Skip to content
This repository has been archived by the owner on Sep 14, 2023. It is now read-only.

Commit

Permalink
fix release workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
tjjfvi committed Jun 11, 2022
1 parent 702a456 commit 6f0c284
Showing 1 changed file with 11 additions and 7 deletions.
18 changes: 11 additions & 7 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ on:
release:
types:
- created
push:
branches:
- fix-release-workflow
jobs:
publish:
name: Build & Publish to NPM
Expand All @@ -12,18 +15,19 @@ jobs:
- uses: denoland/setup-deno@v1
with:
deno-version: v1.x
- name: Retrieve Version
if: startsWith(github.ref, 'refs/tags/')
id: get_tag_version
run: echo ::set-output name=TAG_VERSION::${GITHUB_REF/refs\/tags\//}
# - name: Retrieve Version
# if: startsWith(github.ref, 'refs/tags/')
# id: get_tag_version
# run: echo ::set-output name=TAG_VERSION::${GITHUB_REF/refs\/tags\//}
- uses: actions/setup-node@v2
with:
node-version: "16.x"
registry-url: "https://registry.npmjs.org"
- name: Build NPM Package
run: deno run -A --no-check=remote ./_tasks/build_npm_pkg.ts ${{steps.get_tag_version.outputs.TAG_VERSION}}
# run: deno run -A --no-check=remote ./_tasks/build_npm_pkg.ts ${{steps.get_tag_version.outputs.TAG_VERSION}}
run: deno run -A --no-check=remote ./_tasks/build_npm_pkg.ts v0.1.0-beta.2
- name: Publish NPM Package
if: startsWith(github.ref, 'refs/tags/')
# if: startsWith(github.ref, 'refs/tags/')
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
run: cd target/npm_pkg && npm publish
run: cd target/npm && npm publish

0 comments on commit 6f0c284

Please sign in to comment.