Update main.yml #1
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: Build .NET MAUI App Android | |
on: | |
push: | |
branches: [ "master" ] | |
pull_request: | |
branches: [ "master" ] | |
jobs: | |
build: | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Setup Keystore File | |
run: | | |
echo "${{ secrets.KEYSTORE_FILE }}" > myapp.keystore.asc | |
gpg -d --passphrase "${{ secrets.KEYSTORE_PASSWORD_GPG }}" --batch myapp.keystore.asc > myapp.keystore | |
- name: Setup .NET | |
uses: actions/setup-dotnet@v2 | |
with: | |
dotnet-version: 6.0.x | |
- name: Install .NET MAUI | |
run: dotnet workload install maui | |
- name: Restore dependencies | |
run: dotnet restore | |
- name: Build | |
run: dotnet build DownloadManager/DownloadManager.csproj -c Release -f net6.0-android /p:AndroidSigningKeyStore=myapp.keystore /p:AndroidSigningKeyAlias=ghactionskey /p:AndroidSigningKeyPass="${{ secrets.KEYSTORE_PASSWORD }}" /p:AndroidSigningStorePass="${{ secrets.KEYSTORE_PASSWORD_ALIAS }}" --no-restore | |
- name: Upload a Build Artifact | |
uses: actions/[email protected] | |
with: | |
path: | | |
./**/*.aab | |
./**/*.apk |