Skip to content

Commit

Permalink
Merge branch 'update-ruff' into 'master'
Browse files Browse the repository at this point in the history
Update ruff

See merge request ogs/ogs!4995
  • Loading branch information
bilke committed May 6, 2024
2 parents d6593df + bfbbf4b commit 9186f19
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 2 deletions.
15 changes: 13 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -79,12 +79,23 @@ repos:
args: [sync]
- id: vale
args: [--output=line, --minAlertLevel=error]
- repo: https://github.com/charliermarsh/ruff-pre-commit
rev: "v0.1.0"
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: "v0.4.2"
hooks:
- id: ruff
types_or: [python, pyi, jupyter]
args: [--show-source]
# A variant of the ruff hook above that automatically applies proposed fixes.
# Runs only manually.
# Run this hook (and all other manual hooks if any) with:
# pre-commit run --hook-stage manual
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: "v0.4.2"
hooks:
- id: ruff
types_or: [python, pyi, jupyter]
args: [--show-source, --fix, --exit-non-zero-on-fix]
stages: [manual]
# Enable on demand, run with
# pre-commit run --all-files clang-format
#
Expand Down
1 change: 1 addition & 0 deletions NumLib/TimeStepping/TimeStep.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
#pragma once

#include <cstddef>
#include <limits>

namespace NumLib
{
Expand Down
4 changes: 4 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,10 @@ exclude = ["scripts/doc", "*ci-skip*"]
flake8-unused-arguments.ignore-variadic-names = true
line-length = 80

[tool.ruff.lint]
# allow en-dash
allowed-confusables = [""]

[tool.ruff.per-file-ignores]
"tests/**" = ["T20"]
"*.ipynb" = ["E402"] # Top-level imports

0 comments on commit 9186f19

Please sign in to comment.