Use ruff check --fix instead of isort.

This commit is contained in:
Felix Fontein
2025-12-25 21:59:18 +01:00
parent 9cbf9fc6ec
commit 81c3ae5d84
4 changed files with 14 additions and 9 deletions

View File

@@ -8,3 +8,5 @@
aec1826c34051b9e7f8af7950489915b661e320b
# Reformat with black another time, this time without Python 2 compatibility
797bd8a6e2a6f4a37a89ecb15ca34ec88b33258d
# Reformat with ruff check --fix instead of isort
d1f3518d51bc3efd6dc1d2166b7b410702bd58d5

View File

@@ -1,7 +0,0 @@
# Copyright (c) Ansible Project
# GNU General Public License v3.0+ (see LICENSES/GPL-3.0-or-later.txt or https://www.gnu.org/licenses/gpl-3.0.txt)
# SPDX-License-Identifier: GPL-3.0-or-later
[isort]
profile=black
lines_after_imports = 2

View File

@@ -13,9 +13,14 @@ stable_branches = [ "stable-*" ]
[sessions]
[sessions.lint]
run_isort = true
isort_config = ".isort.cfg"
run_isort = false
run_black = true
run_ruff_autofix = true
ruff_autofix_config = "ruff.toml"
ruff_autofix_select = [
"I",
"RUF022",
]
run_ruff_check = true
ruff_check_config = "ruff.toml"
run_flake8 = true

View File

@@ -29,3 +29,8 @@ unfixable = []
# Allow unused variables when underscore-prefixed or starting with dummy
dummy-variable-rgx = "^(_|dummy).*$"
[lint.isort]
known-third-party = [
"ansible_collections.community.internal_test_tools",
]