Skip to content

Download Status and ViewOnce | Disable Secure Flags #15

Download Status and ViewOnce | Disable Secure Flags

Download Status and ViewOnce | Disable Secure Flags #15

Workflow file for this run

name: Android CI
on:
push:
branches: [ "master" ]
paths:
- '**'
- '!update.json'
- '!.github/workflows/*.yml'
jobs:
build:
permissions: write-all
runs-on: ubuntu-latest
if: github.event_name == 'push'
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 to gradle.properties
run: |
echo ${{ secrets.KEY_STORE }} | base64 --decode > app/key.jks
printf "\nRELEASE_FILE=key.jks" >> gradle.properties
printf "\nRELEASE_PASSWORD=${{ secrets.PASSWORD }}" >> gradle.properties
printf "\nRELEASE_ALIAS=${{ secrets.ALIAS }}" >> gradle.properties
- name: Build and test app
run: |
./gradlew assembleRelease
- name: Upload artifacts
uses: actions/upload-artifact@v4
id: upload
with:
name: app-release
path: app/build/outputs/apk/release/app-release.apk
- name: Setup NodeJs
uses: actions/[email protected]
with:
node-version: 22
- name: Write Bot Files and Configure environment variables
run: |
APKVERSION=$(grep -Po 'versionName\s*=\s*"\K[^"]+' app/build.gradle.kts)
APKNEWPATH="app/build/outputs/apk/release/WaRevamp_$APKVERSION.apk"
cp app/build/outputs/apk/release/app-release.apk $APKNEWPATH
echo ${{ secrets.BOT_INDEX }} | base64 --decode > index.js
echo ${{ secrets.BOT_PACKAGE }} | base64 --decode > package.json
echo "CHANGE_LOG_PATH=change_log.txt" >> $GITHUB_ENV
echo "CHAT_ID=${{ secrets.CHAT_ID }}" >> $GITHUB_ENV
echo "FILE_PATH=$APKNEWPATH" >> $GITHUB_ENV
echo "BOT_TOKEN=${{ secrets.BOT_TOKEN }}" >> $GITHUB_ENV
- name: Install Dependencies
run: npm install
- name: Run Node.js script
run: node index.js