mirror of
https://github.com/kovidgoyal/kitty
synced 2026-07-17 14:04:52 +02:00
Sort imports
This commit is contained in:
@@ -3,11 +3,11 @@
|
|||||||
|
|
||||||
import os
|
import os
|
||||||
import sys
|
import sys
|
||||||
|
from collections.abc import Iterable, Mapping, Sequence
|
||||||
from contextlib import suppress
|
from contextlib import suppress
|
||||||
from functools import partial
|
from functools import partial
|
||||||
from types import MappingProxyType
|
from types import MappingProxyType
|
||||||
from typing import Any
|
from typing import Any
|
||||||
from collections.abc import Iterable, Mapping, Sequence
|
|
||||||
|
|
||||||
from kitty.cli import parse_args
|
from kitty.cli import parse_args
|
||||||
from kitty.cli_stub import PanelCLIOptions
|
from kitty.cli_stub import PanelCLIOptions
|
||||||
|
|||||||
@@ -5,12 +5,11 @@ import os
|
|||||||
import sys
|
import sys
|
||||||
import termios
|
import termios
|
||||||
from collections import defaultdict
|
from collections import defaultdict
|
||||||
from collections.abc import Generator, Sequence
|
from collections.abc import Generator, Iterable, Mapping, Sequence
|
||||||
from contextlib import contextmanager, suppress
|
from contextlib import contextmanager, suppress
|
||||||
from itertools import count
|
from itertools import count
|
||||||
from time import monotonic
|
from time import monotonic
|
||||||
from typing import TYPE_CHECKING, DefaultDict, Optional, TypedDict
|
from typing import TYPE_CHECKING, DefaultDict, Optional, TypedDict
|
||||||
from collections.abc import Iterable, Mapping
|
|
||||||
|
|
||||||
import kitty.fast_data_types as fast_data_types
|
import kitty.fast_data_types as fast_data_types
|
||||||
|
|
||||||
|
|||||||
@@ -5,12 +5,11 @@ import builtins
|
|||||||
import re
|
import re
|
||||||
import textwrap
|
import textwrap
|
||||||
import typing
|
import typing
|
||||||
from collections.abc import Callable, Iterable, Iterator
|
from collections.abc import Callable, Iterable, Iterator, Sequence
|
||||||
from functools import lru_cache
|
from functools import lru_cache
|
||||||
from importlib import import_module
|
from importlib import import_module
|
||||||
from re import Match
|
from re import Match
|
||||||
from typing import Any, Optional, Union, cast
|
from typing import Any, Optional, Union, cast
|
||||||
from collections.abc import Sequence
|
|
||||||
|
|
||||||
import kitty.conf.utils as generic_parsers
|
import kitty.conf.utils as generic_parsers
|
||||||
from kitty.constants import website_url
|
from kitty.constants import website_url
|
||||||
|
|||||||
@@ -4,10 +4,9 @@
|
|||||||
|
|
||||||
import os
|
import os
|
||||||
import shutil
|
import shutil
|
||||||
from collections.abc import Container, Iterable, Iterator, Sequence
|
from collections.abc import Callable, Container, Iterable, Iterator, Sequence
|
||||||
from contextlib import suppress
|
from contextlib import suppress
|
||||||
from typing import Any, Literal, NamedTuple, TypedDict
|
from typing import Any, Literal, NamedTuple, TypedDict
|
||||||
from collections.abc import Callable
|
|
||||||
|
|
||||||
from .boss import Boss
|
from .boss import Boss
|
||||||
from .child import Child
|
from .child import Child
|
||||||
|
|||||||
@@ -1,12 +1,11 @@
|
|||||||
#!/usr/bin/env python
|
#!/usr/bin/env python
|
||||||
# License: GPLv3 Copyright: 2020, Kovid Goyal <kovid at kovidgoyal.net>
|
# License: GPLv3 Copyright: 2020, Kovid Goyal <kovid at kovidgoyal.net>
|
||||||
|
|
||||||
from collections.abc import Generator, Iterable, Iterator, Sequence
|
from collections.abc import Callable, Generator, Iterable, Iterator, Sequence
|
||||||
from enum import Enum
|
from enum import Enum
|
||||||
from functools import partial
|
from functools import partial
|
||||||
from itertools import repeat
|
from itertools import repeat
|
||||||
from typing import Any, ClassVar, NamedTuple
|
from typing import Any, ClassVar, NamedTuple
|
||||||
from collections.abc import Callable
|
|
||||||
|
|
||||||
from kitty.borders import BorderColor
|
from kitty.borders import BorderColor
|
||||||
from kitty.fast_data_types import BOTTOM_EDGE, RIGHT_EDGE, Region, get_options, set_active_window, viewport_for_window
|
from kitty.fast_data_types import BOTTOM_EDGE, RIGHT_EDGE, Region, get_options, set_active_window, viewport_for_window
|
||||||
|
|||||||
@@ -6,12 +6,11 @@ import os
|
|||||||
import re
|
import re
|
||||||
import shlex
|
import shlex
|
||||||
import sys
|
import sys
|
||||||
from collections.abc import Callable, Generator, Iterator, Mapping
|
from collections.abc import Callable, Generator, Iterator, Mapping, Sequence
|
||||||
from contextlib import suppress
|
from contextlib import suppress
|
||||||
from functools import partial
|
from functools import partial
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
from typing import TYPE_CHECKING, Any, Optional, Union
|
from typing import TYPE_CHECKING, Any, Optional, Union
|
||||||
from collections.abc import Sequence
|
|
||||||
|
|
||||||
from .cli_stub import CLIOptions, GotoSessionOptions, SaveAsSessionOptions
|
from .cli_stub import CLIOptions, GotoSessionOptions, SaveAsSessionOptions
|
||||||
from .constants import config_dir, unserialize_launch_flag
|
from .constants import config_dir, unserialize_launch_flag
|
||||||
|
|||||||
@@ -5,9 +5,8 @@
|
|||||||
import os
|
import os
|
||||||
import re
|
import re
|
||||||
import subprocess
|
import subprocess
|
||||||
from collections.abc import Callable
|
from collections.abc import Callable, Iterable
|
||||||
from contextlib import suppress
|
from contextlib import suppress
|
||||||
from collections.abc import Iterable
|
|
||||||
|
|
||||||
from .constants import shell_integration_dir
|
from .constants import shell_integration_dir
|
||||||
from .fast_data_types import get_options
|
from .fast_data_types import get_options
|
||||||
|
|||||||
@@ -6,10 +6,10 @@
|
|||||||
|
|
||||||
import re
|
import re
|
||||||
import sys
|
import sys
|
||||||
|
from collections.abc import Iterator, Sequence
|
||||||
from enum import Enum, auto
|
from enum import Enum, auto
|
||||||
from functools import lru_cache
|
from functools import lru_cache
|
||||||
from typing import Any, NamedTuple
|
from typing import Any, NamedTuple
|
||||||
from collections.abc import Iterator, Sequence
|
|
||||||
|
|
||||||
if getattr(sys, 'running_from_setup', False):
|
if getattr(sys, 'running_from_setup', False):
|
||||||
is_macos = 'darwin' in sys.platform.lower()
|
is_macos = 'darwin' in sys.platform.lower()
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ import re
|
|||||||
import sys
|
import sys
|
||||||
import weakref
|
import weakref
|
||||||
from collections import deque
|
from collections import deque
|
||||||
from collections.abc import Callable, Generator, Iterable, Sequence
|
from collections.abc import Callable, Generator, Iterable, Iterator, Sequence
|
||||||
from contextlib import contextmanager, suppress
|
from contextlib import contextmanager, suppress
|
||||||
from enum import Enum, IntEnum, auto
|
from enum import Enum, IntEnum, auto
|
||||||
from functools import lru_cache, partial
|
from functools import lru_cache, partial
|
||||||
@@ -24,7 +24,6 @@ from typing import (
|
|||||||
Optional,
|
Optional,
|
||||||
Union,
|
Union,
|
||||||
)
|
)
|
||||||
from collections.abc import Iterator
|
|
||||||
|
|
||||||
from .child import ProcessDesc
|
from .child import ProcessDesc
|
||||||
from .cli_stub import CLIOptions, SaveAsSessionOptions
|
from .cli_stub import CLIOptions, SaveAsSessionOptions
|
||||||
|
|||||||
@@ -3,11 +3,10 @@
|
|||||||
|
|
||||||
import weakref
|
import weakref
|
||||||
from collections import deque
|
from collections import deque
|
||||||
from collections.abc import Iterator
|
from collections.abc import Iterator, Sequence
|
||||||
from contextlib import suppress
|
from contextlib import suppress
|
||||||
from itertools import count
|
from itertools import count
|
||||||
from typing import Any, Deque, Union
|
from typing import Any, Deque, Union
|
||||||
from collections.abc import Sequence
|
|
||||||
|
|
||||||
from .fast_data_types import Color, get_options
|
from .fast_data_types import Color, get_options
|
||||||
from .types import OverlayType, WindowGeometry
|
from .types import OverlayType, WindowGeometry
|
||||||
|
|||||||
Reference in New Issue
Block a user