remove workflow

This commit is contained in:
2026-03-18 22:59:28 -04:00
parent 366fbd7c49
commit 8dce41f26e
3 changed files with 169 additions and 137 deletions

View File

@@ -1,125 +0,0 @@
name: desktop-builds
on:
push:
branches:
- main
- master
pull_request:
workflow_dispatch:
jobs:
build-linux:
name: build-linux
runs-on: linux
steps:
- name: Checkout
uses: https://gitea.com/actions/checkout@v4
- name: Install Linux dependencies
run: |
if command -v sudo >/dev/null 2>&1; then
SUDO=sudo
else
SUDO=
fi
$SUDO apt-get update
$SUDO apt-get install -y \
libwebkit2gtk-4.1-dev \
libgtk-3-dev \
libayatana-appindicator3-dev \
librsvg2-dev \
patchelf \
rpm
- name: Install toolchain
run: |
if ! command -v rustup >/dev/null 2>&1; then
curl https://sh.rustup.rs -sSf | sh -s -- -y --profile minimal
fi
if ! command -v bun >/dev/null 2>&1; then
curl -fsSL https://bun.sh/install | bash
fi
- name: Install JavaScript dependencies
run: |
export PATH="$HOME/.cargo/bin:$HOME/.bun/bin:$PATH"
bun install --frozen-lockfile
- name: Build Linux bundles
run: |
export PATH="$HOME/.cargo/bin:$HOME/.bun/bin:$PATH"
bun run tauri:build:linux
- name: Upload Linux bundles
uses: https://gitea.com/actions/upload-artifact@v4
with:
name: endless-sea-linux
if-no-files-found: error
path: |
src-tauri/target/release/bundle/deb/*.deb
src-tauri/target/release/bundle/rpm/*.rpm
build-windows:
name: build-windows
runs-on: linux
steps:
- name: Checkout
uses: https://gitea.com/actions/checkout@v4
- name: Install Windows cross-build dependencies
run: |
if command -v sudo >/dev/null 2>&1; then
SUDO=sudo
else
SUDO=
fi
$SUDO apt-get update
$SUDO apt-get install -y \
nsis \
llvm \
lld \
wget \
unzip \
zip
- name: Install toolchain
run: |
if ! command -v rustup >/dev/null 2>&1; then
curl https://sh.rustup.rs -sSf | sh -s -- -y --profile minimal
fi
if ! command -v bun >/dev/null 2>&1; then
curl -fsSL https://bun.sh/install | bash
fi
export PATH="$HOME/.cargo/bin:$HOME/.bun/bin:$PATH"
rustup target add x86_64-pc-windows-msvc
- name: Install cargo-xwin
run: |
export PATH="$HOME/.cargo/bin:$HOME/.bun/bin:$PATH"
cargo install --locked cargo-xwin
- name: Install JavaScript dependencies
run: |
export PATH="$HOME/.cargo/bin:$HOME/.bun/bin:$PATH"
bun install --frozen-lockfile
- name: Build Windows installer from Linux
run: |
export PATH="$HOME/.cargo/bin:$HOME/.bun/bin:$PATH"
bun run tauri:build:windows
- name: Upload Windows bundles
uses: https://gitea.com/actions/upload-artifact@v4
with:
name: endless-sea-windows
if-no-files-found: error
path: |
src-tauri/target/x86_64-pc-windows-msvc/release/bundle/nsis/*.exe

178
README.md
View File

@@ -35,30 +35,186 @@ This project is static and does not require a build step.
If your browser blocks autoplay audio, start the game with a click so music playback can begin normally.
## Desktop Build
## Desktop Builds
The project now includes a Tauri desktop wrapper.
This repository includes a Tauri desktop wrapper under `src-tauri/`. The frontend is copied into `dist/` before each desktop build.
Requirements:
### Build Overview
- Rust and Cargo
- Bun
- Linux desktop build dependencies required by Tauri on your distribution
1. Install Bun.
2. Install Rust.
3. Install the platform-specific Tauri dependencies for the OS you are building on.
4. Run `bun install`.
5. Run one of the build commands below.
Useful commands:
### Shared Project Setup
Install dependencies once per clone:
```bash
bun install
```
You can also stage the static frontend manually:
```bash
bun run build:web
```
That copies `index.html`, `css/`, `js/`, and `music/` into `dist/`.
### Linux Native Build
The Linux build has been verified on this repository and currently produces `.deb` and `.rpm` bundles.
Install Bun on Linux:
```bash
curl -fsSL https://bun.sh/install | bash
```
Install Rust on Linux:
```bash
curl --proto '=https' --tlsv1.2 https://sh.rustup.rs -sSf | sh
```
If Bun or Rust are not on your shell `PATH` yet, restart the terminal before continuing.
Install the Tauri system packages for your distribution.
Debian or Ubuntu:
```bash
sudo apt update
sudo apt install \
libwebkit2gtk-4.1-dev \
build-essential \
curl \
wget \
file \
libxdo-dev \
libssl-dev \
libayatana-appindicator3-dev \
librsvg2-dev \
patchelf \
rpm
```
Fedora:
```bash
sudo dnf check-update
sudo dnf install \
webkit2gtk4.1-devel \
openssl-devel \
curl \
wget \
file \
libappindicator-gtk3-devel \
librsvg2-devel \
libxdo-devel \
patchelf \
rpm-build
sudo dnf group install "c-development"
```
Build the Linux desktop packages:
```bash
bun install
bun run tauri:build:linux
```
Expected outputs:
- `src-tauri/target/release/bundle/deb/Endless Sea_0.1.0_amd64.deb`
- `src-tauri/target/release/bundle/rpm/Endless Sea-0.1.0-1.x86_64.rpm`
### Windows Native Build
For a full Windows installer, build on a Windows machine. This is the most reliable path.
Install Bun in PowerShell:
```powershell
irm bun.sh/install.ps1 | iex
```
Install Rust with the MSVC toolchain:
```powershell
winget install --id Rustlang.Rustup
rustup default stable-msvc
```
Install the required Windows components:
1. Install Microsoft C++ Build Tools.
2. In the installer, enable `Desktop development with C++`.
3. Make sure Microsoft Edge WebView2 Runtime is installed.
Build the Windows installer:
```powershell
bun install
bun run tauri:build
```
Build artifacts are generated under `src-tauri/target/release/bundle/`.
Expected output:
CI:
- `src-tauri/target/release/bundle/nsis/Endless Sea_0.1.0_x64-setup.exe`
- A Gitea Actions workflow now lives in `.gitea/workflows/desktop-builds.yml`.
- Linux runners build native Linux bundles and cross-compile the Windows release target.
### Windows Cross-Build From Linux
If you are on Linux and only need a Windows `.exe`, you can cross-compile it without packaging an installer.
Install the extra cross-build tools:
```bash
sudo apt update
sudo apt install nsis lld llvm
rustup target add x86_64-pc-windows-msvc
cargo install --locked cargo-xwin
```
Build the Windows executable only:
```bash
bun install
bun run tauri:build:windows:exe
```
Expected output:
- `src-tauri/target/x86_64-pc-windows-msvc/release/endless-sea.exe`
If you want to attempt a full NSIS installer from Linux, use:
```bash
bun install
bun run tauri:build:windows:cross
```
Important note:
- Cross-compiling the Windows installer from Linux is experimental in Tauri.
- On this machine, the executable build worked, but the NSIS installer step failed because `makensis.exe` was not available in the Linux environment.
- If you need a reliable signed installer, use a real Windows build machine.
### Build Outputs
- Browser-ready static build: `dist/`
- Linux desktop binary: `src-tauri/target/release/endless-sea`
- Linux bundles: `src-tauri/target/release/bundle/`
- Windows cross-compiled binary: `src-tauri/target/x86_64-pc-windows-msvc/release/endless-sea.exe`
### Troubleshooting
- If `bun` is not found after installation, restart the shell or add Bun to your `PATH`.
- If `cargo` or `rustup` are not found, restart the shell so Cargo's environment is loaded.
- If Linux packaging fails with missing GTK or WebKit packages, re-check the distro-specific dependency list above.
- If a Windows installer build fails on Linux around NSIS, fall back to the `.exe` cross-build or build natively on Windows.
## Project Notes

View File

@@ -8,7 +8,8 @@
"tauri:dev": "bunx tauri dev",
"tauri:build": "bunx tauri build",
"tauri:build:linux": "bunx tauri build",
"tauri:build:windows": "bunx tauri build --runner cargo-xwin --target x86_64-pc-windows-msvc"
"tauri:build:windows:cross": "bunx tauri build --runner cargo-xwin --target x86_64-pc-windows-msvc",
"tauri:build:windows:exe": "bunx tauri build --runner cargo-xwin --target x86_64-pc-windows-msvc --no-bundle"
},
"devDependencies": {
"@tauri-apps/cli": "^2.10.1"