Update kernel-codeql-release.yaml

This commit is contained in:
Eduardo' Vela" Nava (sirdarckcat)
2025-10-25 10:58:00 +02:00
committed by GitHub
parent ce56c9c807
commit 032dba7a22
+4 -4
View File
@@ -40,6 +40,7 @@ jobs:
repository: ${{ env.SOURCE_REPO }}
fetch-depth: 0
fetch-tags: true
filter: blob:none
- name: Find new tags
id: find_new_tags
@@ -191,12 +192,11 @@ jobs:
ZIP: codeql_db_${{ matrix.tag }}.zip
run: |
set -eux
split --bytes=2G "$ZIP" "$ZIP_split"
zip -s 2g "$ZIP" --out "$ZIP_split"
# Check if release for tag already exists
if gh release view "$TAG" --repo "$TARGET_REPO" >/dev/null 2>&1; then
echo "Release for tag $TAG exists in $TARGET_REPO — uploading asset (will overwrite if exists)"
gh release upload "$TAG" --repo "$TARGET_REPO" --clobber "$ZIP_split"*
else
echo "Creating new release for tag $TAG in $TARGET_REPO and attaching asset"
gh release create "$TAG" --repo "$TARGET_REPO" "$ZIP_split"* --title "CodeQL DB for $TAG" --notes "Attached is the CodeQL database generated for tag $TAG."
gh release create "$TAG" --repo "$TARGET_REPO" "$ZIP_split"* --title "CodeQL DB for $TAG" --notes "Stored as a multipart zip file."
fi