diff options
Diffstat (limited to '.isort.cfg')
-rw-r--r-- | .isort.cfg | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/.isort.cfg b/.isort.cfg new file mode 100644 index 00000000..bc47b614 --- /dev/null +++ b/.isort.cfg | |||
@@ -0,0 +1,41 @@ | |||
1 | # Copyright 2023 The Android Open Source Project | ||
2 | # | ||
3 | # Licensed under the Apache License, Version 2.0 (the "License"); | ||
4 | # you may not use this file except in compliance with the License. | ||
5 | # You may obtain a copy of the License at | ||
6 | # | ||
7 | # http://www.apache.org/licenses/LICENSE-2.0 | ||
8 | # | ||
9 | # Unless required by applicable law or agreed to in writing, software | ||
10 | # distributed under the License is distributed on an "AS IS" BASIS, | ||
11 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
12 | # See the License for the specific language governing permissions and | ||
13 | # limitations under the License. | ||
14 | |||
15 | # Config file for the isort python module. | ||
16 | # This is used to enforce import sorting standards. | ||
17 | # | ||
18 | # https://pycqa.github.io/isort/docs/configuration/options.html | ||
19 | |||
20 | [settings] | ||
21 | # Be compatible with `black` since it also matches what we want. | ||
22 | profile = black | ||
23 | |||
24 | line_length = 80 | ||
25 | length_sort = false | ||
26 | force_single_line = true | ||
27 | lines_after_imports = 2 | ||
28 | from_first = false | ||
29 | case_sensitive = false | ||
30 | force_sort_within_sections = true | ||
31 | order_by_type = false | ||
32 | |||
33 | # Ignore generated files. | ||
34 | extend_skip_glob = *_pb2.py | ||
35 | |||
36 | # Allow importing multiple classes on a single line from these modules. | ||
37 | # https://google.github.io/styleguide/pyguide#s2.2-imports | ||
38 | single_line_exclusions = | ||
39 | abc, | ||
40 | collections.abc, | ||
41 | typing, | ||