diff --git a/entrypoint.sh b/entrypoint.sh index e328bf3..ea93e63 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -10,7 +10,7 @@ TARGET_BRANCH="$6" if [ -z "$REPO_USERNAME" ] then - REPO_USERNAME=$GITHUB_USERNAME + REPO_USERNAME="$GITHUB_USERNAME" fi if [ -z "$TARGET_BRANCH" ] then @@ -23,7 +23,7 @@ echo "Cloning destination git repository" # Setup git git config --global user.email "$USER_EMAIL" git config --global user.name "$GITHUB_USERNAME" -git clone --single-branch --branch $TARGET_BRANCH "https://$API_TOKEN_GITHUB@github.com/$REPO_USERNAME/$GITHUB_REPO.git" "$CLONE_DIR" +git clone --single-branch --branch "$TARGET_BRANCH" "https://$API_TOKEN_GITHUB@github.com/$REPO_USERNAME/$GITHUB_REPO.git" "$CLONE_DIR" ls -la "$CLONE_DIR" echo "Cleaning destination repository of old files" @@ -42,4 +42,4 @@ git status git commit --message "Update from https://github.com/$GITHUB_REPOSITORY/commit/$GITHUB_SHA" echo "Pushing git commit" -git push origin $TARGET_BRANCH +git push origin "$TARGET_BRANCH"