Skip to content

Commit

Permalink
Add suggestion for isort config (#1637)
Browse files Browse the repository at this point in the history
Add suggestion for isort config

SUMMARY
We've been slowly converging on a more consistent formatting on our imports, adds isort rule which implements this (doesn't force the change at this time unless someone explicitly runs isort)
ISSUE TYPE

Feature Pull Request

COMPONENT NAME
pyproject.toml
ADDITIONAL INFORMATION

Reviewed-by: Alina Buzachis
Reviewed-by: Helen Bailey <[email protected]>
  • Loading branch information
tremble committed Jul 3, 2023
1 parent 3594dec commit bfea52d
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 0 deletions.
2 changes: 2 additions & 0 deletions changelogs/fragments/20230702-isort.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
trivial:
- added isort configs to pyproject.toml
17 changes: 17 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,20 @@ src = [
"tests/unit",
"tests/integration",
]

[tool.isort]
profile = "black"
force_single_line = true
line_length = 120

src_paths = [
"plugins",
"tests/unit",
"tests/integration",
]

sections=["FUTURE", "STDLIB", "THIRDPARTY", "FIRSTPARTY", "ANSIBLE_CORE", "ANSIBLE_AMAZON_AWS", "ANSIBLE_COMMUNITY_AWS", "LOCALFOLDER"]
known_third_party=["botocore", "boto3"]
known_ansible_core=["ansible"]
known_ansible_amazon_aws=["ansible_collections.amazon.aws"]
known_ansible_community_aws=["ansible_collections.community.aws"]

0 comments on commit bfea52d

Please sign in to comment.