mirror of
https://github.com/venera-app/venera.git
synced 2025-09-27 07:47:24 +00:00
fix windows build
This commit is contained in:
17
.github/workflows/main.yml
vendored
17
.github/workflows/main.yml
vendored
@@ -93,25 +93,18 @@ jobs:
|
||||
runs-on: windows-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- name: install yq
|
||||
run: choco install yq -y
|
||||
- name: install wget
|
||||
run: choco install wget -y
|
||||
- name: install dependencies
|
||||
run: |
|
||||
choco install yq -y
|
||||
pip install httpx
|
||||
- uses: subosito/flutter-action@v2
|
||||
with:
|
||||
channel: "stable"
|
||||
flutter-version-file: pubspec.yaml
|
||||
architecture: x64
|
||||
- name: install inno setup
|
||||
run: |
|
||||
choco install innosetup -y
|
||||
$inno_path = "C:\Program Files (x86)\Inno Setup 6"
|
||||
wget "https://raw.githubusercontent.com/kira-96/Inno-Setup-Chinese-Simplified-Translation/refs/heads/main/ChineseSimplified.isl" -OutFile "$inno_path\Languages\ChineseSimplified.isl"
|
||||
- run: flutter pub get
|
||||
- name: build
|
||||
run: |
|
||||
$inno_path = "C:\Program Files (x86)\Inno Setup 6\"
|
||||
$env:PATH += ";$inno_path"
|
||||
flutter pub get
|
||||
python windows/build.py
|
||||
- uses: actions/upload-artifact@v4
|
||||
with:
|
||||
|
@@ -33,7 +33,7 @@ WizardStyle=modern
|
||||
|
||||
[Languages]
|
||||
Name: "english"; MessagesFile: "compiler:Default.isl"
|
||||
Name: "chinesesimplified"; MessagesFile: "compiler:Languages\ChineseSimplified.isl"
|
||||
Name: "chinesesimplified"; MessagesFile: "{#RootPath}\windows\ChineseSimplified.isl"
|
||||
|
||||
[Tasks]
|
||||
Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked
|
||||
|
@@ -1,5 +1,6 @@
|
||||
import subprocess
|
||||
import os
|
||||
import httpx
|
||||
|
||||
file = open('pubspec.yaml', 'r')
|
||||
content = file.read()
|
||||
@@ -26,6 +27,13 @@ file = open('windows/build.iss', 'w')
|
||||
file.write(newContent)
|
||||
file.close()
|
||||
|
||||
if not os.path.exists("windows/ChineseSimplified.isl"):
|
||||
# download ChineseSimplified.isl
|
||||
url = "https://raw.githubusercontent.com/kira-96/Inno-Setup-Chinese-Simplified-Translation/refs/heads/main/ChineseSimplified.isl"
|
||||
response = httpx.get(url)
|
||||
with open('windows/ChineseSimplified.isl', 'wb') as file:
|
||||
file.write(response.content)
|
||||
|
||||
subprocess.run(["iscc", "windows/build.iss"], shell=True)
|
||||
|
||||
with open('windows/build.iss', 'w') as file:
|
||||
|
Reference in New Issue
Block a user