Skip to content

Release Candidate 2.0.0-RC2 #6

Release Candidate 2.0.0-RC2

Release Candidate 2.0.0-RC2 #6

Workflow file for this run

name: Release
on:
push:
tags:
- 'release/*'
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v4
- name: Install Lua compiler
run: sudo apt-get -y install lua5.2
- name: Set build variables
run: |
GIT_VER=${GITHUB_REF##*/}
GIT_TAG=${GITHUB_REF##refs/tags/}
if [[ ${GIT_VER} =~ ^[0-9]+[.][0-9]+[.][0-9]+[-][A-Za-z0-9]+ ]]
then
GH_TYPE='Release Candidate'
else
GH_TYPE='Release'
fi
echo "GIT_VER=${GIT_VER}" >> ${GITHUB_ENV}
echo "GIT_TAG=${GIT_TAG}" >> ${GITHUB_ENV}
echo "GH_TYPE=${GH_TYPE}" >> ${GITHUB_ENV}
cat ${GITHUB_ENV}
- name: Make release package
run: make package ZIPFILE="rotorflight-lua-scripts-${{ env.GIT_VER }}.zip"
- name: Create Release
run: |
.github/scripts/extract-release-notes.py "${{ env.GIT_VER }}" Releases.md > Notes.md
gh release create ${{ env.GIT_TAG }} --notes-file Notes.md --title "Rotorflight LUA Scripts - ${{ env.GH_TYPE }} ${{ env.GIT_VER }}" *.zip
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}