Skip to content

Commit

Permalink
Github action for release
Browse files Browse the repository at this point in the history
  • Loading branch information
rozumak committed Feb 28, 2023
1 parent c7d1123 commit b995733
Showing 1 changed file with 60 additions and 0 deletions.
60 changes: 60 additions & 0 deletions .github/workflows/prepare_release.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
name: Prepare Release

on:
workflow_dispatch:
push:
tags:
- "v*"

env:
CI: true

permissions:
contents: read

jobs:
build:
permissions:
contents: write # for softprops/action-gh-release to create GitHub release

runs-on: macos-11

strategy:
matrix:
node-version: [18]

steps:
- uses: actions/checkout@v3

- run: git fetch --tags -f

- name: Resolve version
id: vars
run: |
echo "TAG_NAME=$(git describe --tags --abbrev=0)" >> $GITHUB_ENV
- name: Setup Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
registry-url: "https://registry.npmjs.org"

- name: Install dependencies
run: npm install

- name: Build shikicli
run: npm run build

- name: Release
uses: softprops/action-gh-release@v1
with:
draft: true
tag_name: ${{ env.TAG_NAME }}
files: |
dist/shikicli-linux-arm64
dist/shikicli-linux-armv7
dist/shikicli-linux-x64
dist/shikicli-macos-arm64
dist/shikicli-macos-x64
dist/shikicli-win-x64.exe
dist/shikicli-win-arm64.exe

0 comments on commit b995733

Please sign in to comment.