File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 99 steps :
1010 - name : Checkout code
1111 uses : actions/checkout@v4
12-
12+
1313 - name : Set up JDK 17
1414 uses : actions/setup-java@v4
1515 with :
1616 java-version : ' 17'
1717 distribution : ' temurin'
18-
18+
1919 - name : Grant execute permission for gradlew
2020 run : chmod +x gradlew
21-
21+
2222 - name : Extract version from build.gradle.kts
2323 id : extract_version
2424 run : |
2525 VERSION=$(./gradlew -q printVersion)
2626 echo "version=$VERSION" >> $GITHUB_OUTPUT
2727 echo "Extracted version: $VERSION"
28-
28+
2929 - name : Publish Maven artifacts to local repo
3030 run : ./gradlew publish
3131 env :
3232 GROUP_ID : fr.sandro642.github
3333 ARTIFACT_ID : ConnectorAPI
3434 VERSION : ${{ steps.extract_version.outputs.version }}
35-
35+
3636 - name : Deploy to GitHub Pages
3737 uses : JamesIves/github-pages-deploy-action@v4
3838 with :
4141 branch : main
4242 folder : build/repo
4343 target-folder : connectorapi/jar
44+
45+ - name : Create Git tag
46+ run : |
47+ git config --local user.email "action@github.com"
48+ git config --local user.name "GitHub Action"
49+ git tag -a "${{ steps.extract_version.outputs.version }}" -m "Release version ${{ steps.extract_version.outputs.version }}"
50+ git push origin "${{ steps.extract_version.outputs.version }}"
51+ env :
52+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
You can’t perform that action at this time.
0 commit comments