Skip to content

Commit fda68d7

Browse files
committed
ci: simplify for attestation-only releases (no draft needed)
Since actions/attest@v4 stores attestations via GitHub's attestation API (not as release assets), repos that only use attestation don't need draft releases. Release-please can publish the release directly. Changes: - Remove draft:true from release-please-config.json - Remove create-tag job/steps (force-tag-creation handles this) - Remove publish-release job (release is published directly) - Remove publish_release input from manual workflows
1 parent 6698515 commit fda68d7

File tree

3 files changed

+0
-54
lines changed

3 files changed

+0
-54
lines changed

.github/workflows/manual-publish.yml

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,6 @@ on:
1010
description: 'Tag of an existing draft release to upload artifacts to.'
1111
type: string
1212
required: false
13-
publish_release:
14-
description: 'Publish (un-draft) the release after all artifacts are uploaded?'
15-
type: boolean
16-
required: false
17-
default: true
1813

1914
jobs:
2015
build-publish:
@@ -63,19 +58,3 @@ jobs:
6358
uses: actions/attest@v4
6459
with:
6560
subject-checksums: checksums.txt
66-
67-
publish-release:
68-
needs: ['build-publish']
69-
if: ${{ !inputs.dry_run && inputs.publish_release }}
70-
runs-on: ubuntu-latest
71-
permissions:
72-
contents: write
73-
steps:
74-
- name: Publish release
75-
env:
76-
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
77-
TAG_NAME: ${{ inputs.tag }}
78-
run: >
79-
gh release edit "$TAG_NAME"
80-
--repo ${{ github.repository }}
81-
--draft=false

.github/workflows/release-please.yml

Lines changed: 0 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -25,22 +25,6 @@ jobs:
2525
with:
2626
fetch-depth: 0
2727

28-
- name: Create release tag
29-
if: ${{ steps.release.outputs.releases_created == 'true' }}
30-
env:
31-
TAG_NAME: ${{ steps.release.outputs.tag_name }}
32-
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
33-
run: |
34-
if gh api "repos/${{ github.repository }}/git/ref/tags/${TAG_NAME}" >/dev/null 2>&1; then
35-
echo "Tag ${TAG_NAME} already exists, skipping creation."
36-
else
37-
echo "Creating tag ${TAG_NAME}."
38-
git config user.name "github-actions[bot]"
39-
git config user.email "github-actions[bot]@users.noreply.github.com"
40-
git tag "${TAG_NAME}"
41-
git push origin "${TAG_NAME}"
42-
fi
43-
4428
- uses: actions/setup-python@v5
4529
if: ${{ steps.release.outputs.releases_created == 'true' }}
4630
with:
@@ -82,19 +66,3 @@ jobs:
8266
uses: actions/attest@v4
8367
with:
8468
subject-checksums: checksums.txt
85-
86-
publish-release:
87-
needs: ['release-package']
88-
if: ${{ needs.release-package.outputs.release-created == 'true' }}
89-
runs-on: ubuntu-latest
90-
permissions:
91-
contents: write
92-
steps:
93-
- name: Publish release
94-
env:
95-
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
96-
TAG_NAME: ${{ needs.release-package.outputs.upload-tag-name }}
97-
run: >
98-
gh release edit "$TAG_NAME"
99-
--repo ${{ github.repository }}
100-
--draft=false

release-please-config.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@
99
"PROVENANCE.md"
1010
],
1111
"include-component-in-tag": false,
12-
"draft": true,
1312
"force-tag-creation": true
1413
}
1514
}

0 commit comments

Comments
 (0)