Skip to content

fix(release): reading version from manifest #5

fix(release): reading version from manifest

fix(release): reading version from manifest #5

Workflow file for this run

name: Create Release
on:
push:
branches:
- main
jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Get version from fxmanifest.lua
id: get_version
shell: bash
run: |
version=$(grep "git_version" fxmanifest.lua | awk -F"'" '{print $2}')
echo "Found version: $version"
if [ ! -z "$version" ]; then
echo "version=$version" >> "$GITHUB_OUTPUT"
else
echo "Error: Version not found in fxmanifest.lua"
exit 1
fi
- name: Create ZIP archive
run: |
zip -r sure_lib.zip . -x ".git/*" ".github/*" "*.md" "LICENSE"
- name: Create Release
uses: ncipollo/release-action@v1
with:
artifacts: "sure_lib.zip"
token: ${{ secrets.GITHUB_TOKEN }}
draft: false
prerelease: false
generateReleaseNotes: true
tag: v${{ steps.get_version.outputs.version }}
name: "Release v${{ steps.get_version.outputs.version }}"