Skip to content

Commit

Permalink
Create on-release.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
thrawn01 authored Nov 17, 2021
1 parent ffc52f4 commit aa92858
Showing 1 changed file with 40 additions and 0 deletions.
40 changes: 40 additions & 0 deletions .github/workflows/on-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: On Release Workflow

on:
release:
types: [published]

jobs:

build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

- name: Update 'version' file
run: echo "${{ github.event.release.tag_name }}" > version

- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.17

- name: Build
run: make release

- name: Release
uses: softprops/action-gh-release@v1
with:
files: |
clip-${{ github.event.release.tag_name }}-darwin-amd64.tar.gz
clip-${{ github.event.release.tag_name }}-linux-386.tar.gz
clip-${{ github.event.release.tag_name }}-linux-amd64.tar.gz
# Commit the updated 'version' file
- name: Commit changes
uses: EndBug/add-and-commit@v7
with:
default_author: github_actions
message: 'Update version number'
branch: master
add: 'version'

0 comments on commit aa92858

Please sign in to comment.