Skip to content

fix: change name of the .desktop file. #43

fix: change name of the .desktop file.

fix: change name of the .desktop file. #43

Workflow file for this run

name: Build TWLauncher for Windows and Linux
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
build-windows:
runs-on: windows-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'npm'
- name: Cache Electron and builder cache
uses: actions/cache@v3
with:
path: |
~/.cache/electron
~/.cache/electron-builder
node_modules/.cache
key: ${{ runner.os }}-electron-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-electron-
- name: Install dependencies
run: npm ci --prefer-offline
- name: Set author info
run: |
npm pkg set author.name="${{ github.actor }}"
npm pkg set author.email="${{ github.event.pusher.email || 'noreply@github.com' }}"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Build/release Electron app (Portable)
run: npm run build:win-portable
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Build/release Electron app (Installer)
run: npm run build:win-installer
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: List dist directory
run: dir dist
shell: cmd
- name: Upload portable artifact
uses: actions/upload-artifact@v4
with:
name: twlauncher-windows-portable
path: dist/TWLauncher-x64.exe
if-no-files-found: warn
compression-level: 6
overwrite: false
include-hidden-files: false
- name: Upload installer artifact
uses: actions/upload-artifact@v4
with:
name: twlauncher-windows-installer
path: dist/TWLauncher-Setup.exe
if-no-files-found: warn
compression-level: 6
overwrite: false
include-hidden-files: false
build-linux:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'npm'
- name: Cache Electron and builder cache
uses: actions/cache@v3
with:
path: |
~/.cache/electron
~/.cache/electron-builder
node_modules/.cache
key: ${{ runner.os }}-electron-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-electron-
- name: Install dependencies
run: npm ci --prefer-offline
- name: Install Linux build dependencies
run: |
sudo apt-get update
sudo apt-get install -y --no-install-recommends \
libfuse2 squashfs-tools fuse
sudo apt-get remove -y fuse3 || true
sudo apt-get install -y --no-install-recommends \
flatpak flatpak-builder
wget https://github.com/AppImage/AppImageKit/releases/download/continuous/appimagetool-x86_64.AppImage -O /tmp/appimagetool
chmod +x /tmp/appimagetool
sudo mv /tmp/appimagetool /usr/local/bin/appimagetool
env:
DEBIAN_FRONTEND: noninteractive
- name: Verify Flatpak installation
run: |
flatpak --version || { echo "Flatpak installation failed"; exit 1; }
flatpak-builder --version || { echo "Flatpak-builder installation failed"; exit 1; }
which flatpak || { echo "Flatpak binary not found in PATH"; exit 1; }
- name: Add Flathub repository
run: |
flatpak --user remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo
env:
DEBIAN_FRONTEND: noninteractive
- name: Install Flatpak runtimes
run: |
flatpak --user install -y flathub org.freedesktop.Platform//23.08 org.freedesktop.Sdk//23.08
env:
DEBIAN_FRONTEND: noninteractive
- name: Set author info
run: |
npm pkg set author.name="${{ github.actor }}"
npm pkg set author.email="${{ github.event.pusher.email || 'noreply@github.com' }}"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Build/release Electron app (AppImage)
run: npm run build:linux-appimage
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Build/release Electron app (Installer)
run: npm run build:linux-installer
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Build Flatpak
run: |
flatpak-builder --force-clean --repo=repo build-dir com.noxygalaxy.TWLauncher.json
flatpak build-bundle repo dist/TWLauncher.flatpak com.noxygalaxy.TWLauncher
- name: List dist directory
run: ls -la dist
- name: Upload AppImage artifact
uses: actions/upload-artifact@v4
with:
name: twlauncher-linux-appimage
path: dist/*.AppImage
if-no-files-found: error
compression-level: 6
overwrite: false
include-hidden-files: false
- name: Upload installer artifact
uses: actions/upload-artifact@v4
with:
name: twlauncher-linux-installer
path: dist/*.deb
if-no-files-found: warn
compression-level: 6
overwrite: false
include-hidden-files: false
- name: Upload Flatpak artifact
uses: actions/upload-artifact@v4
with:
name: twlauncher-linux-flatpak
path: dist/*.flatpak
if-no-files-found: error
compression-level: 6
overwrite: false
include-hidden-files: false