forked from LaconicNetwork/kompose
Update cmd to get git remote url for backwards compatibility
with older git-2.6.x
This commit is contained in:
parent
eb719f85c2
commit
ba9995c17b
@ -85,7 +85,7 @@ func hasGitBinary() bool {
|
|||||||
|
|
||||||
// getGitRemote gets git remote URI for the current git repo
|
// getGitRemote gets git remote URI for the current git repo
|
||||||
func getGitRemote(composeFileDir string, remote string) (string, error) {
|
func getGitRemote(composeFileDir string, remote string) (string, error) {
|
||||||
cmd := exec.Command("git", "remote", "get-url", remote)
|
cmd := exec.Command("git", "ls-remote", "--get-url", remote)
|
||||||
cmd.Dir = composeFileDir
|
cmd.Dir = composeFileDir
|
||||||
out, err := cmd.Output()
|
out, err := cmd.Output()
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user