WP-CLI 命令行手册

title: "WP_CLI\Utils\parse_ssh_url()" post_status: publish comment_status: open taxonomy: category: - wp-cli-handbook post_tag: - Internal Api - References - Repos


WP_CLI\Utils\parse_ssh_url()

解析 SSH URL 获取主机、端口和路径信息。


使用方法

WP_CLI\Utils\parse_ssh_url( $url, $component = -1 )
$url (string)
$component (int)
@return (mixed)

说明

功能类似 parse_url(),但增加了对已定义 SSH 别名的支持。

主机名 或 主机名/wordpress路径 或 主机名:端口/wordpress路径

内部 API 文档随每个版本从 WP-CLI 代码库自动生成。如需改进建议,请提交拉取请求。


相关函数