44  workflow_dispatch :
55    inputs :
66      version :
7-         description : ' Release version (e.g., v1.2.3)' 
7+         description : Release version (e.g., v1.2.3) 
88        required : true 
99        type : string 
10+         default : __TAKEN_FROM_ACTION_YML__ 
11+ 
12+ permissions :
13+   contents : write 
14+   packages : write 
1015
1116jobs :
1217  release :
@@ -17,109 +22,69 @@ jobs:
1722        uses : actions/checkout@v5 
1823        with :
1924          fetch-depth : 0 
25+           fetch-tags : true 
2026
21-       - name : Validate version format 
22-         run : | 
23-           VERSION="${{ github.event.inputs.version }}" 
24-           if [[ ! $VERSION =~ ^v[0-9]+\.[0-9]+\.[0-9]+$ ]]; then 
25-             echo "❌ Invalid version format. Use format: v1.2.3" 
26-             exit 1 
27-           fi 
28-           echo "✅ Version format is valid: $VERSION" 
29- 
30-        - name : Check if version already exists 
31-         run : | 
32-           VERSION="${{ github.event.inputs.version }}" 
33-           if git tag -l | grep -q "^${VERSION}$"; then 
34-             echo "❌ Version $VERSION already exists" 
35-             exit 1 
36-           fi 
37-           echo "✅ Version $VERSION is available" 
38- 
39-        - name : Create and push full tag 
40-         run : | 
41-           VERSION="${{ github.event.inputs.version }}" 
42-           git config user.name "github-actions[bot]" 
43-           git config user.email "github-actions[bot]@users.noreply.github.com" 
44-           git tag -a "$VERSION" -m "$VERSION" 
45-           git push origin "$VERSION" 
27+       - name : Install Task 
28+ 29+         with :
30+           version : 3.x 
4631
47-        - name : Extract version components 
32+       - name : Create and push git tags 
4833        id : version 
34+         env :
35+           VERSION_OVERRIDE : ${{ github.event.inputs.version }} 
36+           VERSION_SUFFIX : " " 
4937        run : | 
50-           VERSION="${{ github.event.inputs.version }}" 
51-           # Remove 'v' prefix and split version 
52-           VERSION_NO_V="${VERSION#v}" 
53-           MAJOR=$(echo "$VERSION_NO_V" | cut -d. -f1) 
54-           MINOR=$(echo "$VERSION_NO_V" | cut -d. -f2) 
55-            
56-           echo "major=v$MAJOR" >> $GITHUB_OUTPUT 
57-           echo "minor=v$MAJOR.$MINOR" >> $GITHUB_OUTPUT 
58-           echo "✅ Extracted versions - Major: v$MAJOR, Minor: v$MAJOR.$MINOR" 
59- 
60-        - name : Create/update major version tag 
61-         run : | 
62-           MAJOR_TAG="${{ steps.version.outputs.major }}" 
63-            
64-           # Check if major tag exists 
65-           if git tag -l | grep -q "^${MAJOR_TAG}$"; then 
66-             echo "ℹ️ Major tag $MAJOR_TAG exists, updating it" 
67-             git tag -d "$MAJOR_TAG" || true  
68-             git push origin ":refs/tags/$MAJOR_TAG" || true  
69-           else 
70-             echo "✅ Major tag $MAJOR_TAG is new" 
71-           fi 
72-            
73-           # Create/update major tag 
74-           git tag -a "$MAJOR_TAG" -m "Major version $MAJOR_TAG" 
75-           git push origin "$MAJOR_TAG" 
76-           echo "✅ Created/updated major tag: $MAJOR_TAG" 
77- 
78-        - name : Create/update minor version tag 
79-         run : | 
80-           MINOR_TAG="${{ steps.version.outputs.minor }}" 
81-            
82-           # Check if minor tag exists 
83-           if git tag -l | grep -q "^${MINOR_TAG}$"; then 
84-             echo "ℹ️ Minor tag $MINOR_TAG exists, updating it" 
85-             git tag -d "$MINOR_TAG" || true  
86-             git push origin ":refs/tags/$MINOR_TAG" || true  
87-           else 
88-             echo "✅ Minor tag $MINOR_TAG is new" 
89-           fi 
90-            
91-           # Create/update minor tag 
92-           git tag -a "$MINOR_TAG" -m "Minor version $MINOR_TAG" 
93-           git push origin "$MINOR_TAG" 
94-           echo "✅ Created/updated minor tag: $MINOR_TAG" 
38+           task git:set-config 
39+           task version:tag-release 
40+           echo "REL_VERSION=$(task version:get)" >> "$GITHUB_OUTPUT" 
9541
96-        - name : Docker Buildx 
42+        - name : Install  Docker Buildx
9743        uses : docker/setup-buildx-action@v3 
9844        with :
9945          install : true 
10046
101-       - name : QEMU 
47+       - name : Install  QEMU
10248        uses : docker/setup-qemu-action@v3 
10349        with :
10450          image : tonistiigi/binfmt:latest 
10551          platforms : amd64,arm64 
10652
53+       - name : Get Docker commands 
54+         env :
55+           VERSION_OVERRIDE : ${{ github.event.inputs.version }} 
56+           VERSION_SUFFIX : " " 
57+         run : task docker:cmds 
58+ 
10759      - name : Build and push Docker images 
10860        env :
109-           DOCKER_BUILDKIT : 1 
11061          DOCKER_TOKEN : ${{ secrets.DOCKER_TOKEN }} 
11162          GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }} 
112-           VERSION : ${{ github.event.inputs.version }} 
113-           TERM : xterm-256color 
114-         run : make push 
63+           VERSION_OVERRIDE : ${{ github.event.inputs.version }} 
64+           VERSION_SUFFIX : " " 
65+         run : task docker:push 
66+ 
67+       - name : Inspect image 
68+         env :
69+           VERSION_OVERRIDE : ${{ github.event.inputs.version }} 
70+           VERSION_SUFFIX : " " 
71+         run : task docker:push:inspect 
11572
11673      - name : Create GitHub Release 
11774        uses : softprops/action-gh-release@v2 
11875        with :
119-           tag_name : ${{ github.event.inputs.version  }} 
120-           name : ${{ github.event.inputs.version  }} 
76+           tag_name : ${{ steps.version.outputs.REL_VERSION  }} 
77+           name : ${{ steps.version.outputs.REL_VERSION  }} 
12178          draft : false 
12279          prerelease : false 
12380          generate_release_notes : true 
12481        env :
12582          GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }} 
83+ 
84+       - name : Update Docker Hub description 
85+         uses : peter-evans/dockerhub-description@v5 
86+         with :
87+           username : ${{ vars.DOCKER_USERNAME }} 
88+           password : ${{ secrets.DOCKER_TOKEN }} 
89+           repository : ${{ vars.DOCKER_ORG_NAME }}/${{ github.event.repository.name }} 
90+           short-description : ${{ github.event.repository.description }} 
0 commit comments