-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix linting the template check #287
Changes from all commits
8dc3afd
ee6f5a3
866c938
43e963a
b999b00
5857cb7
13514d2
749a69a
85c3155
18b414a
52c3337
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,7 +5,10 @@ repos: | |
- id: ruff | ||
args: | ||
- --config=pyproject.toml | ||
exclude: "{{cookiecutter.project_slug}}/src/{{cookiecutter.package_name}}" | ||
exclude: |- | ||
(?x)( | ||
Comment on lines
+8
to
+9
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I've changed to this syntax in the case that we need to ignore more than one thing There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I don't get it. Why are we excluding this all of a sudden? And why all over the shop? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. If you look, it's the exact same Unfortunately, @pre-commit isn't using an array for |
||
{{cookiecutter.project_slug}}/src/{{cookiecutter.package_name}} | ||
) | ||
- id: ruff-format | ||
args: | ||
- --config=pyproject.toml | ||
|
@@ -17,7 +20,10 @@ repos: | |
rev: v0.23.1 | ||
hooks: | ||
- id: toml-sort-fix | ||
exclude: "{{cookiecutter.project_slug}}/pyproject.toml" | ||
exclude: |- | ||
(?x)( | ||
{{cookiecutter.project_slug}}/pyproject.toml | ||
) | ||
- repo: https://github.com/pre-commit/mirrors-mypy | ||
rev: v1.8.0 | ||
hooks: | ||
|
@@ -26,12 +32,19 @@ repos: | |
- --config-file=pyproject.toml | ||
additional_dependencies: | ||
- pytest | ||
exclude: "{{cookiecutter.project_slug}}/(src/{{cookiecutter.package_name}}|tests)" | ||
exclude: |- | ||
(?x)( | ||
{{cookiecutter.project_slug}}/src/{{cookiecutter.package_name}}| | ||
{{cookiecutter.project_slug}}/tests | ||
) | ||
- repo: https://github.com/pre-commit/mirrors-prettier | ||
rev: v3.1.0 | ||
hooks: | ||
- id: prettier | ||
exclude: "{{cookiecutter.project_slug}}/.github/workflows/tests.yml" | ||
exclude: |- | ||
(?x)( | ||
{{cookiecutter.project_slug}}/.github/workflows/tests.yml | ||
) | ||
- repo: https://github.com/pre-commit/pre-commit-hooks | ||
rev: v4.5.0 | ||
hooks: | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -649,4 +649,4 @@ what you want to do, use the GNU Lesser General Public License instead of this | |
License. But first, please read | ||
<<http://www.gnu.org/philosophy/why-not-lgpl.html>>. | ||
|
||
{%- endif -%} | ||
{%- endif %} | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thanks to @dpshelio for helping me on this one! |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
"""{{cookiecutter.package_name}} package.""" | ||
from ._version import __version__ # noqa: F401 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🐛-fix here ☝️ ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That and the
working-directory
. We were never actually linting the template before.