update github actions

This commit is contained in:
Vxrtrauter
2025-10-12 15:25:39 +02:00
parent 7d77a88245
commit 30e920675d
+18 -17
View File
@@ -25,14 +25,14 @@ jobs:
matrix: matrix:
include: include:
- os: ubuntu-latest - os: ubuntu-latest
artifact_name: SoftwareManager-dev-${{ github.run_number }}-linux artifact_name: SoftwareManager-dev-${{ github.sha }}-linux
asset_name: SoftwareManager-dev-${{ github.run_number }}-linux asset_name: SoftwareManager-dev-${{ github.sha }}-linux
- os: windows-latest - os: windows-latest
artifact_name: SoftwareManager-dev-${{ github.run_number }}-windows.exe artifact_name: SoftwareManager-dev-${{ github.sha }}-windows.exe
asset_name: SoftwareManager-dev-${{ github.run_number }}-windows.exe asset_name: SoftwareManager-dev-${{ github.sha }}-windows.exe
- os: macos-latest - os: macos-latest
artifact_name: SoftwareManager-dev-${{ github.run_number }}-macos artifact_name: SoftwareManager-dev-${{ github.sha }}-macos
asset_name: SoftwareManager-dev-${{ github.run_number }}-macos asset_name: SoftwareManager-dev-${{ github.sha }}-macos
runs-on: ${{ matrix.os }} runs-on: ${{ matrix.os }}
@@ -111,19 +111,20 @@ jobs:
- name: Generate version - name: Generate version
id: version id: version
run: | run: |
MAJOR=1 COMMIT_SHA=${{ github.sha }}
MINOR=0 SHORT_SHA=${COMMIT_SHA:0:7}
PATCH=${{ github.run_number }} VERSION="${SHORT_SHA}-dev"
VERSION="v${MAJOR}.${MINOR}.${PATCH}-dev"
echo "version=${VERSION}" >> $GITHUB_OUTPUT echo "version=${VERSION}" >> $GITHUB_OUTPUT
echo "short_sha=${SHORT_SHA}" >> $GITHUB_OUTPUT
echo "Generated version: ${VERSION}" echo "Generated version: ${VERSION}"
- name: Prepare release files - name: Prepare release files
run: | run: |
mkdir -p release mkdir -p release
cp artifacts/ubuntu-latest-build/SoftwareManager-dev-${{ github.run_number }}-linux release/SoftwareManager-dev-1.0.${{ github.run_number }}-linux SHORT_SHA="${{ steps.version.outputs.short_sha }}"
cp artifacts/windows-latest-build/SoftwareManager-dev-${{ github.run_number }}-windows.exe release/SoftwareManager-dev-1.0.${{ github.run_number }}-windows.exe cp artifacts/ubuntu-latest-build/SoftwareManager-dev-*-linux release/SoftwareManager-dev-${SHORT_SHA}-linux
cp artifacts/macos-latest-build/SoftwareManager-dev-${{ github.run_number }}-macos release/SoftwareManager-dev-1.0.${{ github.run_number }}-macos cp artifacts/windows-latest-build/SoftwareManager-dev-*-windows.exe release/SoftwareManager-dev-${SHORT_SHA}-windows.exe
cp artifacts/macos-latest-build/SoftwareManager-dev-*-macos release/SoftwareManager-dev-${SHORT_SHA}-macos
chmod +x release/SoftwareManager-dev-*-linux release/SoftwareManager-dev-*-macos chmod +x release/SoftwareManager-dev-*-linux release/SoftwareManager-dev-*-macos
ls -la release/ ls -la release/
@@ -135,8 +136,8 @@ jobs:
draft: true draft: true
prerelease: true prerelease: true
files: | files: |
release/SoftwareManager-dev-1.0.${{ github.run_number }}-linux release/SoftwareManager-dev-${{ steps.version.outputs.short_sha }}-linux
release/SoftwareManager-dev-1.0.${{ github.run_number }}-windows.exe release/SoftwareManager-dev-${{ steps.version.outputs.short_sha }}-windows.exe
release/SoftwareManager-dev-1.0.${{ github.run_number }}-macos release/SoftwareManager-dev-${{ steps.version.outputs.short_sha }}-macos
env: env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}