2021-03-04 20:25:30 -05:00
|
|
|
name: "Create 'preview' release"
|
2021-03-01 18:42:29 -05:00
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- master
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
create_release:
|
2021-03-04 20:25:30 -05:00
|
|
|
name: Create preview release
|
2021-03-01 18:42:29 -05:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
2024-05-07 07:26:23 -04:00
|
|
|
- uses: actions/checkout@v4.1.5
|
2021-03-01 18:42:29 -05:00
|
|
|
|
2021-03-04 20:25:30 -05:00
|
|
|
- name: Delete 'preview' release
|
2021-03-01 18:42:29 -05:00
|
|
|
uses: larryjoelane/delete-release-action@v1.0.24
|
|
|
|
with:
|
2021-03-04 20:25:30 -05:00
|
|
|
release-name: preview
|
2021-03-01 18:42:29 -05:00
|
|
|
token: ${{ secrets.BOTTY_GITHUB_TOKEN }}
|
|
|
|
|
2021-03-01 23:41:47 -05:00
|
|
|
- name: Give GitHub some time to process the deletion, otherwise our release shows up as draft. Sigh.
|
|
|
|
run: sleep 10
|
|
|
|
|
2021-03-23 20:30:27 -04:00
|
|
|
- name: Extract changelog section for release
|
|
|
|
id: changelog
|
|
|
|
uses: coditory/changelog-parser@v1
|
|
|
|
with:
|
|
|
|
version: unreleased
|
|
|
|
|
2021-03-04 20:25:30 -05:00
|
|
|
- name: Create 'preview' release
|
2021-03-01 18:42:29 -05:00
|
|
|
uses: actions/create-release@v1
|
|
|
|
env:
|
|
|
|
GITHUB_TOKEN: ${{ secrets.BOTTY_GITHUB_TOKEN }}
|
|
|
|
with:
|
2021-03-04 20:25:30 -05:00
|
|
|
tag_name: preview
|
|
|
|
release_name: preview
|
2021-03-01 18:42:29 -05:00
|
|
|
draft: false
|
|
|
|
prerelease: true
|
2021-03-23 20:30:27 -04:00
|
|
|
body: ${{ steps.changelog.outputs.description }}
|