Skip to content

Commit 31bdcc7

Browse files
committed
add github actions
1 parent fd1183c commit 31bdcc7

File tree

4 files changed

+12196
-2
lines changed

4 files changed

+12196
-2
lines changed

.github/workflows/electron_build.yml

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node
2+
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs
3+
4+
name: Build electron
5+
6+
on:
7+
push:
8+
tags:
9+
- 'v[0-9]+.[0-9]+.[0-9]+'
10+
11+
jobs:
12+
build:
13+
runs-on: ${{ matrix.os }}
14+
15+
strategy:
16+
matrix:
17+
node-version: [18.x]
18+
os: [macos-latest, ubuntu-latest, windows-latest]
19+
20+
steps:
21+
- uses: actions/checkout@v3
22+
- name: Use Node.js ${{ matrix.node-version }}
23+
uses: actions/setup-node@v3
24+
with:
25+
node-version: ${{ matrix.node-version }}
26+
cache: 'npm'
27+
- name: Run install
28+
uses: borales/actions-yarn@v4
29+
with:
30+
cmd: install
31+
- name: Run package
32+
uses: borales/actions-yarn@v4
33+
with:
34+
cmd: run package
35+
- name: Upload a Build Artifact
36+
uses: actions/upload-artifact@v4.3.1
37+
with:
38+
name: helm-cli-helper-${{ runner.os }}
39+
path: out
40+
overwrite: true
41+
- name: Compress binary (Windows)
42+
if: runner.os == 'Windows'
43+
run: |
44+
Compress-Archive -Path out\* -DestinationPath helm-cli-helper-windows.zip
45+
- name: Compress binary (Linux)
46+
if: runner.os == 'Linux'
47+
run: |
48+
zip -r helm-cli-helper-linux.zip out/*
49+
- name: Compress binary (macOS)
50+
if: runner.os == 'macOS'
51+
run: |
52+
zip -r helm-cli-helper-mac.zip out/*
53+
- name: Release
54+
uses: softprops/action-gh-release@v2.0.4
55+
with:
56+
files: helm-cli-helper-*.zip
57+
env:
58+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.gitignore

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,4 @@ typings/
9191
# Electron-Forge
9292
out/
9393

94-
yarn.lock
95-
package-lock.json
9694
.vscode/

0 commit comments

Comments
 (0)