|
4 | 4 | .PHONY: develop build install |
5 | 5 |
|
6 | 6 | develop: ## install dependencies and build library |
7 | | - python -m pip install -e .[develop] |
| 7 | + uv pip install -e .[develop] |
| 8 | + |
| 9 | +requirements: ## install prerequisite python build requirements |
| 10 | + python -m pip install --upgrade pip toml |
| 11 | + python -m pip install `python -c 'import toml; c = toml.load("pyproject.toml"); print("\n".join(c["build-system"]["requires"]))'` |
| 12 | + python -m pip install `python -c 'import toml; c = toml.load("pyproject.toml"); print(" ".join(c["project"]["optional-dependencies"]["develop"]))'` |
8 | 13 |
|
9 | 14 | build: ## build the python library |
10 | 15 | python -m build -n |
11 | 16 |
|
12 | 17 | install: ## install library |
13 | | - python -m pip install . |
| 18 | + uv pip install . |
14 | 19 |
|
15 | 20 | ######### |
16 | 21 | # LINTS # |
17 | 22 | ######### |
18 | | -.PHONY: lint lints fix format lint-py lint-docs fix-py fix-docs |
| 23 | +.PHONY: lint-py lint-docs fix-py fix-docs lint lints fix format |
19 | 24 |
|
20 | | -lint-py: ## run python linter with ruff |
| 25 | +lint-py: ## lint python with ruff |
21 | 26 | python -m ruff check csp_bot |
22 | 27 | python -m ruff format --check csp_bot |
23 | 28 |
|
24 | 29 | lint-docs: ## lint docs with mdformat and codespell |
25 | | - python -m mdformat --check docs/wiki/ README.md |
26 | | - python -m codespell_lib docs/wiki/ README.md |
| 30 | + python -m mdformat --check README.md docs/wiki/ |
| 31 | + python -m codespell_lib README.md docs/wiki/ |
27 | 32 |
|
28 | | -fix-py: ## fix python formatting with ruff |
| 33 | +fix-py: ## autoformat python code with ruff |
29 | 34 | python -m ruff check --fix csp_bot |
30 | 35 | python -m ruff format csp_bot |
31 | 36 |
|
32 | 37 | fix-docs: ## autoformat docs with mdformat and codespell |
33 | | - python -m mdformat docs/wiki/ README.md |
34 | | - python -m codespell_lib --write docs/wiki/ README.md |
| 38 | + python -m mdformat README.md docs/wiki/ |
| 39 | + python -m codespell_lib --write README.md docs/wiki/ |
35 | 40 |
|
36 | | -# alias |
37 | 41 | lint: lint-py lint-docs ## run all linters |
38 | 42 | lints: lint |
39 | 43 | fix: fix-py fix-docs ## run all autoformatters |
|
0 commit comments