Skip to content

Commit 2fb63a8

Browse files
committed
Add GitHub Actions CI/CD, website refresh, and documentation updates
Features: - Add GitHub Actions workflow for multi-platform builds (Windows, Linux, macOS Intel/ARM) - Platform selection dropdown for manual workflow dispatch - Auto-release on version tags (v*) Website: - Refresh index.html with v2.0 branding and new screenshots - Add local images in web/assets/images/ - New hero section with app preview and gradient border - Gallery with lightbox functionality - Updated stats: <0.5s launch, ~15MB binary, Go + Wails + Svelte Documentation: - Add GitHub Actions build tutorial in README - Step-by-step guide for fork, build, and release - Build output table for all platforms
1 parent b2792c5 commit 2fb63a8

23 files changed

+1779
-16
lines changed
File renamed without changes.

.Proposal/hehe_this_is_before_the_scene

Whitespace-only changes.

.github/workflows/build.yml

Lines changed: 104 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,104 @@
1+
name: Build SurfManager
2+
3+
on:
4+
push:
5+
tags:
6+
- 'v*'
7+
workflow_dispatch:
8+
inputs:
9+
platform:
10+
description: 'Target Platform'
11+
required: true
12+
default: 'all'
13+
type: choice
14+
options:
15+
- all
16+
- windows-amd64
17+
- linux-amd64
18+
- macos-amd64
19+
- macos-arm64
20+
21+
jobs:
22+
build:
23+
strategy:
24+
matrix:
25+
include:
26+
- os: windows-latest
27+
platform: windows/amd64
28+
output: SurfManager-windows-amd64.exe
29+
name: windows-amd64
30+
- os: ubuntu-latest
31+
platform: linux/amd64
32+
output: SurfManager-linux-amd64
33+
name: linux-amd64
34+
- os: macos-latest
35+
platform: darwin/amd64
36+
output: SurfManager-darwin-amd64
37+
name: macos-amd64
38+
- os: macos-latest
39+
platform: darwin/arm64
40+
output: SurfManager-darwin-arm64
41+
name: macos-arm64
42+
43+
runs-on: ${{ matrix.os }}
44+
if: >-
45+
github.event_name == 'push' ||
46+
inputs.platform == 'all' ||
47+
inputs.platform == matrix.name
48+
49+
steps:
50+
- name: Checkout
51+
uses: actions/checkout@v4
52+
53+
- name: Setup Go
54+
uses: actions/setup-go@v5
55+
with:
56+
go-version: '1.21'
57+
58+
- name: Setup Node.js
59+
uses: actions/setup-node@v4
60+
with:
61+
node-version: '20'
62+
63+
- name: Install Wails CLI
64+
run: go install github.com/wailsapp/wails/v2/cmd/wails@latest
65+
66+
# Linux dependencies
67+
- name: Install Linux Dependencies
68+
if: matrix.os == 'ubuntu-latest'
69+
run: |
70+
sudo apt-get update
71+
sudo apt-get install -y libgtk-3-dev libwebkit2gtk-4.0-dev
72+
73+
# Build
74+
- name: Build
75+
run: wails build -platform ${{ matrix.platform }} -o ${{ matrix.output }}
76+
77+
# Upload artifact
78+
- name: Upload Artifact
79+
uses: actions/upload-artifact@v4
80+
with:
81+
name: ${{ matrix.output }}
82+
path: build/bin/${{ matrix.output }}*
83+
84+
release:
85+
needs: build
86+
runs-on: ubuntu-latest
87+
if: startsWith(github.ref, 'refs/tags/')
88+
89+
steps:
90+
- name: Download all artifacts
91+
uses: actions/download-artifact@v4
92+
with:
93+
path: artifacts
94+
95+
- name: Display structure
96+
run: ls -R artifacts
97+
98+
- name: Create Release
99+
uses: softprops/action-gh-release@v1
100+
with:
101+
files: artifacts/**/*
102+
generate_release_notes: true
103+
env:
104+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

README.md

Lines changed: 75 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,25 @@ Perfect for developers who need to:
2121

2222
---
2323

24+
## 📸 Screenshots
25+
26+
<table>
27+
<tr>
28+
<td><img src="https://github.com/user-attachments/assets/84270f82-f69c-4697-a9bd-715dbd9aa4db" alt="Reset Data" width="400"/></td>
29+
<td><img src="https://github.com/user-attachments/assets/4da88062-ed39-4f31-b953-38ac97e2d1e0" alt="Sessions" width="400"/></td>
30+
</tr>
31+
<tr>
32+
<td><img src="https://github.com/user-attachments/assets/aeacc874-2d86-453f-86d1-97b2214c807a" alt="Config App" width="400"/></td>
33+
<td><img src="https://github.com/user-attachments/assets/ba163263-f275-444a-adf5-3d49cdc9bae0" alt="Notes" width="400"/></td>
34+
</tr>
35+
<tr>
36+
<td><img src="https://github.com/user-attachments/assets/7bb1bfc6-d2ae-407c-bbd1-5e76f58a2067" alt="Settings" width="400"/></td>
37+
<td><img src="https://github.com/user-attachments/assets/347d989d-2df7-49d0-a8e3-b77e772cc5a7" alt="About" width="400"/></td>
38+
</tr>
39+
</table>
40+
41+
---
42+
2443
## ✨ Features
2544

2645
| Feature | Description |
@@ -253,6 +272,62 @@ This will check if all dependencies are installed correctly.
253272

254273
---
255274

275+
## 🚀 Building with GitHub Actions (Recommended)
276+
277+
The easiest way to build for all platforms is using GitHub Actions. No need to install anything locally!
278+
279+
### Quick Start
280+
281+
1. **Fork the repository**
282+
- Go to [github.com/risunCode/SurfManager](https://github.com/risunCode/SurfManager)
283+
- Click "Fork" button (top right)
284+
285+
2. **Enable GitHub Actions**
286+
- Go to your forked repo → "Actions" tab
287+
- Click "I understand my workflows, go ahead and enable them"
288+
289+
3. **Run the build**
290+
- Go to "Actions" → "Build SurfManager"
291+
- Click "Run workflow" dropdown
292+
- Select platform:
293+
- `all` - Build for Windows, Linux, macOS (Intel & Apple Silicon)
294+
- `windows-amd64` - Windows 64-bit only
295+
- `linux-amd64` - Linux 64-bit only
296+
- `macos-amd64` - macOS Intel only
297+
- `macos-arm64` - macOS Apple Silicon only
298+
- Click "Run workflow"
299+
300+
4. **Download artifacts**
301+
- Wait for build to complete (~5-10 minutes)
302+
- Click on the completed workflow run
303+
- Download artifacts from the bottom of the page
304+
305+
### Creating a Release
306+
307+
To automatically create a GitHub Release with all binaries:
308+
309+
```bash
310+
# Tag your version
311+
git tag v2.0.0
312+
git push origin v2.0.0
313+
```
314+
315+
This will:
316+
- Build for all 4 platforms automatically
317+
- Create a GitHub Release
318+
- Attach all binaries to the release
319+
320+
### Build Outputs
321+
322+
| Platform | Output File | Architecture |
323+
|----------|-------------|--------------|
324+
| Windows | `SurfManager-windows-amd64.exe` | 64-bit Intel/AMD |
325+
| Linux | `SurfManager-linux-amd64` | 64-bit Intel/AMD |
326+
| macOS | `SurfManager-darwin-amd64` | Intel Mac |
327+
| macOS | `SurfManager-darwin-arm64` | Apple Silicon (M1/M2/M3) |
328+
329+
---
330+
256331
## 🆘 Help Wanted: Linux & macOS Compatibility
257332

258333
**We need your help!** SurfManager is primarily developed and tested on Windows. We need contributors to help with:

frontend/src/App.svelte

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -171,16 +171,15 @@
171171
</div>
172172

173173
<!-- Footer -->
174-
<footer class="h-8 bg-[var(--bg-elevated)] border-t border-[var(--border)] flex items-center justify-between px-4 text-xs transition-colors">
175-
<span class="text-[var(--text-muted)]">{progress.message}</span>
176-
{#if progress.percent > 0 && progress.percent < 100}
177-
<div class="w-48 h-1.5 bg-[var(--bg-hover)] rounded-full overflow-hidden">
178-
<div
179-
class="h-full bg-gradient-to-r from-[var(--primary)] to-[var(--primary-light)] transition-all duration-300"
180-
style="width: {progress.percent}%"
181-
></div>
182-
</div>
183-
{/if}
174+
<footer class="h-10 bg-[var(--bg-elevated)] border-t border-[var(--border)] flex items-center gap-4 px-4 text-xs transition-colors">
175+
<span class="text-[var(--text-muted)] flex-shrink-0">{progress.message}</span>
176+
<div class="flex-1 h-2 bg-[var(--bg-hover)] rounded-full overflow-hidden">
177+
<div
178+
class="h-full bg-gradient-to-r from-[var(--primary)] to-[var(--primary-light)] transition-all duration-300"
179+
style="width: {progress.percent}%"
180+
></div>
181+
</div>
182+
<span class="text-[var(--text-muted)] flex-shrink-0 w-10 text-right">{progress.percent}%</span>
184183
</footer>
185184
</div>
186185
</main>

frontend/src/lib/ResetTab.svelte

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@
1515
let sessionCount = 0;
1616
1717
$: autoBackup = $settings.autoBackup;
18-
$: skipCloseApp = $settings.skipCloseApp;
1918
2019
onMount(loadApps);
2120
@@ -66,7 +65,7 @@
6665
6766
log(`[Reset] Starting ${selectedApp.display_name}...`);
6867
try {
69-
await ResetApp(selectedApp.app_name, autoBackup, skipCloseApp);
68+
await ResetApp(selectedApp.app_name, autoBackup, $settings.skipCloseApp);
7069
log(`[Reset] ${selectedApp.display_name} complete!`);
7170
await loadApps();
7271
} catch (e) {

frontend/src/lib/SessionsTab.svelte

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,6 @@
2323
// Context menu state
2424
let contextMenu = { show: false, x: 0, y: 0, session: null };
2525
26-
$: skipCloseApp = $settings.skipCloseApp;
27-
2826
onMount(() => {
2927
showAuto = $settings.showAutoBackups;
3028
filter = $settings.defaultSessionFilter;
@@ -79,7 +77,7 @@
7977
8078
log(`Creating backup: ${newBackupApp}/${newBackupName}...`);
8179
try {
82-
await CreateBackup(newBackupApp, newBackupName.trim(), skipCloseApp);
80+
await CreateBackup(newBackupApp, newBackupName.trim(), $settings.skipCloseApp);
8381
log(`Backup created: ${newBackupName}`);
8482
showNewDialog = false;
8583
await loadData();
@@ -97,7 +95,7 @@
9795
9896
log(`Restoring ${session.name}...`);
9997
try {
100-
await RestoreBackup(session.app, session.name, skipCloseApp);
98+
await RestoreBackup(session.app, session.name, $settings.skipCloseApp);
10199
log(`Restored: ${session.name}`);
102100
await loadData();
103101
} catch (e) {

0 commit comments

Comments
 (0)