Skip to content

Commit f4488c3

Browse files
committed
ci: one-shot retag workflow — move v1 and create v1.0.3 at HEAD
1 parent 2bb9c17 commit f4488c3

1 file changed

Lines changed: 36 additions & 0 deletions

File tree

.github/workflows/retag.yml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
name: Retag v1
2+
3+
on:
4+
push:
5+
paths:
6+
- '.github/workflows/retag.yml'
7+
8+
permissions:
9+
contents: write
10+
11+
jobs:
12+
retag:
13+
runs-on: ubuntu-latest
14+
steps:
15+
- uses: actions/checkout@v4.2.2
16+
with:
17+
fetch-depth: 0
18+
token: ${{ secrets.GITHUB_TOKEN }}
19+
20+
- name: Move v1 tag and create v1.0.3
21+
run: |
22+
git config user.name "github-actions[bot]"
23+
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
24+
25+
# Delete existing v1 tag remotely
26+
git push origin :refs/tags/v1 || true
27+
28+
# Re-create v1 at current HEAD
29+
git tag -f v1 HEAD
30+
git push origin v1
31+
32+
# Create v1.0.3 at current HEAD
33+
git tag -f v1.0.3 HEAD
34+
git push origin v1.0.3
35+
36+
echo "✅ v1 and v1.0.3 now point to $(git rev-parse HEAD)"

0 commit comments

Comments
 (0)