Skip to content

Commit

Permalink
conditional Python versioning for poetry example
Browse files Browse the repository at this point in the history
  • Loading branch information
tyler-yankee committed Jan 22, 2025
1 parent fb00a52 commit 60c56d9
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions drake_poetry/.github/ci_build_test
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,14 @@ set -euxo pipefail

poetry --version
"python$PYTHON_VERSION" --version
poetry init -n --python "~$PYTHON_VERSION"
poetry env use $PYTHON_VERSION
# Set up the appropriate version of Python for Poetry
# if one other than the default is specified
if [[ "$PYTHON_VERSION" != "3" ]]; then
poetry init -n --python "~$PYTHON_VERSION"
poetry env use $PYTHON_VERSION
else
poetry init -n
fi

poetry add drake
eval $(poetry env activate)
Expand Down

0 comments on commit 60c56d9

Please sign in to comment.