Bumps [actions/checkout](https://github.com/actions/checkout) from 5 to 6. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/v5...v6) --- updated-dependencies: - dependency-name: actions/checkout dependency-version: '6' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com>
57 lines
1.6 KiB
YAML
57 lines
1.6 KiB
YAML
name: Release new version
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
paths:
|
|
- "lib/mcp/version.rb"
|
|
jobs:
|
|
publish_gem:
|
|
if: github.repository_owner == 'modelcontextprotocol'
|
|
name: Release Gem Version to RubyGems.org
|
|
runs-on: ubuntu-latest
|
|
|
|
environment: release
|
|
|
|
permissions:
|
|
id-token: write # IMPORTANT: this permission is mandatory for trusted publishing
|
|
contents: write # IMPORTANT: this permission is required for `rake release` to push the release tag
|
|
steps:
|
|
- uses: actions/checkout@v6
|
|
- name: Set up Ruby
|
|
uses: ruby/setup-ruby@v1
|
|
with:
|
|
bundler-cache: true
|
|
ruby-version: 3.4
|
|
- uses: rubygems/release-gem@v1
|
|
|
|
publish_gh_pages:
|
|
if: github.repository_owner == 'modelcontextprotocol'
|
|
name: Publish Documentation to GitHub Pages
|
|
runs-on: ubuntu-latest
|
|
needs: [publish_gem]
|
|
|
|
permissions:
|
|
contents: write
|
|
|
|
steps:
|
|
- uses: actions/checkout@v6
|
|
with:
|
|
fetch-depth: 0 # Fetch all history for all branches and tags
|
|
|
|
- name: Configure Git
|
|
run: |
|
|
git config --global user.name "github-actions[bot]"
|
|
git config --global user.email "github-actions[bot]@users.noreply.github.com"
|
|
|
|
- name: Get version tag
|
|
id: version
|
|
run: |
|
|
git fetch --tags
|
|
TAG=$(git describe --tags --exact-match HEAD)
|
|
echo "tag=${TAG}" >> $GITHUB_OUTPUT
|
|
|
|
- name: Generate GitHub Pages
|
|
run: ./bin/generate-gh-pages.sh ${{ steps.version.outputs.tag }}
|
|
|
|
- name: Push to gh-pages
|
|
run: git push origin gh-pages
|