diff options
author | Jonas Smedegaard <dr@jones.dk> | 2019-05-30 13:38:35 +0200 |
---|---|---|
committer | Jonas Smedegaard <dr@jones.dk> | 2019-05-30 13:38:35 +0200 |
commit | 980ff168e3b73e7977f263013649044214e8bd7f (patch) | |
tree | 306a0f1e3ac67f84f4699e3be02e66f63fcf8d3e | |
parent | ee3565037c88cff4b51acb43ab875ab306a81f8f (diff) |
Fix strip optional suffix ".git".
-rwxr-xr-x | localmrsync | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/localmrsync b/localmrsync index b34e7ca..a4d4a4f 100755 --- a/localmrsync +++ b/localmrsync @@ -42,7 +42,7 @@ for dir in "$@"; do mr reg fi host=$(echo "$url" | sed -e 's/:.*//') - path=$(echo "$url" | sed -e 's/.*://') + path=$(echo "$url" | sed -e 's/.*://' -e 's/\.git$//') if ! ssh "$host" test -d "$path.git"; then ssh "$host" mkdir -p "$(dirname "$path")" ssh "$host" git init --bare "$path.git" |