Skip to content

Commit 9828d4f

Browse files
committed
Merge branch 'dev' for release v3.1.0
2 parents 6d07db6 + 84bb832 commit 9828d4f

66 files changed

Lines changed: 4756 additions & 643 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/release.yml

Lines changed: 48 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,16 @@ jobs:
7171
7272
- name: Build Windows app and installer
7373
shell: pwsh
74-
run: wails build -clean -nsis -platform windows/amd64
74+
env:
75+
SUBSCRIPTION_ENCRYPT_KEY: ${{ secrets.SUBSCRIPTION_ENCRYPT_KEY }}
76+
run: |
77+
$key = $env:SUBSCRIPTION_ENCRYPT_KEY
78+
if ($key) {
79+
wails build -clean -nsis -platform windows/amd64 -ldflags "-X resultproxy-wails/internal/proxy.subscriptionEncryptKey=$key"
80+
} else {
81+
Write-Warning "Secret SUBSCRIPTION_ENCRYPT_KEY not set — building without decryption key"
82+
wails build -clean -nsis -platform windows/amd64
83+
}
7584
7685
- name: Validate Windows artifacts
7786
shell: pwsh
@@ -114,18 +123,47 @@ jobs:
114123
- name: Parse update.json and format Release Data
115124
id: prepare_release
116125
run: |
117-
node -e "
126+
cat > prepare_release.cjs <<'NODE_EOF'
118127
const fs = require('fs');
119128
const update = JSON.parse(fs.readFileSync('update.json', 'utf8'));
120-
let notesText = update.releaseNotes.replace(/\. /g, '.\n-');
121-
if (!notesText.startsWith('-')) notesText = '-' + notesText;
122-
if (notesText.endsWith('-')) notesText = notesText.slice(0, -1);
123-
const title = String(update.releaseTitle || '').trim() || 'Bug Fixes & Improvements';
124-
const releaseBody = 'Что нового в версии ' + update.version + '?\n\n' + notesText + '\n\n🌐 Официальный сайт: ' + new URL(update.downloadUrl).hostname;
129+
130+
const pickLang = (v, lang) => {
131+
if (v == null) return '';
132+
if (typeof v === 'string') return v;
133+
return v[lang] || v.ru || v.en || Object.values(v)[0] || '';
134+
};
135+
136+
const formatBullets = (text) => {
137+
const t = String(text || '').trim();
138+
if (!t) return '';
139+
let out = t.replace(/\. /g, '.\n-');
140+
if (!out.startsWith('-')) out = '-' + out;
141+
if (out.endsWith('-')) out = out.slice(0, -1);
142+
return out;
143+
};
144+
145+
const ruNotes = formatBullets(pickLang(update.releaseNotes, 'ru'));
146+
const enNotes = formatBullets(pickLang(update.releaseNotes, 'en'));
147+
const ruTitle = pickLang(update.releaseTitle, 'ru').trim() || 'Bug Fixes & Improvements';
148+
const enTitle = pickLang(update.releaseTitle, 'en').trim() || ruTitle;
149+
const host = new URL(update.downloadUrl).hostname;
150+
151+
const sections = [];
152+
if (ruNotes) {
153+
sections.push(`Что нового в версии ${update.version}?\n\n${ruNotes}\n\n🌐 Официальный сайт: ${host}`);
154+
}
155+
if (enNotes && enNotes !== ruNotes) {
156+
sections.push(`What's new in version ${update.version}?\n\n${enNotes}\n\n🌐 Official website: ${host}`);
157+
}
158+
const releaseBody = sections.join('\n\n---\n\n');
125159
fs.writeFileSync('RELEASE_BODY.txt', releaseBody);
126-
const fsOut = require('fs');
127-
fsOut.appendFileSync(process.env.GITHUB_OUTPUT, 'release_name=ResultV v' + update.version + ' - ' + title + '\n');
128-
"
160+
161+
const releaseName = enTitle && enTitle !== ruTitle
162+
? `ResultV v${update.version} - ${ruTitle} / ${enTitle}`
163+
: `ResultV v${update.version} - ${ruTitle}`;
164+
fs.appendFileSync(process.env.GITHUB_OUTPUT, `release_name=${releaseName}\n`);
165+
NODE_EOF
166+
node prepare_release.cjs
129167
130168
- name: Download all workflow assets
131169
uses: actions/download-artifact@v4

.gitignore

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ release
2424
*.sln
2525
.agent
2626
.cursor
27+
.claude
2728

2829

2930
# Claude Superpowers
@@ -37,3 +38,15 @@ build/windows/installer/tmp/*
3738
*.timestamp-*.mjs
3839
/tmp.exe
3940
*~
41+
42+
# Local test artifacts
43+
/ResultV_test.exe
44+
/test.html
45+
46+
# Secrets and private build tools
47+
.env
48+
.env.*
49+
!.env.example
50+
tools/encrypt-sub/
51+
build-release.bat
52+
build-release.sh

README.en.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
</p>
1111

1212
<p align="center">
13-
<img src="https://img.shields.io/badge/version-3.0.2-blue.svg" alt="Version">
13+
<img src="https://img.shields.io/badge/version-3.1.0-blue.svg" alt="Version">
1414
<img src="https://img.shields.io/badge/desktop-Wails-27272f.svg" alt="Wails">
1515
<img src="https://img.shields.io/badge/backend-Go-00ADD8.svg" alt="Go">
1616
<img src="https://img.shields.io/badge/frontend-React_18-61dafb.svg" alt="React">
@@ -33,7 +33,7 @@
3333

3434
## Overview
3535

36-
ResultV **3.0.2** is a native desktop application built with **[Wails v2](https://wails.io/)**. The UI is **React 18** with **Vite** and **Tailwind CSS**; traffic is handled by a **Go** backend and **[sing-box](https://github.com/SagerNet/sing-box)** (with project-specific build tags in `wails.json`). The interface is localized with **i18next** (English and Russian).
36+
ResultV **3.1.0** is a native desktop application built with **[Wails v2](https://wails.io/)**. The UI is **React 18** with **Vite** and **Tailwind CSS**; traffic is handled by a **Go** backend and **[sing-box](https://github.com/SagerNet/sing-box)** (with project-specific build tags in `wails.json`). The interface is localized with **i18next** (English and Russian).
3737

3838
**Prebuilt releases:** GitHub Actions currently publishes **Windows amd64** artifacts (portable `.exe` and NSIS installer) when a `v*` tag is pushed. **macOS and Linux** code paths exist in the repository, but automated CI releases are currently Windows-only; other platforms will be available later due to the full migration of the project to the Go stack.
3939

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
</p>
1111

1212
<p align="center">
13-
<img src="https://img.shields.io/badge/version-3.0.2-blue.svg" alt="Version">
13+
<img src="https://img.shields.io/badge/version-3.1.0-blue.svg" alt="Version">
1414
<img src="https://img.shields.io/badge/desktop-Wails-27272f.svg" alt="Wails">
1515
<img src="https://img.shields.io/badge/backend-Go-00ADD8.svg" alt="Go">
1616
<img src="https://img.shields.io/badge/frontend-React_18-61dafb.svg" alt="React">
@@ -33,7 +33,7 @@
3333

3434
## О проекте
3535

36-
ResultV **3.0.2** — нативное настольное приложение на **[Wails v2](https://wails.io/)**. Интерфейс: **React 18**, **Vite**, **Tailwind CSS**; трафик обрабатывает бэкенд на **Go** и движок **[sing-box](https://github.com/SagerNet/sing-box)** (теги сборки заданы в `wails.json`). Локализация через **i18next** (русский и английский).
36+
ResultV **3.1.0** — нативное настольное приложение на **[Wails v2](https://wails.io/)**. Интерфейс: **React 18**, **Vite**, **Tailwind CSS**; трафик обрабатывает бэкенд на **Go** и движок **[sing-box](https://github.com/SagerNet/sing-box)** (теги сборки заданы в `wails.json`). Локализация через **i18next** (русский и английский).
3737

3838
**Готовые сборки:** в GitHub Actions публикуются артефакты **Windows amd64** (portable `.exe` и установщик NSIS) при push тега `v`*. Код содержит ветки под **macOS** и **Linux**, но автоматические релизы в CI сейчас только для Windows; остальные платформы будут доступны позже, в связи с полным переносом проекта на GO стек.
3939

0 commit comments

Comments
 (0)