APK-J-PY Build #3
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: APK-J-PY Build | |
on: | |
# push: | |
# branches: | |
# - main | |
# pull_request: | |
workflow_dispatch: | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- name: Clone Project | |
run: git clone -b main --depth=1 https://github.com/XiaoRanLiu3119/TVBoxOS-Mobile | |
- name: DIY | |
run: | | |
chmod +x diy-J-PY.sh | |
bash ${{ github.workspace }}/diy-J-PY.sh | |
- name: Build With Gradle | |
run: | | |
num=$(find ${{ github.workspace }} -name gradlew | awk -F"/" '{print NF-1}') | |
DIR=$(find ${{ github.workspace }} -name gradlew | cut -d \/ -f$num) | |
cd $DIR | |
chmod +x gradlew | |
./gradlew assemblerelease --build-cache --parallel --daemon --warning-mode all | |
- name: Prepare App | |
run: | | |
mkdir -p ${{ github.workspace }}/apk/ | |
for file in `find ~ -name "*.apk" -print`; do | |
mv "$file" ${{ github.workspace }}/apk/ | |
done | |
- name: Upload App To Artifact | |
uses: actions/upload-artifact@v3 | |
with: | |
name: com.github.tvbox.osc | |
path: ${{ github.workspace }}/apk/* |