1
0
mirror of https://github.com/AvengeMedia/DankMaterialShell.git synced 2026-08-02 03:28:28 -04:00

workflow: update porting logic

This commit is contained in:
purian23
2026-07-09 12:02:14 -04:00
parent 0439d017b9
commit cb0dc9c68d
2 changed files with 7 additions and 2 deletions
+5
View File
@@ -7,6 +7,7 @@ on:
permissions:
contents: write
issues: write
jobs:
update-stable:
@@ -77,3 +78,7 @@ jobs:
fi
git push "https://x-access-token:${GH_TOKEN}@github.com/${{ github.repository }}.git" "HEAD:refs/heads/${branch}"
echo "created ${branch} at ${GITHUB_REF_NAME}"
GH_TOKEN="${{ secrets.GITHUB_TOKEN }}" gh label create "port ${branch}" \
--repo "${{ github.repository }}" \
--description "Auto-port merged PR to ${branch}" --color 0e8a16 ||
echo "label 'port ${branch}' may already exist"
+2 -2
View File
@@ -1,7 +1,7 @@
name: Port to release branch
# Ports flagged commits from master onto release/X.Y branches:
# - "Port: 1.5" trailer in a commit message pushed to master
# - "Port: 1.5" (or "Port/1.5") trailer line in a commit message pushed to master
# - "port release/1.5" label on a merged PR
# Conflicts are reported to the "Port status: <branch>" tracking issue.
@@ -52,7 +52,7 @@ jobs:
[ "$(git rev-list --no-walk --count --min-parents=2 "$sha")" -eq 0 ] || continue
targets=$(git log -1 --format=%B "$sha" |
{ grep -iE '^Port:' || true; } | sed 's/^port: *//I' | tr ',' '\n' |
{ grep -iE '^Port[:/]' || true; } | sed 's|^port[:/] *||I' | tr ',' '\n' |
sed 's/[[:space:]]//g; /^$/d' | sed 's|^release/||I' | sort -u)
for ver in $targets; do
echo "::group::port $sha -> release/$ver"