Skip to content

Commit

Permalink
chore: add a justfile (#389)
Browse files Browse the repository at this point in the history
Similar to other hugrverse projects
  • Loading branch information
aborgna-q authored Aug 16, 2024
1 parent 81f65f7 commit 25fed3e
Showing 1 changed file with 37 additions and 0 deletions.
37 changes: 37 additions & 0 deletions justfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
# List the available commands
help:
@just --list --justfile {{justfile()}}

# Prepare the environment for development, installing all the dependencies and
# setting up the pre-commit hooks.
setup:
poetry install
[[ -n "${JUST_INHIBIT_GIT_HOOKS:-}" ]] || poetry run pre-commit install -t pre-commit

# Run the pre-commit checks.
check:
poetry run pre-commit run --all-files

# Run all the tests.
test:
poetry run pytest

# Auto-fix all clippy warnings.
fix:
poetry run ruff check --fix guppylang

# Format the code.
format:
poetry run ruff format guppylang

# Generate a test coverage report.
coverage:
poetry run pytest --cov=./ --cov-report=html

# Load a shell with all the dependencies installed
shell:
poetry shell


build-py-docs:
cd hugr-py/docs && ./build.sh

0 comments on commit 25fed3e

Please sign in to comment.