Skip to content

Commit

Permalink
feat: make license-checking optional
Browse files Browse the repository at this point in the history
  • Loading branch information
AJDERS committed Nov 30, 2023
1 parent ce2224f commit 43b2fdf
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 2 deletions.
1 change: 1 addition & 0 deletions cookiecutter.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,6 @@
"open_source": "Is this a public open source project? [y/N]",
"python_version": "Your Python version, written as 3.xx",
"dependency_manager": "Which dependency manager do you use? [pip/POETRY]",
"license-checker": "Do you want to use license-checker? [Y/n]",
"_copy_without_render": []
}
5 changes: 3 additions & 2 deletions {{cookiecutter.project_name}}/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ testpaths = [
"tests",
"src/{{cookiecutter.project_name}}",
]

{%- if cookiecutter.license-checker == "y" -%}
[tool.pylic]
safe_licenses = [
"1-clause BSD License",
Expand Down Expand Up @@ -312,4 +312,5 @@ safe_licenses = [
]
unsafe_packages = [
"unlicensedPackage",
]
]
{% endif %}
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
repos:
- repo: https://github.com/ambv/black
rev: 23.7.0
hooks:
- id: black
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.0.290
hooks:
- id: ruff
args: [--fix, --exit-non-zero-on-fix]
types_or: [python, pyi]
- repo: https://github.com/kynan/nbstripout
rev: 0.6.0
hooks:
- id: nbstripout
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.4.1
hooks:
- id: mypy
args: [--install-types, --non-interactive, --ignore-missing-imports, --show-error-codes]

0 comments on commit 43b2fdf

Please sign in to comment.