Typecheck @ls cli opts
This commit is contained in:
parent
19524a4459
commit
1e29fad5f0
@ -3,7 +3,7 @@
|
|||||||
# License: GPLv3 Copyright: 2020, Kovid Goyal <kovid at kovidgoyal.net>
|
# License: GPLv3 Copyright: 2020, Kovid Goyal <kovid at kovidgoyal.net>
|
||||||
|
|
||||||
import json
|
import json
|
||||||
from typing import Any, Dict, List, Optional, Set, Tuple
|
from typing import TYPE_CHECKING, Dict, List, Optional, Set, Tuple
|
||||||
|
|
||||||
from kitty.constants import appname
|
from kitty.constants import appname
|
||||||
|
|
||||||
@ -12,6 +12,9 @@ from .base import (
|
|||||||
ResponseType, Window
|
ResponseType, Window
|
||||||
)
|
)
|
||||||
|
|
||||||
|
if TYPE_CHECKING:
|
||||||
|
from kitty.cli_stub import LSRCOptions as CLIOptions
|
||||||
|
|
||||||
|
|
||||||
class LS(RemoteCommand):
|
class LS(RemoteCommand):
|
||||||
'''
|
'''
|
||||||
@ -36,7 +39,7 @@ Show all environment variables in output not just differing ones.
|
|||||||
|
|
||||||
argspec = ''
|
argspec = ''
|
||||||
|
|
||||||
def message_to_kitty(self, global_opts: RCOptions, opts: Any, args: ArgsType) -> PayloadType:
|
def message_to_kitty(self, global_opts: RCOptions, opts: CLIOptions, args: ArgsType) -> PayloadType:
|
||||||
return {'all_env_vars': opts.all_env_vars}
|
return {'all_env_vars': opts.all_env_vars}
|
||||||
|
|
||||||
def response_from_kitty(self, boss: Boss, window: Optional[Window], payload_get: PayloadGetType) -> ResponseType:
|
def response_from_kitty(self, boss: Boss, window: Optional[Window], payload_get: PayloadGetType) -> ResponseType:
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user