This repository has been archived by the owner on Apr 12, 2024. It is now read-only.
chore: deprecation notice (#362) #55
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: "Main Branch Beta Release" | |
on: | |
push: | |
branches: | |
- master | |
jobs: | |
release: | |
name: release | |
runs-on: ubuntu-latest | |
if: github.event_name == 'push' && github.ref == 'refs/heads/master' | |
steps: | |
- name: Activate corepack | |
run: corepack enable | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-node@v4 | |
with: | |
node-version: "16" | |
registry-url: 'https://registry.npmjs.org' | |
- name: Get yarn cache directory path | |
id: yarn-cache-dir-path | |
run: echo "dir=$(yarn config get cacheFolder)" >> "$GITHUB_OUTPUT" | |
- name: Cache yarn cache directory | |
uses: actions/cache@v3 | |
id: yarn-cache | |
with: | |
path: ${{ steps.yarn-cache-dir-path.outputs.dir }} | |
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} | |
restore-keys: | | |
${{ runner.os }}-yarn- | |
- run: yarn --immutable | |
- run: yarn build | |
- name: "Retrieving package version" | |
uses: martinbeentjes/npm-get-version-action@main | |
id: version | |
- name: "Retrieving commit hash" | |
id: commit | |
uses: pr-mpt/actions-commit-hash@v2 | |
- name: "Set git user" | |
run: | | |
git config user.name ChainSafe | |
git config user.email [email protected] | |
- run: yarn npm publish --access public --tag beta --new-version ${{steps.version.outputs.current-version}}-${{steps.commit.outputs.short}} | |
env: | |
NODE_AUTH_TOKEN: ${{secrets.NPM_AUTH_TOKEN}} |