Skip to content

Commit 3058e7a

Browse files
committed
Fix issue with single quotes surrounding repo name
1 parent 2471a9d commit 3058e7a

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎gitreceive‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ EOF
4444
export RECEIVE_USER=$2
4545
export RECEIVE_FINGERPRINT=$3
4646
# ssh provides the original requested command in $SSH_ORIGINAL_COMMAND
47-
export RECEIVE_REPO="$(echo $SSH_ORIGINAL_COMMAND | awk '{print $2}')"
47+
export RECEIVE_REPO="$(echo $SSH_ORIGINAL_COMMAND | awk '{print $2}' | perl -pe 's/(?<!\\)'\''//g' | sed 's/\\//g')"
4848
REPO_PATH="$GITHOME/$RECEIVE_REPO"
4949
if [ ! -d $REPO_PATH ]; then
5050
mkdir -p $REPO_PATH

0 commit comments

Comments
 (0)