git-repo

Tools for sharing git bare repositories
git clone git://git.meso-star.fr/git-repo.git
Log | Files | Refs | README | LICENSE

commit 61bbba820ec921107da87ef8f5c32011fbff68a3
parent c6e6b606ad0e2fbec525bb7fcc31024b87ea60bf
Author: Vincent Forest <vincent.forest@meso-star.com>
Date:   Wed, 25 Sep 2024 14:19:21 +0200

Correction of argument analysis

The calculation of the index of the last argument was incorrectly
written, leading to errors or warnings on some shells.

Diffstat:
Mgit-repo | 4++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/git-repo b/git-repo @@ -83,10 +83,10 @@ while getopts ":ds:" opt; do esac done -[ "${OPTIND}" -gt $# ] && { synopsis; die; } +[ "${OPTIND}" -gt "$#" ] && { synopsis; die; } # Skip parsed arguments -shift $(("${OPTIND}" - 1)) +shift $((OPTIND - 1)) repo="$(echo "$1" | sed 's#/\+$##g')"