diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index cb28d5a1..fd263e10 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -6,7 +6,20 @@ on: jobs: create-github-release: runs-on: ubuntu-22.04 - permissions: write-all + permissions: + actions: write + checks: write + contents: write + deployments: write + id-token: write + issues: write + discussions: write + packages: write + pages: write + pull-requests: write + repository-projects: write + security-events: write + statuses: write steps: - uses: actions/checkout@v3.5.3 - run: .scripts/github/release.sh @@ -16,38 +29,3 @@ jobs: with: name: upload_url path: upload_url - jvm-maven-github: - runs-on: macos-14-xlarge - permissions: - packages: write - steps: - - uses: actions/checkout@v3.5.3 - - uses: ./.github/actions/runGradleTask - with: - preTaskString: -Pversion=$GITHUB_REF_NAME - task: library:publishKotlinMultiplatformPublicationToGithubPackagesRepository - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - attach-xcframework-to-github-release: - runs-on: macos-14-xlarge - needs: [ create-github-release ] - steps: - - uses: actions/checkout@v3.5.3 - - uses: ./.github/actions/runGradleTask - with: - task: :library:assembleLibraryReleaseXCFramework - - run: zip -r Library.xcframework.zip library/build/XCFrameworks/release/library.xcframework - - uses: actions/download-artifact@v4.1.4 - with: - name: upload_url - - run: echo $UPLOAD_URL - - run: UPLOAD_URL=$(cat upload_url | sed "s/{?name,label}/?name=Library-${GITHUB_REF_NAME}.xcframework.zip/") - - run: echo $UPLOAD_URL - - run: | - curl -s \ - -X POST \ - -H "Accept: application/vnd.github+json" \ - -H "Authorization: Bearer $GITHUB_TOKEN" \ - -H "X-GitHub-Api-Version: 2022-11-28" \ - --data-binary "@Library.xcframework.zip" \ - $UPLOAD_URL