Skip to content

Commit

Permalink
Update workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
Xtr126 authored Jul 27, 2024
1 parent c9181b6 commit 42636ff
Show file tree
Hide file tree
Showing 2 changed files with 47 additions and 1 deletion.
46 changes: 46 additions & 0 deletions .github/workflows/build-apk.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: Build and Upload APK

on:
workflow_dispatch:
push:
tags:
- "v*"

jobs:

build:

runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Set up JDK 17
uses: actions/setup-java@v4
with:
java-version: '17'
distribution: 'temurin'
cache: gradle

- name: Grant execute permission for gradlew
run: chmod +x gradlew

- name: Write key
run: |
if [ ! -z "${{ secrets.KEYSTORE }}" ]; then
{
echo storePassword='${{ secrets.KEYSTORE_PASSWORD }}'
echo keyPassword='${{ secrets.KEY_PASSWORD }}'
echo keyAlias='${{ secrets.KEY_ALIAS }}'
echo storeFile='../keystore.jks'
} > keystore.properties
echo '${{ secrets.KEYSTORE }}' | base64 -d > keystore.jks
fi
- name: Build with Gradle
run: ./gradlew app:assembleRelease

- uses: actions/upload-artifact@v4
with:
name: my-artifact
path: app/build/outputs/apk/release/XtMapper-universal-release-v2.1.5.apk

Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ jobs:
mv ./github-pages ./app/src/main/assets/XtMapper-docs
- name: Build with Gradle
run: ./gradlew assembleRelease
run: ./gradlew app:assembleRelease

- name: Release
uses: "marvinpinto/action-automatic-releases@latest"
Expand Down

0 comments on commit 42636ff

Please sign in to comment.