Skip to content

Commit

Permalink
build: add pre-commit hook to add license header to python modules
Browse files Browse the repository at this point in the history
  • Loading branch information
afuetterer committed Jan 12, 2024
1 parent c7cb7e5 commit f8fba8b
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
7 changes: 7 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,13 @@ repos:
args: [--autofix, --indent, '2']
- id: pretty-format-yaml
args: [--autofix, --indent, '2']
- repo: https://github.com/Lucas-C/pre-commit-hooks
rev: v1.5.4
hooks:
- id: insert-license
types: [python]
args: [--license-filepath=docs/license_header.txt]
exclude: docs
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.1.11
hooks:
Expand Down
3 changes: 3 additions & 0 deletions docs/license_header.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
SPDX-FileCopyrightText: 2020 PANGAEA (https://www.pangaea.de/)

SPDX-License-Identifier: MIT

0 comments on commit f8fba8b

Please sign in to comment.