Add for loop type inference support #6
Workflow file for this run
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: Publish Release Tag on Release PR Merge | |
| on: | |
| pull_request: | |
| types: [closed] | |
| branches: [main] | |
| permissions: | |
| contents: write | |
| jobs: | |
| create-tag: | |
| if: github.event.pull_request.merged == true && startsWith(github.event.pull_request.head.ref, 'release-v') | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Extract version from branch name | |
| id: version | |
| env: | |
| BRANCH: ${{ github.event.pull_request.head.ref }} | |
| run: | | |
| VERSION="${BRANCH#release-}" | |
| if [[ ! "$VERSION" =~ ^v[0-9]+\.[0-9]+\.[0-9]+$ ]]; then | |
| echo "Invalid version format: $VERSION" | |
| exit 1 | |
| fi | |
| echo "tag=${VERSION}" >> "$GITHUB_OUTPUT" | |
| - name: Create and push tag | |
| env: | |
| TAG: ${{ steps.version.outputs.tag }} | |
| run: | | |
| git tag "$TAG" | |
| git push origin "$TAG" |