develop #1

Open
maddo wants to merge 126 commits from develop into master
Showing only changes of commit daf3b5ad2c - Show all commits

feat: Enhance Windows Avalonia build workflow with NuGet source validation and configuration
Some checks failed
Build Windows Avalonia / build (push) Failing after 1m4s
Build Windows Avalonia / release (push) Has been skipped

MaddoScientisto 2026-03-16 22:22:13 +01:00

View file

@ -14,10 +14,15 @@ env:
PROJECT_PATH: imagecatalog/ImageCatalog 2.csproj
PUBLISH_DIR: artifacts/publish/win-x64
ARTIFACT_NAME: imagecatalog-windows-avalonia
NUGET_SOURCE_NAME: Nuget-GitLab-AIFotoONLUS
NUGET_SOURCE_URL: https://gitlab.com/api/v4/projects/79509532/packages/nuget/index.json
jobs:
build:
runs-on: docker
env:
NUGET_USERNAME: ${{ secrets.NUGET_USERNAME }}
NUGET_PASSWORD: ${{ secrets.NUGET_PASSWORD }}
steps:
- name: Checkout
@ -28,8 +33,35 @@ jobs:
with:
dotnet-version: ${{ env.DOTNET_VERSION }}
- name: Validate NuGet secrets
run: |
set -eu
if [ -z "${NUGET_USERNAME}" ]; then
echo "secrets.NUGET_USERNAME is required"
exit 1
fi
if [ -z "${NUGET_PASSWORD}" ]; then
echo "secrets.NUGET_PASSWORD is required"
exit 1
fi
- name: Configure private NuGet source
run: |
set -eu
temp_config="${RUNNER_TEMP}/nuget.config"
cp NuGet.Config "${temp_config}"
dotnet nuget update source "${{ env.NUGET_SOURCE_NAME }}" \
--source "${{ env.NUGET_SOURCE_URL }}" \
--username "${NUGET_USERNAME}" \
--password "${NUGET_PASSWORD}" \
--store-password-in-clear-text \
--configfile "${temp_config}"
echo "NUGET_CONFIG_PATH=${temp_config}" >> "${GITHUB_ENV}"
- name: Restore
run: dotnet restore "${{ env.PROJECT_PATH }}" -r win-x64
run: dotnet restore "${{ env.PROJECT_PATH }}" -r win-x64 --configfile "${NUGET_CONFIG_PATH}"
- name: Publish Windows Avalonia build
run: |
@ -38,6 +70,7 @@ jobs:
-c Release \
-r win-x64 \
--self-contained true \
--no-restore \
-p:AvaloniaWindowsCrossPublish=true \
-p:PublishSingleFile=true \
-p:PublishTrimmed=false \