ci: support deprecated kernel versions (#648)

This commit is contained in:
weishu
2023-06-18 12:47:29 +08:00
committed by GitHub
parent a48d7b112f
commit 1703c16948
4 changed files with 26 additions and 1 deletions

View File

@@ -90,6 +90,12 @@ jobs:
git clone https://gerrit.googlesource.com/git-repo
mkdir android-kernel && cd android-kernel
../git-repo/repo init --depth=1 --u https://android.googlesource.com/kernel/manifest -b common-${{ inputs.tag }}
REMOTE_BRANCH=$(git ls-remote https://android.googlesource.com/kernel/common ${{ inputs.tag }})
if grep -q deprecated <<< $REMOTE_BRANCH; then
echo "Found deprecated branch: ${{ inputs.tag }}"
sed -i 's/"${{ inputs.tag }}"/"deprecated\/${{ inputs.tag }}"/g' .repo/manifests/default.xml
cat .repo/manifests/default.xml
fi
../git-repo/repo sync -j$(nproc --all)
- name: Setup KernelSU