Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/php/244.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/git/20.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
在php中使用exec推入git_Php_Git - Fatal编程技术网

在php中使用exec推入git

在php中使用exec推入git,php,git,Php,Git,知道如何在push命令后发送密码吗? exec(“git add*”) exec(“git commit-m‘first commit’”) exec(“git推送原始主机”) 我非常需要你的建议 如有任何建议,将不胜感激 谢谢这里有一些想法:@LajosVeres,在你的链接示例中,使用exec和php推进git的地方?@lvaroG.Vicario,这将是直接的工作吗?您测试过吗?如果您可以使用ssh而不是https连接到git repo,我会使用(非交互式)公钥身份验证。还有“expect

知道如何在push命令后发送密码吗?

exec(“git add*”)
exec(“git commit-m‘first commit’”)
exec(“git推送原始主机”)

我非常需要你的建议
如有任何建议,将不胜感激


谢谢

这里有一些想法:@LajosVeres,在你的链接示例中,使用exec和php推进git的地方?@lvaroG.Vicario,这将是直接的工作吗?您测试过吗?如果您可以使用ssh而不是https连接到git repo,我会使用(非交互式)公钥身份验证。还有“expect”unix程序来处理交互式提示…对于ssh,我还建议使用公钥身份验证。