Skip to content

Commit 0cf1823

Browse files
Merge pull request #206 from aligent/fix/DO-1765_random_delimiter
DO-1765: use random delimiter for arbitrary multiline values
2 parents 5408ecf + 5922b51 commit 0cf1823

5 files changed

Lines changed: 18 additions & 12 deletions

File tree

‎.github/workflows/changeset-check.yml‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -163,9 +163,10 @@ jobs:
163163
echo "Affected publishable packages:"
164164
echo "$PUBLISHABLE_AFFECTED"
165165
166-
echo "affected_packages<<EOF" >> $GITHUB_OUTPUT
166+
delimiter="EOF_$(cat /proc/sys/kernel/random/uuid)"
167+
echo "affected_packages<<$delimiter" >> $GITHUB_OUTPUT
167168
echo "$PUBLISHABLE_AFFECTED" >> $GITHUB_OUTPUT
168-
echo "EOF" >> $GITHUB_OUTPUT
169+
echo "$delimiter" >> $GITHUB_OUTPUT
169170
170171
# Check if there are changesets present
171172
CHANGESET_FILES=$(find .changeset -name "*.md" -not -name "README.md" | wc -l)

‎.github/workflows/docker-build.yml‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -124,11 +124,12 @@ jobs:
124124
- name: Prepare build args
125125
id: build-args
126126
run: |
127+
delimiter="EOF_$(cat /proc/sys/kernel/random/uuid)"
127128
{
128-
echo 'args<<EOF'
129+
echo "args<<$delimiter"
129130
echo "$BUILD_ARGS"
130131
echo "$BUILD_ARGS_SECRETS"
131-
echo 'EOF'
132+
echo "$delimiter"
132133
} >> "$GITHUB_OUTPUT"
133134
env:
134135
BUILD_ARGS: ${{ inputs.build-args }}

‎.github/workflows/node-pr.yml‎

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -155,10 +155,11 @@ jobs:
155155
while IFS= read -r mask_line; do
156156
[ -n "$mask_line" ] && echo "::add-mask::${mask_line}"
157157
done <<< "${current_value}"
158+
delimiter="EOF_$(cat /proc/sys/kernel/random/uuid)"
158159
echo "Setting environment variable: ${current_key}"
159-
echo "${current_key}<<GHENV_EOF" >> $GITHUB_ENV
160+
echo "${current_key}<<${delimiter}" >> $GITHUB_ENV
160161
echo "${current_value}" >> $GITHUB_ENV
161-
echo "GHENV_EOF" >> $GITHUB_ENV
162+
echo "${delimiter}" >> $GITHUB_ENV
162163
fi
163164
}
164165
while IFS= read -r line || [ -n "$line" ]; do
@@ -286,10 +287,11 @@ jobs:
286287
while IFS= read -r mask_line; do
287288
[ -n "$mask_line" ] && echo "::add-mask::${mask_line}"
288289
done <<< "${current_value}"
290+
delimiter="EOF_$(cat /proc/sys/kernel/random/uuid)"
289291
echo "Setting environment variable: ${current_key}"
290-
echo "${current_key}<<GHENV_EOF" >> $GITHUB_ENV
292+
echo "${current_key}<<${delimiter}" >> $GITHUB_ENV
291293
echo "${current_value}" >> $GITHUB_ENV
292-
echo "GHENV_EOF" >> $GITHUB_ENV
294+
echo "${delimiter}" >> $GITHUB_ENV
293295
fi
294296
}
295297
while IFS= read -r line || [ -n "$line" ]; do

‎.github/workflows/pwa-deployment.yml‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -225,10 +225,11 @@ jobs:
225225
esac
226226
227227
# Prepare invalidation paths (use heredoc to preserve JSON special characters)
228+
delimiter="EOF_$(cat /proc/sys/kernel/random/uuid)"
228229
{
229-
echo 'invalidation-paths<<INVALIDATION_EOF'
230+
echo "invalidation-paths<<${delimiter}"
230231
echo "${INPUTS_CLOUDFRONT_INVALIDATION_PATHS}"
231-
echo 'INVALIDATION_EOF'
232+
echo "${delimiter}"
232233
} >> $GITHUB_OUTPUT
233234
234235
if [ "${INPUTS_DEBUG}" = "true" ]; then

‎.github/workflows/vercel-performance.yml‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -237,10 +237,11 @@ jobs:
237237
238238
# Hand the fully-qualified URLs to the Lighthouse step so the list is
239239
# defined once, by the caller, in measured-paths.
240+
delimiter="EOF_$(cat /proc/sys/kernel/random/uuid)"
240241
{
241-
echo "list<<URLS_EOF"
242+
echo "list<<$delimiter"
242243
printf '%s' "$urls"
243-
echo "URLS_EOF"
244+
echo "$delimiter"
244245
} >> "$GITHUB_OUTPUT"
245246
246247
- name: Resolve Lighthouse config

0 commit comments

Comments
 (0)