-
Notifications
You must be signed in to change notification settings - Fork 11
58 lines (48 loc) · 2.08 KB
/
main.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
name: Build NikGapps Custom Package
on:
workflow_dispatch:
inputs:
ANDROID_VERSION:
description: " Enter the Target Android Version (eg: 10, 11, 12.1, 13 etc.)"
required: true
env:
TARGET_ANDROID_VERSION: ${{ github.event.inputs.ANDROID_VERSION }}
CONFIG: custom.config # Use custom.config to build the Package
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkouts
uses: actions/checkout@v2
- name: Cloning the Build Repo
run: |
git clone --depth=1 https://github.com/ri5h46h/build.git
- name: Cloning the Config Repo
run: |
git clone --depth=1 https://github.com/nikgapps/config.git
- name: Install the Required Packages from the repos
working-directory: build
run: |
sudo apt update -y
sudo apt install aapt -y
sudo python3 -m pip install wheel setuptools testresources
sudo pip3 install -r requirements.txt
- name: Setup Configs according to the Target Android Version input by user
run: |
cp ${CONFIG} config/${TARGET_ANDROID_VERSION}/custom.config
sed -i 's|TARGET_ANDROID_VERSION|#TARGET_ANDROID_VERSION|g' build/Config.py
printf "\nTARGET_ANDROID_VERSION = %s\n" "${TARGET_ANDROID_VERSION}" >> build/Config.py
- name: Build the Package
working-directory: build
run: |
python3 config_control.py --androidVersion ${TARGET_ANDROID_VERSION}
echo -e "\033[0;32m""### Build Completed Successfully!""\033[0m"
- name: Upload to WeTransfer using transfer
run: |
curl -sL https://git.io/file-transfer | bash
ls -al Releases/
ls -al Releases/${TARGET_ANDROID_VERSION}/
sha256sum Releases/${TARGET_ANDROID_VERSION}/NikGapps*.zip
./transfer wet --silent Releases/${TARGET_ANDROID_VERSION}/NikGapps*.zip
rm Releases/${TARGET_ANDROID_VERSION}/NikGapps*.zip
ls -al Releases/${TARGET_ANDROID_VERSION}/