Skip to content

Commit

Permalink
feat: add pre commit hooks
Browse files Browse the repository at this point in the history
  • Loading branch information
furkan-bilgin committed Oct 12, 2024
1 parent fd19b40 commit 0908554
Show file tree
Hide file tree
Showing 3 changed files with 176 additions and 0 deletions.
23 changes: 23 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
repos:
- repo: https://github.com/astral-sh/uv-pre-commit
# uv version.
rev: 0.4.20
hooks:
# Run the pip compile
- id: pip-compile
args: [requirements.in, -o, requirements.txt]
- repo: https://github.com/astral-sh/uv-pre-commit
# uv version.
rev: 0.4.20
hooks:
# Update the uv lockfile
- id: uv-lock
- repo: https://github.com/astral-sh/ruff-pre-commit
# Ruff version.
rev: v0.6.9
hooks:
# Run the linter.
- id: ruff
args: [--fix]
# Run the formatter.
- id: ruff-format
6 changes: 6 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,11 @@ dependencies = [
"uproot>=5.4.1",
]

[tool.uv]
dev-dependencies = [
"pre-commit>=4.0.1",
"ruff>=0.6.9",
]

[tool.uv.sources]
n1081b-sdk = { git = "https://github.com/ENRG-tr/N1081B-SDK-Python.git" }
147 changes: 147 additions & 0 deletions uv.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 0908554

Please sign in to comment.