.forgejo/workflows/dotnet.yaml aktualisiert
Some checks failed
Dotnet Build / build (push) Failing after 1m39s

This commit is contained in:
WeeXnes 2025-05-18 19:52:54 +00:00
parent 6846729432
commit 77250ee7c1

View file

@ -75,13 +75,26 @@ jobs:
git tag v$env:PROJECT_VERSION git tag v$env:PROJECT_VERSION
git push origin v$env:PROJECT_VERSION git push origin v$env:PROJECT_VERSION
- name: Upload to Forgejo - name: Upload Release Asset to Forgejo
uses: actions/forgejo-release@v2.6.0 env:
with: RELEASE_TOKEN: ${{ secrets.RELEASE_TOKEN }}
direction: upload PROJECT_VERSION: ${{ env.PROJECT_VERSION }}
url: https://git.weexnes.dev/ run: |
repo: WeeXnes/Cryptura $repoOwner = "WeeXnes"
token: ${{ secrets.RELEASE_TOKEN }} $repoName = "WeeXnesSuite"
tag: v${{ steps.get_version.outputs.version }} $tag = "$env:PROJECT_VERSION"
release-dir: release $fileName = "currentRelease_$env:PROJECT_VERSION.zip"
release-notes: "Automated release for version ${{ steps.get_version.outputs.version }}" $filePath = "release/$fileName"
$uploadUrl = "https://git.weexnes.dev/api/v1/repos/$repoOwner/$repoName/releases/tags/$tag"
$release = Invoke-RestMethod -Headers @{ Authorization = "token $env:RELEASE_TOKEN" } -Uri $uploadUrl
$uploadUrlTemplate = $release.upload_url
$uploadUrlFinal = $uploadUrlTemplate -replace "\{\?name,label\}", "?name=$fileName"
Invoke-RestMethod -Uri $uploadUrlFinal `
-Headers @{ Authorization = "token $env:RELEASE_TOKEN" } `
-Method Post `
-ContentType "application/zip" `
-InFile $filePath