Skip to content

Commit

Permalink
Workflow overhaul
Browse files Browse the repository at this point in the history
  • Loading branch information
Sheathed committed Nov 13, 2024
1 parent ff9e68b commit 4ac47fa
Show file tree
Hide file tree
Showing 3 changed files with 86 additions and 5 deletions.
85 changes: 83 additions & 2 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,22 @@
name: Node.js CI

on: [push]
on:
push:
branches:
- main
paths-ignore:
- 'package.json'
- 'app/package.json'
- 'app/client/package.json'
- 'README.md'

env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

jobs:
build:

windows:
name: Build for Windows

runs-on: windows-latest

Expand All @@ -16,10 +26,81 @@ jobs:
uses: actions/setup-node@v4
with:
node-version: '22.5.1'
- run: npm version patch --git-tag-version false && cd app && npm version patch --git-tag-version false && cd client && npm version patch --git-tag-version false && cd ..\..
- uses: stefanzweifel/git-auto-commit-action@v5
with:
commit_message: Automated Version Bump
push_options: '--force'
skip_dirty_check: true
- run: npm install -g electron-builder
- run: npm install
- run: npm run build
- uses: actions/[email protected]
with:
name: Windows Executables
path: dist/*.exe

linux:
name: Build for Linux
needs: windows

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
- name: Use Node.js
uses: actions/setup-node@v4
with:
node-version: '22.5.1'
- run: npm install -g electron-builder
- run: npm install
- run: npm run lbuild
- uses: actions/[email protected]
with:
name: Linux Executables
path: |
dist/*.AppImage
dist/*.tar.xz
dist/*.amd64.deb
osx:
name: Build for MacOS
needs: windows

runs-on: macos-13

steps:
- uses: actions/checkout@v4
- name: Use Node.js
uses: actions/setup-node@v4
with:
node-version: '22.5.1'
- run: export OPENSSL_DIR=/usr/local/opt/openssl@3
- run: npm install -g electron-builder
- run: npm install
- run: npm run lbuild
- uses: actions/[email protected]
with:
name: MacOS Executables
path: dist/*.dmg

notify:
name: Notify
needs: [osx, linux]

runs-on: ubuntu-latest

steps:
- name: Send message
uses: appleboy/telegram-action@master
with:
to: ${{ secrets.TELEGRAM_TO }}
token: ${{ secrets.TELEGRAM_TOKEN }}
message: |
${{ github.actor }} added a new commit!
${{ github.event.commits[0].message }}
Download: https://nightly.link/SaturnMusic/PC/workflows/main/main?preview
Changelog: https://github.com/${{ github.repository }}/commit/${{github.sha}}
Please star the repository <3
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[![Build status](https://ci.appveyor.com/api/projects/status/bqx9f29tp574oq4w?svg=true)](https://ci.appveyor.com/project/Ascensionist/pc-huhqc) [![Node.js CI](https://github.com/SaturnMusic/PC/actions/workflows/main.yml/badge.svg)](https://github.com/SaturnMusic/PC/actions/workflows/main.yml)
<sup> | [linux dl](https://ci.appveyor.com/project/Ascensionist/pc-huhqc/build/artifacts) | [mac dl](https://ci.appveyor.com/project/Ascensionist/pc/build/artifacts) | [win dl](https://github.com/SaturnMusic/PC/actions/workflows/main.yml)</sup>
[![Node.js CI](https://github.com/SaturnMusic/PC/actions/workflows/main.yml/badge.svg)](https://github.com/SaturnMusic/PC/actions/workflows/main.yml)
<sup> | [download](https://nightly.link/SaturnMusic/PC/workflows/main/main?preview) </sup>

# Saturn
## Freezer Reborn
Expand Down
2 changes: 1 addition & 1 deletion app/client/src/views/About.vue
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
v{{data.version}}
</div>
<br>
<div v-if='update' class='text-center text-h6 font-weight-bold mb-4' @click='openUrl("https://saturn.kim")'>
<div v-if='update' class='text-center text-h6 font-weight-bold mb-4' @click='openUrl("https://nightly.link/SaturnMusic/PC/workflows/main/main?preview")'>
{{$t("New update available:")}} {{update.version}}
<v-btn text color='primary' outlined class='mx-2'>{{$t("Visit website")}}</v-btn>
</div>
Expand Down

0 comments on commit 4ac47fa

Please sign in to comment.