Skip to content

SkyHawk-RP Builder - A12 EXYNOS - NO FBE #1

SkyHawk-RP Builder - A12 EXYNOS - NO FBE

SkyHawk-RP Builder - A12 EXYNOS - NO FBE #1

name: SkyHawk-RP Builder - A12 EXYNOS - NO FBE
on:
workflow_dispatch:
inputs:
MANIFEST_BRANCH:
description: 'Manifest Branch'
required: true
default: 'v3_11.0'
type: choice
options:
- 'v3_9.0'
- 'v3_10.0'
- 'v3_11.0'
- 'shrp-12.1'
DEVICE_TREE_URL:
description: 'Device Tree URL'
required: true
default: 'https://github.com/SUFandom/A12-Exynos-Recovery-devtree-shrp'
DEVICE_TREE_BRANCH:
description: 'Device Tree Branch'
required: true
default: 'UA-aug'
BRAND:
description: 'Brand'
required: true
default: 'samsung'
DEVICE_CODE:
description: 'Device Code'
required: true
default: 'a12s'
MAKEFILE_TYPE:
description: 'Makefile Type'
required: true
default: 'twrp'
type: choice
options:
- 'omni'
- 'twrp'
ADD_EXPORT:
description: 'Add "export"'
required: false
BUILD_TARGET:
description: 'Build Target'
required: true
default: 'recovery'
type: choice
options:
- 'recovery'
- 'boot'
- 'vendorboot'
jobs:
SkyHawk-Recovery-Project:
runs-on: ubuntu-20.04
permissions:
contents: write
steps:
- name: Checkout
uses: actions/checkout@master
- name: Free up space
uses: rokibhasansagar/slimhub_actions@main # USES CLEANUP TOOLS
- name: Set up the Compilation environment
run: |
sudo apt-get -y install bc build-essential zip curl libstdc++6 git wget python python2 gcc clang libssl-dev rsync flex bison aria2 openjdk-8-jdk make
mkdir ~/bin
curl https://storage.googleapis.com/git-repo-downloads/repo > ~/bin/repo
chmod a+x ~/bin/repo
sudo ln -sf ~/bin/repo /usr/bin/repo
- name: Git Config
run: |
rm -rf shrp
mkdir shrp
cd shrp
git config --global user.email "bluepearl394@gmail.com"
git config --global user.name "SUFandom"
- name: Sync Minimal Manifest
run: |
cd shrp
repo init --depth=1 -u https://github.com/SUFandom/shrp-manifest -b ${{ inputs.MANIFEST_BRANCH }}
- name: Sync Source
run: |
cd shrp
repo sync -c -j$(nproc --all) --force-sync --no-clone-bundle --no-tags
rm -rf .rep
continue-on-error: true
- name: Clone Device Tree
run: |
git clone -b ${{ inputs.DEVICE_TREE_BRANCH }} ${{ inputs.DEVICE_TREE_URL }} shrp/device/${{ inputs.BRAND }}/${{ inputs.DEVICE_CODE }}
- name: Compile Custom Recovery
run: |
cd shrp
chmod 777 build/envsetup.sh
export ALLOW_MISSING_DEPENDENCIES=true
${{ inputs.ADD_EXPORT }}
. build/envsetup.sh
lunch ${{ inputs.MAKEFILE_TYPE }}_${{ inputs.DEVICE_CODE }}-eng
mka ${{ inputs.BUILD_TARGET }}image
continue-on-error: true
- name: Rename File
run: |
cd shrp/out/target/product/${{ inputs.DEVICE_CODE }}
mv ${{ inputs.BUILD_TARGET }}.img SHRP-Unofficial_${{ inputs.DEVICE_CODE }}.img
- name: Upload to Artifacts
uses: actions/upload-artifact@v3
with:
name: SHRP-Unofficial_${{ inputs.DEVICE_CODE }}.img
path: shrp/out/target/product/${{ inputs.DEVICE_CODE }}/SHRP-Unofficial_${{ inputs.DEVICE_CODE }}.img
# - name: Upload to Release
# uses: softprops/action-gh-release@v1
# with:
# files: |
# workspace/out/target/product/${{ github.event.inputs.DEVICE_NAME }}/${{ github.event.inputs.BUILD_TARGET }}.img
# workspace/out/target/product/${{ github.event.inputs.DEVICE_NAME }}/*.zip
# workspace/out/target/product/${{ github.event.inputs.DEVICE_NAME }}/*vendor*.img
# name: ${{ github.event.inputs.DEVICE_NAME }}-${{ github.run_id }}
# tag_name: ${{ github.run_id }}
# body: |
# Manifest: ${{ github.event.inputs.MANIFEST_BRANCH }}
# Device: ${{ github.event.inputs.DEVICE_NAME }}
# Target: ${{ github.event.inputs.BUILD_TARGET }}.img
# env:
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}