Skip to content

Commit a953036

Browse files
committed
Update release workflows
1 parent 8bc6e57 commit a953036

File tree

2 files changed

+13
-9
lines changed

2 files changed

+13
-9
lines changed

.github/workflows/prep-release.yml

+4-1
Original file line numberDiff line numberDiff line change
@@ -22,16 +22,19 @@ on:
2222
jobs:
2323
prep_release:
2424
runs-on: ubuntu-latest
25+
permissions:
26+
contents: write
2527
steps:
2628
- uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1
2729

2830
- name: Prep Release
2931
id: prep-release
3032
uses: jupyter-server/jupyter_releaser/.github/actions/prep-release@v2
3133
with:
32-
token: ${{ secrets.ADMIN_GITHUB_TOKEN }}
34+
token: ${{ secrets.GITHUB_TOKEN }}
3335
version_spec: ${{ github.event.inputs.version_spec }}
3436
post_version_spec: ${{ github.event.inputs.post_version_spec }}
37+
target: ${{ github.event.inputs.target }}
3538
branch: ${{ github.event.inputs.branch }}
3639
since: ${{ github.event.inputs.since }}
3740
since_last_stable: ${{ github.event.inputs.since_last_stable }}

.github/workflows/publish-release.yml

+9-8
Original file line numberDiff line numberDiff line change
@@ -15,33 +15,34 @@ on:
1515
jobs:
1616
publish_release:
1717
runs-on: ubuntu-latest
18+
environment: release
1819
permissions:
19-
# This is useful if you want to use PyPI trusted publisher
20-
# and NPM provenance
2120
id-token: write
2221
steps:
2322
- uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1
2423

24+
- uses: actions/create-github-app-token@v1
25+
id: app-token
26+
with:
27+
app-id: ${{ vars.APP_ID }}
28+
private-key: ${{ secrets.APP_PRIVATE_KEY }}
29+
2530
- name: Populate Release
2631
id: populate-release
2732
uses: jupyter-server/jupyter_releaser/.github/actions/populate-release@v2
2833
with:
29-
token: ${{ secrets.ADMIN_GITHUB_TOKEN }}
34+
token: ${{ steps.app-token.outputs.token }}
3035
branch: ${{ github.event.inputs.branch }}
3136
release_url: ${{ github.event.inputs.release_url }}
3237
steps_to_skip: ${{ github.event.inputs.steps_to_skip }}
3338

3439
- name: Finalize Release
3540
id: finalize-release
3641
env:
37-
# The following are needed if you use legacy PyPI set up
38-
# PYPI_TOKEN: ${{ secrets.PYPI_TOKEN }}
39-
# PYPI_TOKEN_MAP: ${{ secrets.PYPI_TOKEN_MAP }}
40-
# TWINE_USERNAME: __token__
4142
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
4243
uses: jupyter-server/jupyter_releaser/.github/actions/finalize-release@v2
4344
with:
44-
token: ${{ secrets.ADMIN_GITHUB_TOKEN }}
45+
token: ${{ steps.app-token.outputs.token }}
4546
release_url: ${{ steps.populate-release.outputs.release_url }}
4647

4748
- name: "** Next Step **"

0 commit comments

Comments
 (0)