Skip to content

Commit

Permalink
gh-actions/github/run: Fix escape and rename env -> source
Browse files Browse the repository at this point in the history
Signed-off-by: Ryan Northey <ryan@synca.io>
  • Loading branch information
phlax committed Oct 27, 2023
1 parent e7ad5b3 commit 2716ba9
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions gh-actions/github/run/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ inputs:
default: |
WARNING
env:
source:
type: string


Expand All @@ -36,7 +36,7 @@ runs:
if [[ "${#INPUT_ENV}" -ne 0 ]]; then
SOURCETMP="$(mktemp)"
# TODO(phlax): Fix escaping
echo "${{ inputs.env }}" > "$SOURCETMP"
printf "%s" '${{ inputs.source || inputs.env }}' > "$SOURCETMP"
. "$SOURCETMP"
rm -rf "$SOURCETMP"
fi
Expand Down Expand Up @@ -79,4 +79,4 @@ runs:
fi
shell: bash
env:
INPUT_ENV: ${{ inputs.env }}
INPUT_ENV: ${{ inputs.source || inputs.env }}

0 comments on commit 2716ba9

Please sign in to comment.