Browse Source

Merge pull request #7 from hpe-cloud-garage/fix-bashisms

Fix bashisms.
pull/12/head v1.1.2
Brett Langdon 10 years ago
parent
commit
fe2f6cca40
1 changed files with 11 additions and 12 deletions
  1. +11
    -12
      bin/git-vendor

+ 11
- 12
bin/git-vendor View File

@ -32,12 +32,11 @@ case "$command" in
esac
prefix="vendor"
if [ "$1" == "--prefix" ]; then
if [ "$1" = "--prefix" ]; then
prefix="$2"
shift; shift
fi
vendor_names_from_log()
{
name=
@ -108,16 +107,16 @@ cmd_list()
git-vendor-ref:) ref="$b" ;;
git-vendor-repository:) repository="$b" ;;
END)
if [[ ! -z "$repository" ]];
if [ ! -z "$repository" ];
then
if [[ -z "$showOnly" ]] || [ "$showOnly" == "$name" ]; then
echo "$name@$ref:"
echo "\tname:\t$name"
echo "\tdir:\t$dir"
echo "\trepo:\t$repository"
echo "\tref:\t$ref"
echo "\tcommit:\t$commit"
echo ""
if [ -z "$showOnly" -o "$showOnly" = "$name" ]; then
printf "$name@$ref:\n"
printf "\tname:\t$name\n"
printf "\tdir:\t$dir\n"
printf "\trepo:\t$repository\n"
printf "\tref:\t$ref\n"
printf "\tcommit:\t$commit\n"
printf "\n"
fi
fi
name=
@ -155,7 +154,7 @@ cmd_update()
die "Dependency \"$1\" is missing from \"$dir\""
fi
if [[ ! -z "$repository" ]];
if [ ! -z "$repository" ];
then
message="\
Update \"$name\" from \"$repository@$ref\"


Loading…
Cancel
Save