-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
PyPi Setup #37
PyPi Setup #37
Conversation
pip install uv | ||
uv pip install -r pyproject.toml --system --all-extras |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think if you use uv sync .
, you can avoid the pythonpath
shenanigans for pytest.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That didn't work immediately, but it looks like uv pip install -e . --system
did! Good enough for me
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah yes, I think because you want a system-wide installation. uv sync
creates a virtual environment at $PWD/.venv
.
#!/bin/bash | ||
|
||
# Get current version from pyproject.toml | ||
CURRENT_VERSION=$(grep "^version = " pyproject.toml | sed "s/^version = \"\(.*\)\"/\1/g") | ||
# Get the new version from stdin | ||
NEW_VERSION=$1 | ||
|
||
echo "Bumping from $CURRENT_VERSION to $NEW_VERSION" | ||
|
||
# Check that the user wants to continue. exit if not | ||
read -p "Continue? (y/n) " -n 1 -r | ||
echo # move to a new line | ||
|
||
if [[ $REPLY =~ ^[Yy]$ ]]; then | ||
# Update the version in the pyproject.toml file | ||
sed -i "" "s/^version = \".*\"/version = \"$NEW_VERSION\"/g" "pyproject.toml" | ||
|
||
# Set the git tag | ||
git tag "v$NEW_VERSION" | ||
fi |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I can't be bothered to set up a gh action to bump versions so instead I'll run this locally and it'll handle all the bumping required
@ambroisie Thank you for the help! Would you mind taking a quick look over these changes and let me know if I've done anything stupid? |
No description provided.