Skip to content

Commit

Permalink
add github actions
Browse files Browse the repository at this point in the history
  • Loading branch information
molihuan committed Nov 20, 2023
1 parent 389eaf6 commit 26c3261
Show file tree
Hide file tree
Showing 3 changed files with 72 additions and 1 deletion.
38 changes: 38 additions & 0 deletions .github/workflows/release_android.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Release Android Apk
on:
# 手动触发
workflow_dispatch:
jobs:
build:
name: Build
runs-on: windows-latest
steps:
# 使用本项目
- uses: actions/checkout@v3
# 设置jdk
- uses: actions/setup-java@v3.13.0
with:
distribution: 'zulu'
# The Java version to set up. Takes a whole or semver Java version. See examples of supported syntax in README file
java-version: 17
#设置flutter
- uses: subosito/flutter-action@v2.12.0
with:
# The Flutter version to make available on the path
flutter-version: 3.13.9
# The Flutter build release channel
channel: # optional, default is stable

# Get flutter dependencies.
- run: flutter pub get
# Build apk.打包各架构版本
- run: flutter build apk --split-per-abi
# Upload generated apk to the artifacts.
- uses: actions/upload-artifact@v3.1.3
with:
# Artifact name
name: release-android
# 导出文件夹
path: build/app/outputs/flutter-apk/
# The desired behavior if no files are found using the provided path.

33 changes: 33 additions & 0 deletions .github/workflows/release_ios.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Release IOS ipa
on:
# 手动触发
workflow_dispatch:
jobs:
build:
name: Build
runs-on: macos-latest
steps:
# 使用本项目
- uses: actions/checkout@v3
#设置flutter
- uses: subosito/flutter-action@v2.12.0
with:
# The Flutter version to make available on the path
flutter-version: 3.13.9
# The Flutter build release channel
channel: # optional, default is stable

# Get flutter dependencies.
- run: flutter pub get
# TODO Build ios


# Upload generated apk to the artifacts.
- uses: actions/upload-artifact@v3.1.3
with:
# Artifact name
name: release-ios
# 导出文件夹
path: ios/build/Runner.ipa
# The desired behavior if no files are found using the provided path.

2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

#### 还在规划内测阶段!!!


[![Build status](https://build.appcenter.ms/v0.1/apps/fd36227c-9ac2-4d77-9ca3-232d5b89bf0f/branches/master/badge)](https://appcenter.ms)

# 我们会一直维护这个软件,除非江水为竭🌊,冬雷震震⚡,没有Star⭐。直至时间的尽头🕑。

Expand Down

0 comments on commit 26c3261

Please sign in to comment.