mirror of
https://github.com/kovidgoyal/kitty
synced 2026-06-12 19:49:32 +02:00
Cleanup previous PR
This commit is contained in:
@@ -3,8 +3,7 @@
|
||||
# License: GPLv3 Copyright: 2021, Kovid Goyal <kovid at kovidgoyal.net>
|
||||
|
||||
|
||||
import shlex
|
||||
from typing import Any, Dict, Iterable, List, Tuple, Union
|
||||
from typing import Any, Container, Dict, Iterable, Tuple, Union
|
||||
|
||||
from kitty.conf.utils import (
|
||||
KeyFuncWrapper, KittensKeyDefinition, parse_kittens_key
|
||||
@@ -59,8 +58,10 @@ def syntax_aliases(raw: str) -> Dict[str, str]:
|
||||
return ans
|
||||
|
||||
|
||||
def pattern_list(raw: str) -> Tuple[str, ...]:
|
||||
return tuple(shlex.split(raw, comments=True))
|
||||
def store_multiple(val: str, current_val: Container[str]) -> Iterable[Tuple[str, str]]:
|
||||
val = val.strip()
|
||||
if val not in current_val:
|
||||
yield val, val
|
||||
|
||||
|
||||
def parse_map(val: str) -> Iterable[KittensKeyDefinition]:
|
||||
|
||||
Reference in New Issue
Block a user