fix: add nodejs and npm installation to setup steps for all export jobs
Some checks failed
Some checks failed
This commit is contained in:
@@ -24,6 +24,8 @@ jobs:
|
||||
lfs: true
|
||||
- name: Setup
|
||||
run: |
|
||||
apt-get update
|
||||
apt-get install -y nodejs npm
|
||||
mkdir -v -p ~/.local/share/godot/export_templates/
|
||||
mkdir -v -p ~/.config/
|
||||
mv /root/.config/godot ~/.config/godot
|
||||
@@ -52,6 +54,8 @@ jobs:
|
||||
lfs: true
|
||||
- name: Setup
|
||||
run: |
|
||||
apt-get update
|
||||
apt-get install -y nodejs npm
|
||||
mkdir -v -p ~/.local/share/godot/export_templates/
|
||||
mv /root/.local/share/godot/export_templates/${GODOT_VERSION}.stable ~/.local/share/godot/export_templates/${GODOT_VERSION}.stable
|
||||
- name: Linux Build
|
||||
@@ -112,6 +116,8 @@ jobs:
|
||||
lfs: true
|
||||
- name: Setup
|
||||
run: |
|
||||
apt-get update
|
||||
apt-get install -y nodejs npm
|
||||
mkdir -v -p ~/.local/share/godot/export_templates/
|
||||
mv /root/.local/share/godot/export_templates/${GODOT_VERSION}.stable ~/.local/share/godot/export_templates/${GODOT_VERSION}.stable
|
||||
- name: Mac Build
|
||||
@@ -126,11 +132,39 @@ jobs:
|
||||
name: mac
|
||||
path: build/mac
|
||||
|
||||
- name: Upload builds
|
||||
uses: actions/upload-artifact@v5
|
||||
with:
|
||||
name: ${{ matrix.platform }}
|
||||
path: build/${{ matrix.platform }}
|
||||
create-release:
|
||||
name: Create Release
|
||||
runs-on: ubuntu-latest
|
||||
needs: [export-mac, export-linux, export-windows]
|
||||
steps:
|
||||
- name: Extract version and body from CHANGELOG
|
||||
id: changelog
|
||||
run: |
|
||||
# Extract the latest released version (skip Unreleased)
|
||||
LATEST=$(grep -E '^## \[[0-9]+\.[0-9]+\.[0-9]+\]' CHANGELOG.md | head -n1 | sed -E 's/^## \[([0-9]+\.[0-9]+\.[0-9]+)\].*/\1/')
|
||||
|
||||
if [ -z "$LATEST" ]; then
|
||||
echo "No released version found in CHANGELOG.md"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo "Released version found: $LATEST"
|
||||
echo "version=$LATEST" >> $GITHUB_OUTPUT
|
||||
|
||||
# Extract the body: lines until the next ## header
|
||||
BODY=$(awk -v ver="$LATEST" '
|
||||
$0 ~ "^## \\[" ver "\\]" {found=1; next}
|
||||
found && $0 ~ "^## \\[" {exit}
|
||||
found {print}
|
||||
' CHANGELOG.md)
|
||||
|
||||
# Trim leading/trailing empty lines
|
||||
BODY=$(echo "$BODY" | sed '/^\s*$/d')
|
||||
|
||||
# Output body safely for GitHub Actions
|
||||
echo "body<<EOF" >> $GITHUB_OUTPUT
|
||||
echo "$BODY" >> $GITHUB_OUTPUT
|
||||
echo "EOF" >> $GITHUB_OUTPUT
|
||||
|
||||
- name: Create Release
|
||||
uses: akkuman/gitea-release-action@v1
|
||||
|
||||
Reference in New Issue
Block a user