Skip to content

Workflow file for this run

name: 📦 Publish Github
on:
release:
types:
- published
jobs:
release:
name: Publish
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
token: ${{ secrets.PAT }}
- uses: actions/setup-node@v4
with:
node-version: 20
registry-url: https://npm.pkg.github.com/
scope: "@ahiho"
- run: yarn ci:install
env:
NODE_AUTH_TOKEN: ${{ secrets.PAT }}
- run: echo "PACKAGE=$(sed -e s:@[^@]*$::g <<< ${GITHUB_REF#refs/*/})" >> $GITHUB_ENV
- run: echo "RELEASE_VERSION=$(sed -e s:.*@::g <<< ${GITHUB_REF#refs/*/})" >> $GITHUB_ENV
- run: |
git config --global user.email "[email protected]"
git config --global user.name "GitHub Action"
yarn nx publish ${PACKAGE} --ver ${RELEASE_VERSION}
env:
GH_TOKEN: ${{ secrets.PAT }}
NODE_AUTH_TOKEN: ${{ github.token }}