liblab SDK update v1.0.3 #15
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Build and Release from Merged PR | |
| on: | |
| pull_request: | |
| types: [closed] | |
| branches: [master] | |
| workflow_dispatch: | |
| jobs: | |
| create-release: | |
| if: github.event_name == 'workflow_dispatch' || (github.event.pull_request.merged == true && contains(github.event.pull_request.labels.*.name, 'release')) | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| - name: Install xmllint | |
| run: sudo apt-get update && sudo apt-get install -y libxml2-utils | |
| - name: Extract version from pom.xml | |
| id: extract_version | |
| run: | | |
| VERSION=$(xmllint --xpath "/*[local-name()='project']/*[local-name()='version']/text()" pom.xml) | |
| echo "VERSION=$VERSION" | |
| echo "VERSION=$VERSION" >> $GITHUB_OUTPUT | |
| - name: Create GitHub Release | |
| uses: softprops/action-gh-release@v2 | |
| with: | |
| tag_name: v${{ steps.extract_version.outputs.VERSION }} | |
| name: Release v${{ steps.extract_version.outputs.VERSION }} | |
| generate_release_notes: false | |
| draft: false | |
| prerelease: false | |
| token: ${{ secrets.RELEASE_GITHUB_TOKEN }} |