Skip to content

Commit

Permalink
feat: add github generated SDK_VERSION
Browse files Browse the repository at this point in the history
  • Loading branch information
coroiu committed Oct 22, 2024
1 parent d9f4fad commit 154dbf1
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions .github/workflows/build-wasm-internal.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,23 @@ jobs:
- name: Checkout repo
uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4.2.1

- name: Set version (PR)
if: ${{ github.event_name == 'pull_request' }}
run: |
export REF_NAME="${{ github.event.pull_request.head.ref }}"
export SHA="${{ github.event.pull_request.head.sha }}"
- name: Set env variables (Branch/Tag)
if: ${{ github.event_name == 'push' }}
run: |
export REF_NAME="${GITHUB_REF_NAME}"
export SHA="${GITHUB_SHA}"
- name: Set version
run: |
export SDK_VERSION="${REF_NAME} (${SHA:0:7})"
echo "SDK_VERSION=$SDK_VERSION"
- name: Setup Node
uses: actions/setup-node@0a44ba7841725637a19e28fa30b79a866c81b0a6 # v4.0.4
with:
Expand Down

0 comments on commit 154dbf1

Please sign in to comment.