mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2026-05-12 11:42:57 -04:00
Fix detached head issue
This commit is contained in:
parent
9c7caf8346
commit
ad5cd112c8
1 changed files with 5 additions and 10 deletions
15
.github/workflows/auto-release.yml
vendored
15
.github/workflows/auto-release.yml
vendored
|
|
@ -98,22 +98,17 @@ jobs:
|
||||||
VERSION_NUMBER: ${{ github.event.inputs.version_number }}
|
VERSION_NUMBER: ${{ github.event.inputs.version_number }}
|
||||||
working-directory: ./local_kernel
|
working-directory: ./local_kernel
|
||||||
run: |
|
run: |
|
||||||
echo "=== Git log (last 5 commits) ==="
|
# The update_src_version.py script detaches HEAD by checking out a SHA.
|
||||||
git log --oneline -5
|
# Re-attach HEAD to the release prep branch, keeping all commits.
|
||||||
echo "=== Git status ==="
|
git branch -f "release-prep-$VERSION_NUMBER" HEAD
|
||||||
git status
|
git checkout "release-prep-$VERSION_NUMBER"
|
||||||
echo "=== Git diff --stat ==="
|
|
||||||
git diff --stat
|
|
||||||
git add .
|
git add .
|
||||||
echo "=== Staged changes ==="
|
|
||||||
git diff --cached --stat
|
|
||||||
if git diff --cached --quiet; then
|
if git diff --cached --quiet; then
|
||||||
echo "No new changes to commit — source files and manifest already up to date."
|
echo "No new changes to commit — source files and manifest already up to date."
|
||||||
else
|
else
|
||||||
git commit -m '[AUTO][RELEASE]: Update version number in manifest.yml and source files'
|
git commit -m '[AUTO][RELEASE]: Update version number in manifest.yml and source files'
|
||||||
fi
|
fi
|
||||||
echo "=== Commits ahead of origin/main ==="
|
|
||||||
git log --oneline origin/main..HEAD
|
|
||||||
git push -u origin "release-prep-$VERSION_NUMBER"
|
git push -u origin "release-prep-$VERSION_NUMBER"
|
||||||
|
|
||||||
- name: Create pull request
|
- name: Create pull request
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue