diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 5a98cd0..b54d431 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -1,7 +1,8 @@ name: Publish NPM on: - release: - types: [released] + workflow_run: + workflows: [Release] + types: [completed] jobs: release: runs-on: ubuntu-latest @@ -9,6 +10,11 @@ jobs: steps: - name: Checkout uses: actions/checkout@v4 + - name: Checkout latest tag + run: | + git fetch --all --tags -f + git rev-list --tags --max-count=1 + git checkout $(git describe --tags `git rev-list --tags --max-count=1`) - name: Setup Node.js uses: actions/setup-node@v3 with: