.github: Generate and upload diff with patches #7
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 APK | |
env: | |
APKTOOL_VER: 2.7.0 | |
on: | |
push: | |
branches: | |
- ANE-9.1.0.401 | |
jobs: | |
build: | |
runs-on: ubuntu-22.04 | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-java@v3 | |
with: | |
distribution: 'semeru' | |
java-version: '11' | |
- name: Install aapt2 | |
run: sudo apt-get update && sudo apt-get install -y aapt | |
- uses: robinraju/release-downloader@v1.5 | |
with: | |
repository: 'iBotPeaches/Apktool' | |
tag: 'v${{ env.APKTOOL_VER }}' | |
fileName: 'apktool_${{ env.APKTOOL_VER }}.jar' | |
- run: java -jar apktool_${{ env.APKTOOL_VER }}.jar b . | |
- name: Generate diff file with patches | |
run: | | |
REPO_NAME=$(basename "$GITHUB_REPOSITORY") | |
git diff $(git rev-list --max-parents=0 HEAD) -- . ':(exclude).github' > "${REPO_NAME}_patch.diff" | |
- uses: actions/upload-artifact@v3 | |
with: | |
name: APK | |
path: dist/hwEmui.jar | |
- uses: actions/upload-artifact@v3 | |
with: | |
name: Patch | |
path: "${{ github.repository }}_patch.diff" |