-
Notifications
You must be signed in to change notification settings - Fork 0
79 lines (67 loc) · 2.28 KB
/
electron-build.yaml
File metadata and controls
79 lines (67 loc) · 2.28 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
name: 🚧 Build/🚀 Release Electron App
on:
push:
branches: ["main"]
tags:
- v*.*.* # 🔖 Only run on version tags like v0.0.2
jobs:
release:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
steps:
- name: 🔄 Check out Git repository
uses: actions/checkout@v3
- name: 📦 Install Node.js
uses: actions/setup-node@v3
with:
node-version: 20
- name: 📥 Install Dependencies
run: npm install
working-directory: desktop
# 🐧 Linux Build
- name: 🐧 Build for Linux
if: matrix.os == 'ubuntu-latest'
run: npm run build:linux
working-directory: desktop
# 🍎 macOS Build
- name: 🍎 Build for macOS
if: matrix.os == 'macos-latest'
run: npm run build:mac
working-directory: desktop
# 🪟 Windows Build
- name: 🪟 Build for Windows
if: matrix.os == 'windows-latest'
run: npm run build:win
working-directory: desktop
# 📜 Extract changelog for the current version tag
- name: 📝 Extract changelog for current tag
id: extract_changelog
run: |
TAG_NAME=${{ github.ref_name }}
awk "/## ${TAG_NAME}/,/^## v[0-9]+\.[0-9]+\.[0-9]+/" changelog.md | sed '$d' > changelog.txt
shell: bash
- name: 👀 Show extracted changelog
run: cat changelog.txt
# 🚀 Publish GitHub Release with Assets and Changelog
- name: 🚀 Publish GitHub Release
uses: softprops/action-gh-release@v1
if: github.ref_type == 'tag'
with:
body_path: changelog.txt
repository: devlopersabbir/executeme
token: ${{ secrets.EXECUTE_ME_GITHUB_TOKEN }}
files: |
desktop/dist/*.exe
desktop/dist/*.zip
desktop/dist/*.dmg
desktop/dist/*.AppImage
desktop/dist/*.snap
desktop/dist/*.deb
desktop/dist/*.rpm
desktop/dist/*.tar.gz
desktop/dist/*.yml
desktop/dist/*.blockmap
env:
GITHUB_TOKEN: ${{ secrets.EXECUTE_ME_GITHUB_TOKEN }}