From 38358f9265e98468d1c78a67256900636e54b564 Mon Sep 17 00:00:00 2001 From: Remi Gau Date: Mon, 5 Feb 2024 17:40:43 +0100 Subject: [PATCH] use isort (#84) --- .pre-commit-config.yaml | 8 ++++---- .vscode/settings.json | 3 ++- file_tree_check/smartPath.py | 6 ++---- 3 files changed, 8 insertions(+), 9 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index a5e258d..d4b7106 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -26,11 +26,11 @@ repos: hooks: - id: flynt -- repo: https://github.com/asottile/reorder-python-imports - rev: v3.12.0 +- repo: https://github.com/pycqa/isort + rev: 5.13.2 hooks: - - id: reorder-python-imports - args: [--py38-plus, --add-import, from __future__ import annotations] + - id: isort + args: [--profile, black] # - repo: https://github.com/pre-commit/mirrors-mypy # rev: v1.3.0 diff --git a/.vscode/settings.json b/.vscode/settings.json index 016f692..a734c0e 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -4,5 +4,6 @@ "editor.defaultFormatter": "ms-python.black-formatter" }, "python.formatting.provider": "none", - "editor.formatOnPaste": true + "editor.formatOnPaste": true, + "esbonio.sphinx.confDir": "" } diff --git a/file_tree_check/smartPath.py b/file_tree_check/smartPath.py index b09724a..03c4899 100644 --- a/file_tree_check/smartPath.py +++ b/file_tree_check/smartPath.py @@ -1,12 +1,10 @@ from __future__ import annotations import re -from abc import ABC -from abc import abstractmethod +from abc import ABC, abstractmethod from pathlib import Path -from file_tree import FileTree -from file_tree import Template +from file_tree import FileTree, Template from file_tree.template import Literal