This python cli app uses dynaconf to manage secrets and environment variables.
So that you can use your secrets and environment variables declared in settings.toml
or .settings.toml
, use the GITHUB
prefix value of envvar_prefix
declared in config.py.
Set up python package dependencies in pyproject.toml
:
uv sync
Activate virtualenv
:
source .venv/bin/activate
Export required environment variables:
export GITHUB_USER="<github-username>"
export GITHUB_AUTH_TOKEN="<github-auth-token>"
Run the github-rest-api
cli:
github-rest-api -h
List all defined parameters:
dynaconf -i github_rest_api.config.settings list
Validate all defined parameters:
dynaconf -i github_rest_api.config.settings validate
NOTE: dynaconf_validators.toml
must exist.
Install ruff via uv:
uv tool install ruff
Run check:
ruff check .
Run format:
ruff format .