Skip to content

Merge pull request #468 from Yggaz/patch-1 #38

Merge pull request #468 from Yggaz/patch-1

Merge pull request #468 from Yggaz/patch-1 #38

Workflow file for this run

name: Release from master
on:
push:
branches: [ master ]
workflow_dispatch:
jobs:
release:
runs-on: ubuntu-latest
steps:
- name: Install Utils
run: sudo apt-get install -y bsdmainutils
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Compute tag name
id: compute-tag
run: |
echo "Computing next tag number"
LASTPATCH=$(git describe --tags | cut -d- -f1 | cut -d. -f3)
PATCH=$(($LASTPATCH+1))
echo "New tag name: 2.1.${PATCH}"
echo "::set-output name=tagname::2.1.${PATCH}"
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: 3.0
bundler-cache: true # runs 'bundle install' and caches installed gems automatically
- name: Build release assets
run: bundle exec rake book:build
- name: Create Release
uses: ncipollo/release-action@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
tag: ${{ steps.compute-tag.outputs.tagname }}
commit: master
artifacts: './progit.epub,./progit.fb2.zip,./progit.mobi,./progit.pdf,./progit.html'