Skip to content

Commit 7fa823d

Browse files
authored
Merge pull request #16 from unDefFtr/master
ci(workflow): 修复 Linux 平台自动化构建
2 parents ab5f206 + 5ebab35 commit 7fa823d

1 file changed

Lines changed: 32 additions & 27 deletions

File tree

.github/workflows/build.yml

Lines changed: 32 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -34,30 +34,35 @@ jobs:
3434
name: NamePicker-Windows-x64
3535
path: |
3636
namepicker\build\windows\x64\runner\Release
37-
# build_linux:
38-
# runs-on: ubuntu-latest
39-
# steps:
40-
# - name: Clone repository
41-
# uses: actions/checkout@v4
42-
43-
# - name: Set up Flutter
44-
# uses: subosito/flutter-action@v2
45-
# with:
46-
# channel: stable
47-
48-
# - name: Init flutter env
49-
# run: |
50-
# cd namepicker
51-
# flutter pub get
52-
53-
# - name: Build linux app
54-
# run: |
55-
# cd namepicker
56-
# flutter build linux
57-
58-
# - name: Upload linux artifact
59-
# uses: actions/upload-artifact@v4
60-
# with:
61-
# name: NamePicker-Linux-x64
62-
# path: |
63-
# namepicker\build\linux\x64\runner\Release
37+
build_linux:
38+
runs-on: ubuntu-latest
39+
steps:
40+
- name: Clone repository
41+
uses: actions/checkout@v4
42+
43+
- name: Set up Flutter
44+
uses: subosito/flutter-action@v2
45+
with:
46+
channel: stable
47+
48+
- name: Install Linux dependencies
49+
run: |
50+
sudo apt-get update
51+
sudo apt-get install -y clang cmake ninja-build pkg-config libgtk-3-dev
52+
53+
- name: Init flutter env
54+
run: |
55+
cd namepicker
56+
flutter pub get
57+
58+
- name: Build linux app
59+
run: |
60+
cd namepicker
61+
flutter build linux
62+
63+
- name: Upload linux artifact
64+
uses: actions/upload-artifact@v4
65+
with:
66+
name: NamePicker-Linux-x64
67+
path: |
68+
namepicker/build/linux/x64/release/bundle

0 commit comments

Comments
 (0)