From 8254cd8ee34579176d36606dc4e6cae89e7bfca5 Mon Sep 17 00:00:00 2001 From: Deukhoofd Date: Tue, 17 Nov 2026 19:43:46 +0100 Subject: [PATCH] revert change to use built-in token --- .gitea/workflows/build.yaml | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/.gitea/workflows/build.yaml b/.gitea/workflows/build.yaml index a155b4e..10aeef6 100644 --- a/.gitea/workflows/build.yaml +++ b/.gitea/workflows/build.yaml @@ -11,9 +11,6 @@ env: jobs: Build: runs-on: [ ubuntu-latest ] - permissions: - contents: read - packages: write steps: - name: Checkout uses: actions/checkout@v4 @@ -42,10 +39,12 @@ jobs: - name: Pack if: github.event_name == 'push' && (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/tags/v')) run: dotnet pack PkmnLib.NET.slnx -c Release --nologo --no-restore --no-build -p:Version=$VERSION -o ./packages + # Needs a personal access token with write:package scope: Gitea's automatic Actions token + # only ever gets read access to the package registry, so pushing with it returns 401. - name: Publish to Gitea NuGet feed if: github.event_name == 'push' && (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/tags/v')) run: > dotnet nuget push "./packages/*.nupkg" --source "${{ github.server_url }}/api/packages/${{ github.repository_owner }}/nuget/index.json" - --api-key "${{ secrets.GITHUB_TOKEN }}" + --api-key "${{ secrets.PACKAGES_TOKEN }}" --skip-duplicate