coder/v0.3.0 #32
Workflow file for this run
This file contains hidden or 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: Publish | |
# This workflow will publish releases published on GitHub to NPM. | |
on: | |
release: | |
types: | |
- released | |
workflow_dispatch: | |
inputs: | |
tag: | |
description: The tag to publish (for example "coder/v0.0.0") | |
type: string | |
required: true | |
concurrency: ${{ github.workflow }}-${{ github.ref }} | |
jobs: | |
npm: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: robinraju/[email protected] | |
with: | |
tag: ${{ github.event.inputs.tag || github.ref_name }} | |
fileName: '*.tgz' | |
# Although we are publishing the tarball, yarn will not actually look at | |
# the package.json in the tarball so we have to extract it first. | |
- run: tar -xf *.tgz | |
- run: mv package/package.json package.json | |
# Normally publish tries to run a script that packages the plugin but we | |
# already have it packaged, so ignore scripts. | |
- run: yarn publish --ignore-scripts *.tgz | |
env: | |
YARN_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} |