First off, thank you so much for taking the time to contribute! 👍
This document is meant to help you get started and save you time. It is not meant to be a barrier or hurdle. Don’t be afraid to open incomplete PRs and ask questions!
No contribution is too small. Typo and grammar fixes are welcome.
-
Check if there’s a matching issue before opening a new issue or pull request
-
When possible, provide a usage example to reproduce bugs
These steps should help you setup a development environment for the Globus CLI in which you can interactively write and test commands.
-
Create a fork of the globus/globus-cli repository.
Follow https://github.com/globus/globus-cli/fork in a browser.
-
Clone your forked repository & navigate to it.
git clone <fork-repo-url> && cd globus-cli
-
Install dependencies in a local virtualenv for development.
make install
-
Activate the resulting virtualenv.
source .venv/bin/activate
You should now have, in your virtualenv, the globus-cli installed, pointed at
your local copy of the repo. globus will invoke code directly out of the
repo.
We use tox to run our tests against all supported Python versions.
You can use a tool like pyenv to install all of the Python versions, or
install uv and the tox-uv plugin to have uv manage the interpreter versions for you.
(tox-uv will also use uv to provision test environments.)
For example:
uv tool install tox --with=tox-uv # or pipx install tox pipx inject tox tox-uv
Once installed, you can run all tests with:
tox run
|
Tip
|
Try To run a single environment, use the |
We use pre-commit to run (optional) pre-commit hooks for linting and formatting.
Use pre-commit install if you want to setup the hooks locally.
Code is also type-checked with mypy, which you can run with tox run -e mypy.
Most changes to CLI functionality should be included in the changelog.
Pull Requests must have a changelog fragment or be approved by a maintainer to not need one.
See the changelog doc for information about how to create fragments for your changes.
Maintainers use the no-news-is-good-news label to indicate that no changelog is needed.
If you are a CLI maintainer, you need to be able to do a release. For steps, see the RELEASING doc.