作为我正在做的自动化工作的一部分,我需要克隆一个 repo,因为它有一个我需要用于自动化的 json 文件。我已导入posh-git
,但无法在git clone <url>
其中运行。这是错误:git : The term 'git' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
显然,我已经在源代码管理中添加了我的帐户。所以,我已经完成了
$SourceControl = Get-AzureRmAutomationSourceControl -AutomationAccountName $AutomationAccountName -Name testRepo -ResourceGroupName $ResourceGroupName
然后我在做git clone $SourceControl.RepoUrl
它因上述错误而失败。
任何帮助是极大的赞赏。