Release/v1.2.0 (#25) #141
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI Build | |
on: | |
push: | |
branches: [ master ] | |
paths-ignore: | |
- '**/*.md' | |
- '**/*.gitignore' | |
- '**/*.gitattributes' | |
permissions: | |
contents: read | |
env: | |
DOTNET_NOLOGO: true # Disable the .NET logo | |
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: true # Disable the .NET first time experience | |
DOTNET_CLI_TELEMETRY_OPTOUT: true # Disable sending .NET CLI telemetry | |
jobs: | |
# MAUI Android Build | |
build-android: | |
runs-on: windows-2022 | |
name: Android Build | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- name: Versioning | |
uses: dotnet/nbgv@master | |
id: nbgv | |
- name: Restore Dependencies | |
run: dotnet restore PursuitTimer | |
- name: Build MAUI Android | |
run: dotnet build PursuitTimer -c Release -f net8.0-android --no-restore /p:AndroidSigningKeyPass=${{ secrets.PLAYSTORE_PASS }} /p:AndroidSigningStorePass=${{ secrets.PLAYSTORE_PASS }} | |
- name: Publish MAUI Android | |
run: dotnet publish PursuitTimer -c Release -f net8.0-android --no-restore | |
- name: Upload Android Artifact | |
uses: actions/[email protected] | |
with: | |
name: android-ci-build | |
path: PursuitTimer/bin/Release/net8.0-android/*Signed.a* | |
- name: Publish to Play Store | |
uses: r0adkll/upload-google-play@v1 | |
with: | |
serviceAccountJsonPlainText: ${{ secrets.APPSTORE_SERVICE_ACCOUNT }} | |
packageName: me.veloti.pursuittimer | |
releaseFiles: PursuitTimer/bin/Release/net8.0-android/publish/me.veloti.pursuittimer-Signed.aab | |
track: alpha | |
status: completed | |
# MAUI iOS Build | |
build-ios: | |
runs-on: macos-13 | |
name: iOS Build | |
steps: | |
- uses: maxim-lobanov/setup-xcode@v1 | |
with: | |
xcode-version: '15.1' | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- name: Versioning | |
uses: dotnet/nbgv@master | |
id: nbgv | |
- name: Install MAUI Workloads | |
run: | | |
dotnet workload install ios --ignore-failed-sources | |
dotnet workload install maui --ignore-failed-sources | |
- name: Restore Dependencies | |
run: dotnet restore PursuitTimer -r ios-arm64 | |
- name: Import Code-Signing Certificates | |
uses: Apple-Actions/import-codesign-certs@v2 | |
with: | |
p12-file-base64: ${{ secrets.CERTIFICATES_P12_BASE64 }} | |
#p12-filepath: 'DistributionCertVeloTimePursuitTimer.p12' | |
p12-password: ${{ secrets.CERTIFICATES_P12_PASSWORD }} | |
- name: Download Apple Provisioning Profiles | |
uses: Apple-Actions/download-provisioning-profiles@v1 | |
with: | |
bundle-id: 'me.veloti.pursuittimer' | |
issuer-id: ${{ secrets.APPSTORE_ISSUER_ID }} | |
api-key-id: ${{ secrets.APPSTORE_KEY_ID }} | |
api-private-key: ${{ secrets.APPSTORE_PRIVATE_KEY }} | |
- name: Build MAUI iOS | |
run: dotnet build PursuitTimer -c Release -f net8.0-ios --no-restore | |
- name: Publish MAUI iOS | |
run: dotnet publish PursuitTimer -c Release -f:net8.0-ios -r ios-arm64 | |
- name: Upload iOS Artifact | |
uses: actions/[email protected] | |
with: | |
name: ios-ci-build | |
path: PursuitTimer/bin/Release/net8.0-ios/**/*.app/ | |
- name: Upload iOS Package | |
uses: actions/[email protected] | |
with: | |
name: ios-ci-package | |
path: PursuitTimer/bin/Release/net8.0-ios/**/*.ipa | |
- name: Make appstore key ready | |
run: echo "${{ secrets.APPSTORE_PRIVATE_KEY }}" > Authkey_${{ secrets.APPSTORE_KEY_ID }}.p8 | |
- name: Publish to App Store | |
env: | |
API_PRIVATE_KEYS_DIR: . | |
run: xcrun altool --upload-package PursuitTimer/bin/Release/net8.0-ios/ios-arm64/publish/PursuitTimer.ipa --type ios --apple-id 1630437751 --bundle-id me.velotimer.pursuittimer --apiKey ${{ secrets.APPSTORE_KEY_ID }} --apiIssuer ${{ secrets.APPSTORE_ISSUER_ID }} --bundle-version ${{ steps.nbgv.outputs.CloudBuildNumber }} --bundle-short-version-string ${{ steps.nbgv.outputs.SemVer2 }} |