Skip to content

Commit 2b9044c

Browse files
committed
1
1 parent 99642e5 commit 2b9044c

34 files changed

+129
-139
lines changed

.github/workflows/build.yml

Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@ name: 构建
22
on:
33
push:
44
workflow_dispatch:
5+
inputs:
6+
version:
7+
description: '发布版本号(如 v3.0.0)'
8+
required: true
59

610
permissions:
711
contents: write
@@ -155,3 +159,52 @@ jobs:
155159
name: NamePicker-macOS-arm64
156160
path: |
157161
namepicker/build/macos/Build/Products/Release/*-macOS-arm64.zip
162+
163+
build_android:
164+
runs-on: ubuntu-latest
165+
steps:
166+
- name: Clone repository
167+
uses: actions/checkout@v4
168+
169+
- name: Set up Flutter
170+
uses: subosito/flutter-action@v2
171+
with:
172+
channel: stable
173+
174+
- name: Init flutter env
175+
run: |
176+
cd namepicker
177+
flutter pub get
178+
179+
- name: Build APK
180+
run: |
181+
cd namepicker
182+
flutter build apk --release
183+
184+
- name: Upload android artifact
185+
uses: actions/upload-artifact@v4
186+
with:
187+
name: NamePicker-Android-APK
188+
path: namepicker/build/app/outputs/flutter-apk/app-release.apk
189+
190+
release:
191+
needs: [build_windows, build_linux, build_macos_intel, build_macos_arm, build_android]
192+
if: ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.version != '' }}
193+
runs-on: ubuntu-latest
194+
steps:
195+
- name: Checkout
196+
uses: actions/checkout@v5
197+
198+
- name: Download all artifacts
199+
uses: actions/download-artifact@v4
200+
with:
201+
path: artifacts
202+
203+
- name: Create Release
204+
uses: softprops/action-gh-release@v2
205+
with:
206+
tag_name: ${{ github.event.inputs.version }}
207+
name: NamePicker ${{ github.event.inputs.version }}
208+
body_path: CHANGELOG.md
209+
files: |
210+
artifacts/**/*

CHANGELOG.md

Lines changed: 1 addition & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1 @@
1-
> [!caution]
2-
> ## 请勿在生产环境使用该版本!
3-
>
4-
> 该版本使用了flutter完全重构,缺失很多功能,并且可能存在一些潜在的Bug,仅供尝鲜
5-
>
6-
> 生产环境请使用v2.2.0d6 Release
7-
8-
## 实现的功能
9-
10-
- 选择抽选学号范围
11-
12-
- 设置界面
13-
14-
- 自动获取系统主题色
1+
这只是一个测试自动发版系统的release

namepicker/android/app/src/main/AndroidManifest.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
<application
33
android:label="NamePicker"
44
android:name="${applicationName}"
5-
android:icon="@mipmap/ic_launcher">
5+
android:icon="@mipmap/launcher_icon">
66
<activity
77
android:name=".MainActivity"
88
android:exported="true"
1.77 KB
Loading
1.2 KB
Loading
2.33 KB
Loading
3.46 KB
Loading
4.65 KB
Loading

namepicker/icon.png

21.6 KB
Loading

namepicker/ios/Runner.xcodeproj/project.pbxproj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -427,7 +427,7 @@
427427
isa = XCBuildConfiguration;
428428
buildSettings = {
429429
ALWAYS_SEARCH_USER_PATHS = NO;
430-
ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES;
430+
ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = AppIcon;
431431
CLANG_ANALYZER_NONNULL = YES;
432432
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
433433
CLANG_CXX_LIBRARY = "libc++";
@@ -484,7 +484,7 @@
484484
isa = XCBuildConfiguration;
485485
buildSettings = {
486486
ALWAYS_SEARCH_USER_PATHS = NO;
487-
ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES;
487+
ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = AppIcon;
488488
CLANG_ANALYZER_NONNULL = YES;
489489
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
490490
CLANG_CXX_LIBRARY = "libc++";

0 commit comments

Comments
 (0)