diff --git a/Makefile b/Makefile index d6b5f33..dd9cebd 100644 --- a/Makefile +++ b/Makefile @@ -11,7 +11,7 @@ else TEST_COMMAND := PYTHONPATH=$(PYTHONPATH) poetry run pytest -c pyproject.toml --cov-report=html --cov=hooks tests/ endif -.PHONY: lock install pre-commit-install pre-commit-uninstall polish-codestyle formatting format test check-codestyle check-safety lint help +.PHONY: lock install pre-commit-install pre-commit-uninstall format test check-codestyle check-safety lint help install: poetry lock -n && poetry export --without-hashes > requirements.txt @@ -23,12 +23,10 @@ pre-commit-install: pre-commit-uninstall: poetry run pre-commit uninstall -polish-codestyle: +format: poetry run ruff format --config pyproject.toml hooks tests p3g poetry run ruff check --fix --config pyproject.toml hooks tests p3g -format: polish-codestyle - test: $(TEST_COMMAND) poetry run coverage-badge -o assets/images/coverage.svg -f @@ -49,8 +47,6 @@ help: @echo "install: Install the project dependencies." @echo "pre-commit-install: Install the pre-commit hooks." @echo "pre-commit-uninstall: Uninstall the pre-commit hooks." - @echo "polish-codestyle: Format the codebase using ruff." - @echo "formatting: Format the codebase using ruff." @echo "format: Format the codebase using ruff." @echo "test: Run the test suite." @echo "check-codestyle: Check the codebase using ruff." diff --git a/README.md b/README.md index 04865a7..fef39a7 100644 --- a/README.md +++ b/README.md @@ -188,9 +188,6 @@ make pre-commit-install Automatic formatting uses `ruff`. ```bash -make polish-codestyle - -# or use synonym make format ``` diff --git a/README_zh.md b/README_zh.md index 728fd4a..88b0ef3 100644 --- a/README_zh.md +++ b/README_zh.md @@ -179,9 +179,6 @@ make pre-commit-install 自动格式化使用 `ruff`。 ```bash -make polish-codestyle - -# 或使用同义词 make format ``` diff --git a/{{ cookiecutter.project_name.lower().replace(' ', '_').replace('-', '_') }}/DELETE_ME.md b/{{ cookiecutter.project_name.lower().replace(' ', '_').replace('-', '_') }}/DELETE_ME.md index 8960cda..722580a 100644 --- a/{{ cookiecutter.project_name.lower().replace(' ', '_').replace('-', '_') }}/DELETE_ME.md +++ b/{{ cookiecutter.project_name.lower().replace(' ', '_').replace('-', '_') }}/DELETE_ME.md @@ -45,7 +45,7 @@ priority = "default" 4. Run the codestyle to polish your code: ```bash -make polish-codestyle +make format ``` 5. Upload initial code to GitHub: