Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: plum-tech/mimir
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v2.6.4+501
Choose a base ref
...
head repository: plum-tech/mimir
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: master
Choose a head ref
Loading
Showing 567 changed files with 1,915 additions and 35,720 deletions.
17 changes: 0 additions & 17 deletions .github/dependabot.yml

This file was deleted.

66 changes: 66 additions & 0 deletions .github/workflows/build-android-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
name: Flutter Build Android Release

on: workflow_dispatch

jobs:
build_android:
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/master'

steps:
- uses: actions/checkout@v4
with:
repository: plum-tech/mimir-x
token: ${{ secrets.MIMIR_GITHUB_TOKEN }}
fetch-depth: 0

- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 9

- uses: actions/setup-node@v4
with:
node-version: 22
cache: 'pnpm'
cache-dependency-path: tools/pnpm-lock.yaml

- name: Pnpm install
run: |
cd tools && pnpm i && pnpm build && cd ..
- name: Install JDK 17
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '17'

- name: Install Flutter
uses: subosito/flutter-action@v2
with:
channel: stable
cache: true
flutter-version-file: pubspec.yaml

- name: Build APK
run: |
flutter config --no-cli-animations
flutter build apk --release --target-platform android-arm,android-arm64 --split-per-abi
- name: Sign APK
uses: r0adkll/sign-android-release@v1
id: sign_apk
with:
releaseDirectory: build/app/outputs/flutter-apk
signingKeyBase64: ${{ secrets.APK_SIGN_JKS_BASE64 }}
keyStorePassword: ${{ secrets.APK_SIGN_JKS_PASSWORD }}
keyPassword: ${{ secrets.APK_SIGN_ALIAS_PASS }}
alias: ${{ secrets.APK_SIGN_ALIAS }}
env:
BUILD_TOOLS_VERSION: "34.0.0"

- name: Publish Android Artifact
uses: actions/upload-artifact@v4
with:
name: Android-release
path: build/app/outputs/flutter-apk/*-signed.apk
78 changes: 78 additions & 0 deletions .github/workflows/build-ios.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
name: Flutter Build iOS

on: workflow_dispatch

jobs:
build_ios:
runs-on: macos-15
steps:
- uses: actions/checkout@v4
with:
repository: plum-tech/mimir-x
token: ${{ secrets.MIMIR_GITHUB_TOKEN }}

- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 9

- uses: actions/setup-node@v4
with:
node-version: 22
cache: 'pnpm'
cache-dependency-path: tools/pnpm-lock.yaml

- name: Pnpm install
run: |
cd tools && pnpm i && pnpm build && cd ..
- name: Change Develop to Distribution
run: |
pnpm run to-distro
- name: Install Apple Certificate
uses: apple-actions/import-codesign-certs@v3
with:
p12-file-base64: ${{ secrets.P12_BASE64 }}
p12-password: ${{ secrets.P12_PASSWORD }}

- name: Install the provisioning profile
env:
PROVISIONING_CERTIFICATE_BASE64: ${{ secrets.PROVISIONING_PROFILE_BASE64 }}
run: |
PP_PATH=$RUNNER_TEMP/build_pp.mobileprovision
echo -n "$PROVISIONING_CERTIFICATE_BASE64" | base64 --decode --output $PP_PATH
mkdir -p ~/Library/MobileDevice/Provisioning\ Profiles
cp $PP_PATH ~/Library/MobileDevice/Provisioning\ Profiles
- name: Install Flutter
uses: subosito/flutter-action@v2
with:
channel: stable
cache: true
flutter-version-file: pubspec.yaml

- name: Build iOS
run: |
flutter config --no-cli-animations
flutter build ios --release --no-codesign
- name: Build resolve Swift dependencies
run: |
xcodebuild -resolvePackageDependencies -workspace ios/Runner.xcworkspace -scheme Runner -configuration Release
- name: Build xArchive
run: |
xcodebuild -workspace ios/Runner.xcworkspace -scheme Runner -configuration Release DEVELOPMENT_TEAM="TGBYYVM7AB" -sdk 'iphoneos' -destination 'generic/platform=iOS' -archivePath build-output/app.xcarchive PROVISIONING_PROFILE="05f6171f-60f5-45f4-a6e8-40d042c29e91" clean archive CODE_SIGN_IDENTITY="Apple Distribution: Shanghai Plum Technology Ltd. (TGBYYVM7AB)"
- name: Export ipa
run: |
xcodebuild -exportArchive -archivePath build-output/app.xcarchive -exportPath build-output/ios -exportOptionsPlist ios/ExportOptions.plist
- name: Publish iOS Artifact
uses: actions/upload-artifact@v4
with:
name: iOS-release
path: build-output/ios/life.mysit.SITLife.ipa
87 changes: 41 additions & 46 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,15 @@
name: 1.Flutter Build
name: Flutter Build

on: workflow_dispatch
permissions: write-all
on:
workflow_dispatch:
inputs:
deploy_app_store:
description: 'Deploy on App Store connect'
required: true
default: true
type: boolean

env:
flutter_version: '3.24.3'
permissions: write-all

jobs:
build_android:
@@ -14,6 +19,8 @@ jobs:
steps:
- uses: actions/checkout@v4
with:
repository: plum-tech/mimir-x
token: ${{ secrets.MIMIR_GITHUB_TOKEN }}
fetch-depth: 0

- name: Install pnpm
@@ -29,11 +36,11 @@ jobs:

- name: Pnpm install
run: |
cd tools && pnpm i && cd ..
cd tools && pnpm i && pnpm build && cd ..
- name: Change version
run: |
node tools/increment-build-number.mjs
pnpm run increment-build-number
- name: Install JDK 17
uses: actions/setup-java@v4
@@ -44,17 +51,14 @@ jobs:
- name: Install Flutter
uses: subosito/flutter-action@v2
with:
flutter-version: ${{ env.flutter_version }}
channel: stable
cache: true

- name: Setup Flutter
run: |
flutter config --no-cli-animations
flutter-version-file: pubspec.yaml

- name: Build APK
run: |
flutter build apk --target-platform android-arm,android-arm64
flutter config --no-cli-animations
flutter build apk --release --target-platform android-arm,android-arm64
- name: Sign APK
uses: r0adkll/sign-android-release@v1
@@ -75,12 +79,14 @@ jobs:
path: build/app/outputs/flutter-apk/*-signed.apk

build_ios:
runs-on: macos-14 # macos-latest is macos-12 actually, and iOS 17+ SDK not supported
if: github.ref == 'refs/heads/master'
runs-on: macos-15
if: github.ref == 'refs/heads/master' && ${{ inputs.deploy_app_store }}

steps:
- uses: actions/checkout@v4
with:
repository: plum-tech/mimir-x
token: ${{ secrets.MIMIR_GITHUB_TOKEN }}
fetch-depth: 0

- name: Install pnpm
@@ -96,15 +102,15 @@ jobs:

- name: Pnpm install
run: |
cd tools && pnpm i && cd ..
cd tools && pnpm i && pnpm build && cd ..
- name: Change version
run: |
node tools/increment-build-number.mjs
pnpm run increment-build-number
- name: Change Develop to Distribution
run: |
node tools/to-distro.mjs
pnpm run to-distro
- name: Install Apple Certificate
uses: apple-actions/import-codesign-certs@v3
@@ -126,16 +132,13 @@ jobs:
- name: Install Flutter
uses: subosito/flutter-action@v2
with:
flutter-version: ${{ env.flutter_version }}
channel: stable
cache: true

- name: Setup Flutter
run: |
flutter config --no-cli-animations
flutter-version-file: pubspec.yaml

- name: Build iOS
run: |
flutter config --no-cli-animations
flutter build ios --release --no-codesign
- name: Build resolve Swift dependencies
@@ -162,6 +165,8 @@ jobs:
steps:
- uses: actions/checkout@v4
with:
repository: plum-tech/mimir-x
token: ${{ secrets.MIMIR_GITHUB_TOKEN }}
fetch-depth: 0

- name: Install pnpm
@@ -177,54 +182,44 @@ jobs:

- name: Pnpm install
run: |
cd tools && pnpm i && cd ..
cd tools && pnpm i && pnpm build && cd ..
- name: Change version and push tag
- name: Change version and commit tag
run: |
git config --global user.email "github-actions[bot]@users.noreply.github.com"
git config --global user.name "github-actions[bot]"
node tools/increment-build-number.mjs --push
pnpm run increment-build-number --commit
- name: Get iOS Artifact
if: github.repository == 'plum-tech/mimir'
uses: actions/download-artifact@v4
with:
name: iOS-release
path: build/

- name: Deploy to App Store (TestFlight)
if: github.repository == 'plum-tech/mimir'
uses: apple-actions/upload-testflight-build@v1
with:
app-path: ${{ github.workspace }}/build/life.mysit.SITLife.ipa
issuer-id: ${{ secrets.APP_STORE_CONNECT_ISSUER_ID }}
api-key-id: ${{ secrets.APP_STORE_CONNECT_API_KEY_ID }}
api-private-key: ${{ secrets.APP_STORE_CONNECT_API_PRIVATE_KEY }}

- name: Push changes
uses: ad-m/github-push-action@master
with:
repository: plum-tech/mimir-x
github_token: ${{ secrets.MIMIR_GITHUB_TOKEN }}
branch: ${{ github.ref }}

- name: Get Android Artifact
if: github.repository == 'plum-tech/mimir'
uses: actions/download-artifact@v4
with:
name: Android-release
path: build/

- name: Upload preview file onto SIT-MC server
if: github.repository == 'plum-tech/mimir'
continue-on-error: true
env:
SITMC_TEMP_SERVER_AUTH: ${{ secrets.SITMC_TEMP_SERVER_AUTH }}
run: |
node tools/upload-sitmc.mjs build/app-release-signed.apk -d mimir-preview/latest.apk
- name: Push changes
uses: ad-m/github-push-action@master
with:
branch: ${{ github.ref }}

- name: Notify the latest building
if: github.repository == 'plum-tech/mimir'
- name: Publish preview version
continue-on-error: true
env:
QQBOT_URL: ${{ secrets.gocq_sendgroupmsg_url }}
MIMIR_VERSION_ADMIN_TOKEN: ${{ secrets.MIMIR_VERSION_ADMIN_TOKEN }}
run: |
node tools/bot-notify-build.mjs
pnpm run publish-preview --upload build/app-release-signed.apk
Loading