rocky-logos/.github/workflows/main.yml

40 lines
1.3 KiB
YAML
Raw Normal View History

2021-05-02 00:43:11 +00:00
---
name: 'Release Formatting'
2021-05-02 01:09:33 +00:00
on:
push:
tags:
- '*'
2021-05-02 00:43:11 +00:00
jobs:
package:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Extract tag name
id: tag
uses: actions/github-script@0.2.0
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
2021-05-08 22:44:01 +00:00
return context.payload.ref
.replace(/\/refs\/tags\//, '')
.replace(/refs\/tags\//, '');
2021-05-02 00:49:19 +00:00
- name: Build source artifact
2021-05-02 00:56:36 +00:00
run: |
mkdir -p ../rocky-logos-${{ steps.tag.outputs.result }} &&
cp -r . ../rocky-logos-${{ steps.tag.outputs.result }} &&
mv ../rocky-logos-${{ steps.tag.outputs.result }} . &&
2021-05-08 22:44:01 +00:00
tar cfJ rocky-logos-${{ steps.tag.outputs.result }}.tar.xz rocky-logos-${{ steps.tag.outputs.result }}
2021-05-02 01:09:33 +00:00
- name: Generate release
uses: docker://antonyurchenko/git-release:latest
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
DRAFT_RELEASE: "false"
PRE_RELEASE: "false"
CHANGELOG_FILE: "none"
ALLOW_EMPTY_CHANGELOG: "false"
2021-12-06 01:43:41 +00:00
TAG_PREFIX_REGEX: "^refs\/tags\/(0|[1-9]\d*)\.(0|[1-9]\d*)?$"
2021-05-02 01:09:33 +00:00
with:
args: |
rocky-logos-${{ steps.tag.outputs.result }}.tar.xz