Skip to main content
Glama
create-release-pr.yml3.32 kB
name: Create release PR permissions: contents: write pull-requests: write on: workflow_dispatch: inputs: bump: type: choice description: The version bump type. Select 'auto' to determine from changelog entries. default: auto options: - auto - major - minor - patch prerelease: type: string description: Optional pre-release tag (e.g. alpha.1, beta.1, rc.1). Leave empty for stable. default: "" jobs: create-release-pr: runs-on: ubuntu-latest steps: - uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # actions/checkout@v4 - uses: ./.github/actions/setup-python - name: Compute next dir for bump id: changie-next uses: miniscruff/changie-action@6dcc2533cac0495148ed4046c438487e4dceaa23 with: version: latest args: next ${{ inputs.bump }} - name: Prepare batch args id: prepare-batch shell: bash run: | PR="${{ inputs.prerelease }}" BUMP="${{ inputs.bump }}" NEXT_DIR="${{ steps.changie-next.outputs.output }}" if [[ -n "$PR" ]]; then if [[ ! "$PR" =~ ^(alpha|beta|rc)\.[0-9]+$ ]]; then echo "Invalid prerelease format: $PR (expected alpha.N, beta.N, rc.N)" >&2 exit 1 fi echo "args=batch $BUMP --move-dir $NEXT_DIR --prerelease $PR" >> "$GITHUB_OUTPUT" else if [[ -d "$NEXT_DIR" ]]; then echo "args=batch $BUMP --include $NEXT_DIR --remove-prereleases" >> "$GITHUB_OUTPUT" else echo "args=batch $BUMP" >> "$GITHUB_OUTPUT" fi fi - name: Batch changes uses: miniscruff/changie-action@6dcc2533cac0495148ed4046c438487e4dceaa23 with: version: latest args: ${{ steps.prepare-batch.outputs.args }} - name: Merge uses: miniscruff/changie-action@6dcc2533cac0495148ed4046c438487e4dceaa23 with: version: latest args: merge - name: Get the latest version id: changie-latest uses: miniscruff/changie-action@6dcc2533cac0495148ed4046c438487e4dceaa23 with: version: latest args: latest - name: Set latest package version id: package-version run: | VERSION="${{ steps.changie-latest.outputs.output }}" VERSION_NO_V=$(echo "$VERSION" | cut -c 2-) MESSAGE=$(cat ".changes/$VERSION.md") { echo "version=$VERSION_NO_V" echo "message<<EOF" echo "$MESSAGE" echo "EOF" } >> "$GITHUB_OUTPUT" - name: Create Pull Request uses: peter-evans/create-pull-request@271a8d0340265f705b14b6d32b9829c1cb33d45e with: title: "version: ${{ steps.package-version.outputs.version }}" branch: release/${{ steps.package-version.outputs.version }} commit-message: | version: ${{ steps.package-version.outputs.version }} ${{ steps.package-version.outputs.message }} body: | ## version: ${{ steps.package-version.outputs.version }} ${{ steps.package-version.outputs.message }}

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/dbt-labs/dbt-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server