Skip to content

Commit

Permalink
feat(cd): build and attach plugin binary to dev github release
Browse files Browse the repository at this point in the history
  • Loading branch information
nishantwrp committed Jan 26, 2025
1 parent b1c80fc commit b632333
Showing 1 changed file with 40 additions and 0 deletions.
40 changes: 40 additions & 0 deletions .github/workflows/cd.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: CD
on:
push:
branches:
- master
paths:
- src/**
- package.json
- tsconfig.json
- webpack.config.js
- .github/workflows/cd.yml
workflow_dispatch:
jobs:
dev-release:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest]
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
- name: Install dependencies
run: npm install
- name: Build plugin
run: npm run dist
- name: Remove existing artifacts
uses: andreaswilli/[email protected]
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
tag: dev
- name: Calculate short SHA
shell: bash
run: echo "GITHUB_SHORT_SHA=$(git rev-parse --short "$GITHUB_SHA")" >> "$GITHUB_ENV"
- name: Upload binary to release
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: publish/joplin.plugin.templates.jpl
asset_name: joplin.plugin.templates.dev-${{ env.GITHUB_SHORT_SHA }}.jpl
tag: dev

0 comments on commit b632333

Please sign in to comment.