Sha256: 6534f4c92b9b8adcd81cbff0af9a3d5da491f31c4f7b46753e6b61f6306b410e

Contents?: true

Size: 1.56 KB

Versions: 16

Compression:

Stored size: 1.56 KB

Contents

name: release-tag

on:
  repository_dispatch:
    types: [ metanorma/mn2pdf ]

jobs:
  tag_repo:
    runs-on: ubuntu-18.04
    if: startsWith(github.event.client_payload.ref, 'refs/tags/v')
    steps:
      - uses: actions/checkout@v1
      - name: Add writable remote
        run: |
          git config --global user.name "metanorma-ci"
          git config --global user.email "metanorma-ci@users.noreply.github.com"
          git remote add github "https://metanorma-ci:${{ secrets.METANORMA_CI_PAT_TOKEN }}@github.com/$GITHUB_REPOSITORY.git"
          git pull github ${GITHUB_REF} --ff-only
      - name: Parse mn2pdf version
        env:
          MN2PDF_TAG: ${{ github.event.client_payload.ref }}
        run: |
          echo MN2PDF_VERSION=${MN2PDF_TAG#*/v} >> ${GITHUB_ENV}
      - name: Use Ruby
        uses: actions/setup-ruby@v1
        with:
          ruby-version: '2.6'
          architecture: 'x64'
      - name: Update gems
        run: |
          gem install gem-release
          gem install bundler
          bundle install --jobs 4 --retry 3
      - name: Update version
        run: |
          gem bump --version ${MN2PDF_VERSION} --no-commit
      - name: Update mn2pdf.jar
        run: |
          rm -f bin/mn2pdf.jar
          rake bin/mn2pdf.jar
      - name: Run specs
        run: |
          bundle exec rake
      - name: Push commit and tag
        run: |
          git add -u bin/mn2pdf.jar lib/mn2pdf/version.rb
          git commit -m "Bump version to ${MN2PDF_VERSION}"
          git tag v${MN2PDF_VERSION}
          git push github HEAD:${GITHUB_REF} --tags

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
mn2pdf-1.41.1 .github/workflows/release-tag.yml
mn2pdf-1.41 .github/workflows/release-tag.yml
mn2pdf-1.38.1 .github/workflows/release-tag.yml
mn2pdf-1.36 .github/workflows/release-tag.yml
mn2pdf-1.35 .github/workflows/release-tag.yml
mn2pdf-1.34 .github/workflows/release-tag.yml
mn2pdf-1.33 .github/workflows/release-tag.yml
mn2pdf-1.32 .github/workflows/release-tag.yml
mn2pdf-1.31.2 .github/workflows/release-tag.yml
mn2pdf-1.31.1 .github/workflows/release-tag.yml
mn2pdf-1.31 .github/workflows/release-tag.yml
mn2pdf-1.30 .github/workflows/release-tag.yml
mn2pdf-1.29 .github/workflows/release-tag.yml
mn2pdf-1.28 .github/workflows/release-tag.yml
mn2pdf-1.27 .github/workflows/release-tag.yml
mn2pdf-1.26 .github/workflows/release-tag.yml