Skip to content

Commit cf1fdde

Browse files
Refactor Github Action per b/485167538
1 parent d8ab6a1 commit cf1fdde

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

.github/workflows/dist.yml

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -47,11 +47,11 @@ jobs:
4747
id: event-args
4848
run: |
4949
set -x
50-
REF="${{ github.event.ref }}"
50+
REF="${GITHUB_EVENT_REF}"
5151
TAG=$(echo $REF| sed 's/refs\/tags\///')
5252
DIST_TAG="dist-$TAG"
53-
git config user.email "${{ github.event.head_commit.author.email }}"
54-
git config user.name "${{ github.event.head_commit.author.name }}"
53+
git config user.email "${GITHUB_EVENT_HEAD_COMMIT_AUTHOR_EMAIL}"
54+
git config user.name "${GITHUB_EVENT_HEAD_COMMIT_AUTHOR_NAME}"
5555
git checkout -b tmp-$DIST_TAG
5656
# remove workflow etc, otherwise we'll need workflow override permissions
5757
rm -rf .github
@@ -71,3 +71,7 @@ jobs:
7171
git tag -a $DIST_TAG -m "dist for $TAG" -f
7272
git push origin $DIST_TAG -f
7373
echo "done pushing to git"
74+
env:
75+
GITHUB_EVENT_REF: ${{ github.event.ref }}
76+
GITHUB_EVENT_HEAD_COMMIT_AUTHOR_EMAIL: ${{ github.event.head_commit.author.email }}
77+
GITHUB_EVENT_HEAD_COMMIT_AUTHOR_NAME: ${{ github.event.head_commit.author.name }}

0 commit comments

Comments
 (0)