Skip to content

Commit 81fd8de

Browse files
committed
AEA-5986 Accept pypi token secrets.
1 parent a8fc173 commit 81fd8de

2 files changed

Lines changed: 9 additions & 1 deletion

File tree

.github/workflows/tag-release.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,12 @@ on:
6969
NPM_TOKEN:
7070
required: false
7171
description: "NPM token to publish packages"
72+
PYPI_TOKEN:
73+
required: false
74+
description: "PyPI token to publish packages"
75+
PYPI_TEST_TOKEN:
76+
required: false
77+
description: "Test PyPI token to publish packages to test index"
7278
jobs:
7379
install_semantic_release:
7480
# Install asdf

release.config.cjs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ const mainBranch = process.env.MAIN_BRANCH || "main"
88
const pypiPublish = process.env.PYPI_PUBLISH || false
99
const pypiTestPublish = process.env.PYPI_TEST_PUBLISH || false
1010
const pypiRepoUrl = pypiTestPublish ? "https://test.pypi.org/legacy/" : "https://upload.pypi.org/legacy/"
11+
const pypiToken = pypiTestPublish ? process.env.PYPI_TEST_TOKEN : process.env.PYPI_TOKEN
1112

1213
module.exports = {
1314
branches: [
@@ -81,7 +82,8 @@ module.exports = {
8182
"semantic-release-pypi",
8283
{
8384
pypiPublish, pypiPublish,
84-
repoUrl: pypiRepoUrl
85+
repoUrl: pypiRepoUrl,
86+
repoToken: pypiToken
8587
}
8688
],
8789
[

0 commit comments

Comments
 (0)