-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
b826de4
commit 035307c
Showing
2 changed files
with
28 additions
and
59 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +1,32 @@ | ||
lint: | ||
@echo Running black | ||
black . | ||
install-dev: | ||
pip install -r dev-requirements.txt | ||
|
||
@echo Running ruff | ||
ruff check . --fix | ||
install-deps: | ||
pip install -r requirements.txt | ||
|
||
test: | ||
@echo ––– Testing ––– | ||
pytest -n auto -rfE --failed-first --disable-warnings -q | ||
install: | ||
make install-deps | ||
pip install -e . | ||
|
||
type-check: | ||
@echo ––– Running static type checks ––– | ||
pyright . | ||
test: ## Run tests | ||
pytest {{cookiecutter.package_name}} | ||
|
||
install: | ||
pip install --upgrade -e .[dev,tests] | ||
|
||
validate: | ||
@echo ––– Ensuring dependencies are up to date. This will take a few moments --- | ||
@make install > /dev/null | ||
@make lint && make type-check && make test | ||
|
||
pr: | ||
gh pr create -w | ||
make validate | ||
git push | ||
gh pr merge --auto --merge | ||
lint: ## Format code | ||
ruff check {{cookiecutter.package_name}} --fix | ||
ruff format {{cookiecutter.package_name}} | ||
|
||
type-check: ## Type-check code | ||
pyright {{cookiecutter.package_name}} | ||
|
||
validate: ## Run all checks | ||
make lint | ||
make type-check | ||
make test | ||
|
||
create-and-merge-pr: | ||
gh pr create -w || true | ||
gh pr merge --auto --merge --delete-branch | ||
|
||
pr: ## Run relevant tests before PR | ||
make create-and-merge-pr | ||
make validate |