mirror of
https://github.com/puppetlabs/vmpooler.git
synced 2026-01-26 10:08:40 -05:00
Add Gem release workflow
This commit is contained in:
parent
19626ddea0
commit
4742977e16
1 changed files with 32 additions and 0 deletions
32
.github/workflows/release.yml
vendored
Normal file
32
.github/workflows/release.yml
vendored
Normal file
|
|
@ -0,0 +1,32 @@
|
||||||
|
name: Release
|
||||||
|
|
||||||
|
on: workflow_dispatch
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
release:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
if: github.repository == 'puppetlabs/vmpooler'
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
- name: Get Version
|
||||||
|
id: gv
|
||||||
|
run: |
|
||||||
|
echo "::set-output name=ver::$(grep VERSION lib/vmpooler/version.rb |rev |cut -d "'" -f2 |rev)"
|
||||||
|
- name: Tag Release
|
||||||
|
uses: ncipollo/release-action@v1
|
||||||
|
with:
|
||||||
|
tag: ${{ steps.gv.outputs.ver }}
|
||||||
|
token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
draft: false
|
||||||
|
prerelease: false
|
||||||
|
generateReleaseNotes: true
|
||||||
|
- name: Install Ruby 2.5.8
|
||||||
|
uses: ruby/setup-ruby@v1
|
||||||
|
with:
|
||||||
|
ruby-version: '2.5.8'
|
||||||
|
- name: Build gem
|
||||||
|
run: gem build *.gemspec
|
||||||
|
- name: Publish gem
|
||||||
|
run: gem push *.gem
|
||||||
|
env:
|
||||||
|
GEM_HOST_API_KEY: '${{ secrets.RUBYGEMS_AUTH_TOKEN }}'
|
||||||
Loading…
Add table
Add a link
Reference in a new issue