openpilot/teleoprtc_repo/scripts/publish_pypi.sh
Vehicle Researcher c5d5c5d1f3 openpilot v0.10.1 release
date: 2025-10-24T00:30:59
master commit: 405631baf9685e171a0dd19547cb763f1b163d18
2025-10-24 00:31:03 -07:00

24 lines
410 B
Bash
Executable File

#!/usr/bin/env bash
set -e
if [[ -z "$1" ]]; then
echo "Usage: $0 <PyPI token>"
exit 1
fi
PYPI_TOKEN="$1"
# install required packages
pip install --upgrade twine build
# build the package
python3 -m build
# upload to PyPI
REPOSITORY=""
if [[ -n "$TEST_UPLOAD" ]]; then
REPOSITORY="--repository testpypi"
fi
python3 -m twine upload $REPOSITORY --username __token__ --password "$PYPI_TOKEN" dist/*