Skip to content

Commit

Permalink
Towards better release procedure
Browse files Browse the repository at this point in the history
- Prepare release commit (CHANGELOG), triple-check and push.
- Wait for CI to finish.
- Tag locally and push.
- Tadaaa!
  • Loading branch information
stronk7 committed Apr 8, 2024
1 parent 02a279e commit 9b04188
Showing 1 changed file with 36 additions and 0 deletions.
36 changes: 36 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: Create Release

on:
push:
tags: [ 'v*' ]

jobs:
release:
# Avoid forks to perform this job.
if: github.repository_owner == 'stronk7'
name: Create Release
runs-on: ubuntu-22.04

steps:
- name: Check out repository code
uses: actions/checkout@v4

- name: Get version from tag
id: tag-name
run: |
echo "version=${GITHUB_REF#refs/tags/}" >> $GITHUB_OUTPUT
- name: Extract release notes from changelog
id: extract-release-notes
uses: mindsers/changelog-reader-action@v2
with:
path: ./CHANGELOG.md
version: ${{ steps.tag-name.version }}

- name: Create Release
uses: ncipollo/release-action@v1
with:
body: |
${{ steps.extract-release-notes.outputs.changes }}
#
Take a look at the [CHANGELOG](https://github.com/moodlehq/moodle-cs/blob/main/CHANGELOG.md) for details about other releases.

0 comments on commit 9b04188

Please sign in to comment.