File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2929 " @semantic-release/exec" ,
3030 {
3131 "prepareCmd" : " ./scripts/createdistribution.sh" ,
32- "publishCmd" : " ./scripts/uploaddistribution_live.sh"
32+ "publishCmd" : " ./scripts/uploaddistribution_test.sh && ./scripts/ uploaddistribution_live.sh"
3333 }
3434 ],
3535 [
Original file line number Diff line number Diff line change 11#! /bin/bash
2- twine upload --skip-existing -u " ${TWINE_LIVE_USERNAME} " -p " ${TWINE_LIVE_PASSWORD } " dist/*
2+ twine upload --skip-existing -p " ${TWINE_LIVE_TOKEN } " dist/*
Original file line number Diff line number Diff line change 11#! /bin/bash
22
33# This script uploads the distribution packages to the Test PyPI repository.
4- # It uses the environment variables TWINE_TEST_USERNAME and TWINE_TEST_PASSWORD for authentication.
4+ # It uses the environment variables TWINE_TEST_USERNAME and TWINE_TEST_TOKEN for authentication.
55
66# TWINE_TEST_USERNAME: The username for Test PyPI.
7- # TWINE_TEST_PASSWORD: The password for Test PyPI.
7+ # TWINE_TEST_TOKEN: The password for Test PyPI.
8+
9+ # no user name is needed when using API tokens, so we can skip the username and just use the token for authentication.
810
911# Increment the version number in your setup.py or pyproject.toml file before running this script.
1012# Example for setup.py: update the version parameter in the setup() function.
1113# Example for pyproject.toml: update the version field under [tool.poetry].
1214
13- twine upload -u " ${TWINE_TEST_USERNAME} " - p " ${TWINE_TEST_PASSWORD } " --repository-url https://test.pypi.org/legacy/ dist/* --skip-existing
15+ twine upload -p " ${TWINE_TEST_TOKEN } " --repository-url https://test.pypi.org/legacy/ dist/* --skip-existing
You can’t perform that action at this time.
0 commit comments