Skip to content

Commit

Permalink
Use intermediate files to handle newlines
Browse files Browse the repository at this point in the history
  • Loading branch information
almahmoud authored Dec 23, 2024
1 parent d11bc90 commit eeb936e
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions .github/workflows/build_containers.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -238,11 +238,9 @@ jobs:
shell: bash
run: |
# Prepare tags
TAGS=$(printf "%s" '${{ steps.meta2.outputs.tags }}' | tr '\n' ' ' | sed 's/ *$//')
TAG_ARGS=""
for tag in "$TAGS"; do
TAG_ARGS="$TAG_ARGS -t $tag"
done
echo '${{ steps.meta2.outputs.tags }}' > /tmp/tags
cat /tmp/tags | xargs -i bash -c 'printf "%s" "-t {} " >> /tmp/tagargs'
TAG_ARGS="$(cat /tmp/tagargs)"
# Add R version tags for ghcr.io images
if [[ "${{ matrix.base.image }}" == *"ghcr.io"* ]]; then
Expand Down

0 comments on commit eeb936e

Please sign in to comment.