Contributing
To contribute to this tool, first checkout the code. Then create a new virtual environment:
cd braglog
python -m venv .venv
source .venv/bin/activate
Now install the dependencies and test dependencies:
pip install -e '.[dev]'
Or if you are using uv:
uv sync --extra dev
To run the tests:
uv run pytest .
To help ensure consistent code quality that follows our guidelines, pre-commit may be used. We have git hooks defined which will execute before commit. To install the hooks:
pre-commit install
Environment Variables
The application uses the following environment variable:
BRAGLOG_CONFIG_DIR: Specifies the directory where the application's configuration and database files are stored. If not set, the default directory will be used (typically a platform-specific application directory).
To set this environment variable, use the following command:
export BRAGLOG_CONFIG_DIR=.
Release process
To release a new version:
- Create a new branch like
v0.5.0 - Update
docs/changelog.mdwith the new changes. - Update the version number in
setup.pyand runuv sync. - Create a git tag:
git tag v0.5.0. - Create a GitHub release for the new version using the tag
Documentation
The documentation is built using MkDocs Material.
Setting up documentation locally
- Make sure you've installed the development dependencies as mentioned above.
- Run the following command to start a local documentation server:
mkdocs serve