Skip to content

Commit 271806f

Browse files
committed
Removed initial character stripping
Locally the `[` being copied over was an issue, but apparently on the GitHub Actions side of things it is smart enough to inherently strip that character. Or at least that appears to be the case, we shall soon find out.
1 parent 662b67d commit 271806f

File tree

1 file changed

+1
-8
lines changed

1 file changed

+1
-8
lines changed

entrypoint.sh

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -119,15 +119,13 @@ then
119119
fi
120120
set -e
121121

122-
# Parses the passed strings to arrays and removes the leading `[` from the YAML parsing
122+
# Parses the passed strings to arrays
123123
# https://stackoverflow.com/a/5257398/6456163
124124
SOURCE_DIRECTORIES_ARRAY=(${SOURCE_DIRECTORIES//\\n/ })
125-
SOURCE_DIRECTORIES_ARRAY[0]="${SOURCE_DIRECTORIES_ARRAY[0]:1}"
126125

127126
if [ -n "${DESTINATION_DIRECTORY_PREFIXES:=}" ]
128127
then
129128
DESTINATION_DIRECTORY_PREFIXES_ARRAY=(${DESTINATION_DIRECTORY_PREFIXES//\\n/ })
130-
DESTINATION_DIRECTORY_PREFIXES_ARRAY[0]="${DESTINATION_DIRECTORY_PREFIXES_ARRAY[0]:1}"
131129
else
132130
# Populate an array of the correct length with empty strings
133131
for i in $(seq "$NUM_SOURCE_DIRS"); do
@@ -151,11 +149,6 @@ echo ""
151149
echo "[+] List of files that will be pushed:"
152150
ls -la
153151

154-
# Used for local testing, when ran via `./entrypoint.sh [...]`
155-
# GITHUB_REPOSITORY="$DESTINATION_REPOSITORY_USERNAME/$DESTINATION_REPOSITORY_NAME"
156-
# GITHUB_SHA="$(git rev-parse HEAD)"
157-
# GITHUB_REF="refs/heads/$TARGET_BRANCH"
158-
159152
ORIGIN_COMMIT="https://$GITHUB_SERVER/$GITHUB_REPOSITORY/commit/$GITHUB_SHA"
160153
COMMIT_MESSAGE="${COMMIT_MESSAGE/ORIGIN_COMMIT/$ORIGIN_COMMIT}"
161154
COMMIT_MESSAGE="${COMMIT_MESSAGE/\$GITHUB_REF/$GITHUB_REF}"

0 commit comments

Comments
 (0)