Browse Source

support ssh repos

support repositories with SHH URL.
e.g. given repository URL `ssh://git@some.domain.com:7999/project/cool-stuff.git`
before the change the resulting directory will be: `vendor/git@some.domain.com/7999/project/cool-stuff`
the directory after this change will be: `                 `vendor/some.domain.com/project/cool-stuff``
pull/17/head
Alexander Zilberkant 5 years ago
committed by GitHub
parent
commit
74b0e94d89
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      bin/git-vendor

+ 1
- 1
bin/git-vendor View File

@ -80,7 +80,7 @@ cmd_add()
die "Incorrect options provided: git vendor add <name> <repository> [<ref>]"
fi
dir="$prefix/$(echo "$repository" | sed -E 's/^[a-zA-Z]+((:\/\/)|@)//' | sed 's/:/\//' | sed -E 's/\.git$//')"
dir="$prefix/$(echo "$repository" | sed -E 's/^[a-zA-Z]+((:\/\/)|@|(:\/\/git@))//' | sed -E 's/:[0-9]+//' | sed -E 's/\.git$//')"
message="\
Add \"$name\" from \"$repository@$ref\"


Loading…
Cancel
Save