-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
383faa1
commit 7068165
Showing
3 changed files
with
80 additions
and
43 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,37 +1,37 @@ | ||
name: Build and deploy | ||
name: Full build | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
description: Builds and tests | ||
|
||
jobs: | ||
android: | ||
runs-on: windows-latest | ||
steps: | ||
runs: | ||
using: "composite" | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 # Need full history for git versioning | ||
|
||
- name: Create keystore | ||
id: create_keystore | ||
uses: timheuer/[email protected] | ||
with: | ||
fileName: release.keystore | ||
encodedString: "${{ secrets.RELEASE_KEYSTORE_BASE64 }}" | ||
|
||
- uses: actions/setup-dotnet@v3 | ||
|
||
- name: Show .NET info | ||
shell: bash | ||
run: dotnet --info | ||
|
||
- name: Install .NET MAUI | ||
shell: bash | ||
run: dotnet workload install maui android wasm-tools | ||
|
||
- name: Test | ||
shell: bash | ||
run: dotnet test | ||
|
||
- name: Create keystore | ||
id: create_keystore | ||
uses: timheuer/[email protected] | ||
with: | ||
fileName: release.keystore | ||
encodedString: "${{ secrets.RELEASE_KEYSTORE_BASE64 }}" | ||
|
||
- name: Build for Android | ||
shell: bash | ||
run: > | ||
dotnet publish JournalApp\JournalApp.csproj -o publish -c:Release -f:net8.0-android | ||
-p:AndroidKeyStore=True | ||
|
@@ -40,31 +40,6 @@ jobs: | |
-p:AndroidSigningKeyAlias="key" | ||
-p:AndroidSigningKeyPass="${{ secrets.RELEASE_KEYSTORE_PASS }}" | ||
- name: Show build output | ||
- name: List build output | ||
shell: bash | ||
run: ls publish | ||
|
||
- uses: actions/upload-artifact@v4 | ||
with: | ||
path: | | ||
publish | ||
# publish/*.apk | ||
# publish/*.aab | ||
if-no-files-found: error | ||
|
||
# - name: Create GitHub release | ||
# uses: softprops/action-gh-release@v1 | ||
# with: | ||
# files: | | ||
# publish/*.apk | ||
# publish/*.aab | ||
# fail_on_unmatched_files: true | ||
# generate_release_notes: true | ||
|
||
- name: Upload to Play Store | ||
uses: r0adkll/upload-google-play@v1 | ||
with: | ||
serviceAccountJsonPlainText: "${{ secrets.SERVICE_ACCOUNT_JSON }}" | ||
packageName: com.danielchalmers.journalapp | ||
releaseFiles: publish/*-Signed.aab | ||
track: beta | ||
status: completed |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
name: Build | ||
|
||
on: | ||
push: | ||
branches-ignore: | ||
- release | ||
pull_request: | ||
|
||
jobs: | ||
build: | ||
runs-on: windows-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- uses: ./.github/actions/full-build | ||
|
||
- uses: actions/upload-artifact@v4 | ||
with: | ||
path: | | ||
publish | ||
# publish/*.apk | ||
# publish/*.aab | ||
if-no-files-found: error |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
name: Deploy | ||
|
||
on: | ||
push: | ||
branches: | ||
- release | ||
|
||
jobs: | ||
android: | ||
runs-on: windows-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- uses: ./.github/actions/full-build | ||
|
||
- uses: dotnet/[email protected] | ||
id: nbgv | ||
|
||
- name: Create GitHub release | ||
uses: ncipollo/release-action@v1 | ||
with: | ||
tag: "v${{ steps.nbgv.outputs.SimpleVersion }}" | ||
artifacts: "publish/*.apk" | ||
allowUpdates: true | ||
removeArtifacts: true | ||
replacesArtifacts: true | ||
artifactErrorsFailBuild: true | ||
makeLatest: true | ||
generateReleaseNotes: true | ||
prerelease: ${{ !steps.nbgv.outputs.PublicRelease }} | ||
|
||
- name: Upload to Play Store | ||
uses: r0adkll/upload-google-play@v1 | ||
with: | ||
serviceAccountJsonPlainText: "${{ secrets.SERVICE_ACCOUNT_JSON }}" | ||
packageName: com.danielchalmers.journalapp | ||
releaseFiles: publish/*-Signed.aab | ||
track: beta | ||
status: completed |