Skip to content

fuzzy ¤

Classes:

Functions:

Attributes:

P module-attribute ¤

P = ParamSpec('P')

T module-attribute ¤

T = TypeVar('T')

PROMPT module-attribute ¤

PROMPT = ANSI('\x1b[34mpwndbg-lldb> ')

HISTORY_FILE module-attribute ¤

HISTORY_FILE = expanduser('~/.pwndbg_history')

FZF_RUN_CMD module-attribute ¤

FZF_RUN_CMD = (
    "fzf",
    "--select-1",
    "--exit-0",
    "--tiebreak=index",
    "--no-multi",
    "--height=40%",
    "--layout=reverse",
)

FZF_PRVIEW_WINDOW_ARGS module-attribute ¤

FZF_PRVIEW_WINDOW_ARGS = ('--preview-window', 'right:55%:wrap')

FzfTabCompletePreviewThread ¤

FzfTabCompletePreviewThread(
    fifo_input_path: str,
    fifo_output_path: str,
    completion_help_docs: dict[int, str],
    **kwargs,
)

Bases: Thread

A thread for previewing help docs of selected completion with fzf.

This is modified from: https://github.com/infokiller/config-public/blob/master/.config/ipython/profile_default/startup/ext/fzf_history.py#L72

Methods:

Attributes:

fifo_input_path instance-attribute ¤

fifo_input_path = fifo_input_path

fifo_output_path instance-attribute ¤

fifo_output_path = fifo_output_path

completion_help_docs instance-attribute ¤

completion_help_docs = completion_help_docs

is_done instance-attribute ¤

is_done = Event()

run ¤

run() -> None

stop ¤

stop() -> None

LLDBHistory ¤

LLDBHistory(filename: str, ignore_duplicates: bool = False)

Bases: FileHistory

Manage your LLDB History

Methods:

Attributes:

ignore_duplicates instance-attribute ¤

ignore_duplicates = ignore_duplicates

load_history_strings ¤

load_history_strings() -> list[str]

store_string ¤

store_string(string: str) -> None

LLDBCompleter ¤

LLDBCompleter(dbg)

Bases: Completer

Completer of LLDB

Methods:

Attributes:

dbg instance-attribute ¤

dbg = dbg

get_completions ¤

get_completions(
    document: Document, complete_event: CompleteEvent
) -> Iterator[Completion]

get_lldb_completes ¤

get_lldb_completes(dbg: LLDB, query: str = '') -> list[str]

safe_get_help_docs ¤

safe_get_help_docs(dbg: LLDB, command: str) -> str | None

should_get_help_docs ¤

should_get_help_docs(dbg: LLDB, completion: str) -> bool

Check if we need to get help docs for another completion that generated by same command.

get_lldb_completion_and_status ¤

get_lldb_completion_and_status(dbg: LLDB, query: str) -> tuple[list[str], bool]

Return all possible completions and whether we need to get help docs for all completions.

create_fzf_process ¤

create_fzf_process(
    query: str, preview: str = "", pre_cmd: str = ""
) -> Popen[str]

Create a fzf process with given query and preview command.

create_preview_fifos ¤

create_preview_fifos() -> tuple[str, str]

Create a temporary directory and two FIFOs in it, return the paths of these FIFOs.

This is modified from: https://github.com/infokiller/config-public/blob/652b4638a0a0ffed9743fa9e0ad2a8d4e4e90572/.config/ipython/profile_default/startup/ext/fzf_history.py#L128

fzf_reverse_search(event: KeyPressEvent) -> None

Reverse search history with fzf.

fzf_tab_autocomplete ¤

fzf_tab_autocomplete(
    event: KeyPressEvent, dbg: LLDB, preview: str, fifo_in: str, fifo_out: str
) -> None

Tab autocomplete with fzf.

wrap_with_history ¤

wrap_with_history(function: Callable[P, T]) -> Callable[P, T]

get_prompt_session ¤

get_prompt_session(dbg)