Skip to content

[pre-commit.ci] pre-commit autoupdate #316

[pre-commit.ci] pre-commit autoupdate

[pre-commit.ci] pre-commit autoupdate #316

Workflow file for this run

---
'on':
push:
paths-ignore:
- '**.md'
pull_request:
paths-ignore:
- '**.md'
workflow_dispatch:
# https://github.com/softprops/action-gh-release/issues/236
permissions:
contents: write
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Enable corepack
run: |
corepack enable
- uses: actions/setup-node@v4
with:
node-version: latest
registry-url: https://registry.npmjs.org
cache: 'yarn'
- name: Install dependencies
run: |
sudo apt-get -y update
sudo apt-get -y install librime-dev libjson-c-dev librime1 libjson-c5
yarn
- name: Build
run: |
yarn pack
env:
NODE_ENV: production
- uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
files: '*.tgz'
- name: Publish
env:
NODE_AUTH_TOKEN: ${{secrets.NODE_AUTH_TOKEN}}
NODE_ENV: production
if: startsWith(github.ref, 'refs/tags/')
run: |
npm publish