Enum xplr::msg::in_::external::ExternalMsg

source ·
pub enum ExternalMsg {
Show 128 variants ExplorePwd, ExplorePwdAsync, ExploreParentsAsync, ClearScreen, Refresh, FocusNext, FocusNextSelection, FocusNextByRelativeIndex(usize), FocusNextByRelativeIndexFromInput, FocusPrevious, FocusPreviousSelection, FocusPreviousByRelativeIndex(usize), FocusPreviousByRelativeIndexFromInput, FocusFirst, FocusLast, FocusPath(String), FocusPathFromInput, FocusByIndex(usize), FocusByIndexFromInput, FocusByFileName(String), ScrollUp, ScrollDown, ScrollUpHalf, ScrollDownHalf, ChangeDirectory(String), Enter, Back, LastVisitedPath, NextVisitedPath, PreviousVisitedDeepBranch, NextVisitedDeepBranch, FollowSymlink, SetVroot(String), UnsetVroot, ToggleVroot, ResetVroot, SetInputPrompt(String), UpdateInputBuffer(InputOperation), UpdateInputBufferFromKey, BufferInput(String), BufferInputFromKey, SetInputBuffer(String), RemoveInputBufferLastCharacter, RemoveInputBufferLastWord, ResetInputBuffer, SwitchMode(String), SwitchModeKeepingInputBuffer(String), SwitchModeBuiltin(String), SwitchModeBuiltinKeepingInputBuffer(String), SwitchModeCustom(String), SwitchModeCustomKeepingInputBuffer(String), PopMode, PopModeKeepingInputBuffer, SwitchLayout(String), SwitchLayoutBuiltin(String), SwitchLayoutCustom(String), Call(Command), Call0(Command), CallSilently(Command), CallSilently0(Command), BashExec(String), BashExec0(String), BashExecSilently(String), BashExecSilently0(String), CallLua(String), CallLuaSilently(String), LuaEval(String), LuaEvalSilently(String), Select, SelectAll, SelectPath(String), UnSelect, UnSelectAll, UnSelectPath(String), ToggleSelection, ToggleSelectAll, ToggleSelectionByPath(String), ClearSelection, AddNodeFilter(NodeFilterApplicable), RemoveNodeFilter(NodeFilterApplicable), ToggleNodeFilter(NodeFilterApplicable), AddNodeFilterFromInput(NodeFilter), RemoveNodeFilterFromInput(NodeFilter), RemoveLastNodeFilter, ResetNodeFilters, ClearNodeFilters, AddNodeSorter(NodeSorterApplicable), RemoveNodeSorter(NodeSorter), ReverseNodeSorter(NodeSorter), ToggleNodeSorter(NodeSorterApplicable), ReverseNodeSorters, RemoveLastNodeSorter, ResetNodeSorters, ClearNodeSorters, Search(String), SearchFromInput, SearchFuzzy(String), SearchFuzzyFromInput, SearchFuzzyUnordered(String), SearchFuzzyUnorderedFromInput, SearchRegex(String), SearchRegexFromInput, SearchRegexUnordered(String), SearchRegexUnorderedFromInput, ToggleSearchAlgorithm, EnableSearchOrder, DisableSearchOrder, ToggleSearchOrder, AcceptSearch, CancelSearch, EnableMouse, DisableMouse, ToggleMouse, StartFifo(String), StopFifo, ToggleFifo(String), LogInfo(String), LogSuccess(String), LogWarning(String), LogError(String), Debug(String), Quit, PrintPwdAndQuit, PrintFocusPathAndQuit, PrintSelectionAndQuit, PrintResultAndQuit, PrintAppStateAndQuit, Terminate,
}

Variants§

§

ExplorePwd

§Exploring –––––––––––––––––––––––––––––

Explore the present working directory and register the filtered nodes. This operation is expensive. So, try to avoid using it too often.

Example:

  • Lua: "ExplorePwd"
  • YAML: ExplorePwd
§

ExplorePwdAsync

Explore the present working directory and register the filtered nodes asynchronously. This operation happens asynchronously. That means, the xplr directory buffers won’t be updated immediately. Hence, it needs to be used with care and probably with special checks in place. To explore $PWD synchronously, use ExplorePwd instead.

Example:

  • Lua: "ExplorePwdAsync"
  • YAML: ExplorePwdAsync
§

ExploreParentsAsync

Explore the present working directory along with its parents and register the filtered nodes. This operation happens asynchronously. That means, the xplr directory buffers won’t be updated immediately. Hence, it needs to be used with care and probably with special checks in place. To explore just the $PWD synchronously, use ExplorePwd instead.

Example:

  • Lua: "ExploreParentsAsync"
  • YAML: ExploreParentsAsync
§

ClearScreen

§Screen ———————————————————––

Clear the screen.

Example:

  • Lua: "ClearScreen"
  • YAML: ClearScreen
§

Refresh

Refresh the screen. But it will not re-explore the directory if the working directory is the same. If there is some change in the working directory and you want to re-explore it, use the Explore message instead. Also, it will not clear the screen. Use ClearScreen for that.

Example:

  • Lua: "Refresh"
  • YAML: Refresh
§

FocusNext

Focus next node.

Example:

  • Lua: "FocusNext"
  • YAML: FocusNext
§

FocusNextSelection

Focus on the next selected node.

Example:

  • Lua: "FocusNextSelection"
  • YAML: FocusNextSelection
§

FocusNextByRelativeIndex(usize)

Focus on the nth node relative to the current focus where n is a given value.

Type: { FocusNextByRelativeIndex = int }

Example:

  • Lua: { FocusNextByRelativeIndex = 2 }
  • YAML: FocusNextByRelativeIndex: 2
§

FocusNextByRelativeIndexFromInput

Focus on the nth node relative to the current focus where n is read from the input buffer.

Example:

  • Lua: "FocusNextByRelativeIndexFromInput"
  • YAML: FocusNextByRelativeIndexFromInput
§

FocusPrevious

Focus on the previous item.

Example:

  • Lua: "FocusPrevious"
  • YAML: FocusPrevious
§

FocusPreviousSelection

Focus on the previous selection item.

Example:

  • Lua: "FocusPreviousSelection"
  • YAML: FocusPreviousSelection
§

FocusPreviousByRelativeIndex(usize)

Focus on the -nth node relative to the current focus where n is a given value.

Type: { FocusPreviousByRelativeIndex = int }

Example:

  • Lua: { FocusPreviousByRelativeIndex = 2 }
  • YAML: FocusPreviousByRelativeIndex: 2
§

FocusPreviousByRelativeIndexFromInput

Focus on the -nth node relative to the current focus where n is read from the input buffer.

Example:

  • Lua: "FocusPreviousByRelativeIndexFromInput"
  • YAML: FocusPreviousByRelativeIndexFromInput
§

FocusFirst

Focus on the first node.

Example:

  • Lua: "FocusFirst"
  • YAML: FocusFirst
§

FocusLast

Focus on the last node.

Example:

  • Lua: "FocusLast"
  • YAML: FocusLast
§

FocusPath(String)

Focus on the given path.

Type: { FocusPath = “string” }

Example:

  • Lua: { FocusPath = "/path/to/file" }
  • YAML: FocusPath: /path/to/file
§

FocusPathFromInput

Focus on the path read from input buffer.

Example:

  • Lua: "FocusPathFromInput"
  • YAML: FocusPathFromInput
§

FocusByIndex(usize)

Focus on the absolute nth node where n is a given value.

Type: { FocusByIndex = int }

Example:

  • Lua: { FocusByIndex = 2 }
  • YAML: FocusByIndex: 2
§

FocusByIndexFromInput

Focus on the absolute nth node where n is read from the input buffer.

Example:

  • Lua: "FocusByIndexFromInput"
  • YAML: FocusByIndexFromInput
§

FocusByFileName(String)

Focus on the file by name from the present working directory.

Type: { FocusByFileName = “string” }

Example:

  • Lua: { FocusByFileName = "filename.ext" }
  • YAML: FocusByFileName: filename.ext
§

ScrollUp

Scroll up by terminal height.

Example:

  • Lua: "ScrollUp"
  • YAML: ScrollUp
§

ScrollDown

Scroll down by terminal height.

Example:

  • Lua: "ScrollDown"
  • YAML: ScrollDown
§

ScrollUpHalf

Scroll up by half of terminal height.

Example:

  • Lua: "ScrollUpHalf"
  • YAML: ScrollUpHalf
§

ScrollDownHalf

Scroll down by half of terminal height.

Example:

  • Lua: "ScrollDownHalf"
  • YAML: ScrollDownHalf
§

ChangeDirectory(String)

Change the present working directory ($PWD)

Type: { ChangeDirectory = “string” }

Example:

  • Lua: { ChangeDirectory = "/path/to/directory" }
  • YAML: ChangeDirectory: /path/to/directory
§

Enter

Enter into the currently focused path if it’s a directory.

Example:

  • Lua: "Enter"
  • YAML: Enter
§

Back

Go back to the parent directory.

Example:

  • Lua: "Back"
  • YAML: Back
§

LastVisitedPath

Go to the last path visited.

Example:

  • Lua: "LastVisitedPath"
  • YAML: LastVisitedPath
§

NextVisitedPath

Go to the next path visited.

Example:

  • Lua: "NextVisitedPath"
  • YAML: NextVisitedPath
§

PreviousVisitedDeepBranch

Go to the previous deep level branch.

Example:

  • Lua: "PreviousVisitedDeepBranch"
  • YAML: PreviousVisitedDeepBranch
§

NextVisitedDeepBranch

Go to the next deep level branch.

Example:

  • Lua: "NextVisitedDeepBranch"
  • YAML: NextVisitedDeepBranch

Follow the symlink under focus to its actual location.

Example:

  • Lua: "FollowSymlink"
  • YAML: FollowSymlink
§

SetVroot(String)

§Virtual Root ——————————————————

Sets the virtual root for isolating xplr navigation, similar to --vroot, but temporary (can be reset back to initial value). If the $PWD is outside the vroot, xplr will automatically enter vroot.

Type: { SetVroot = “string” }

Example:

  • Lua: { SetVroot = "/tmp" }
  • YAML: SetVroot: /tmp
§

UnsetVroot

Unset the virtual root temporarily (can be reset back to the initial value).

Example:

  • Lua: "UnsetVroot"
  • YAML: UnsetVroot
§

ToggleVroot

Toggle virtual root between unset, initial value and $PWD.

Example:

  • Lua: "ToggleVroot"
  • YAML: ToggleVroot
§

ResetVroot

Reset the virtual root back to the initial value.

Example:

  • Lua: "ResetVroot"
  • YAML: ResetVroot
§

SetInputPrompt(String)

§Reading Input —————————————————–

Set the input prompt temporarily, until the input buffer is reset.

Type: { SetInputPrompt = string }

Example:

  • Lua: { SetInputPrompt = "→" }
  • YAML: SetInputPrompt: →
§

UpdateInputBuffer(InputOperation)

Update the input buffer using cursor based operations.

Type: { UpdateInputBuffer = Input Operation }

Example:

  • Lua: { UpdateInputBuffer = "GoToPreviousWord" }
  • YAML: UpdateInputBuffer: GoToPreviousWord
§

UpdateInputBufferFromKey

Update the input buffer from the key read from keyboard input.

Example:

  • Lua: "UpdateInputBufferFromKey"
  • YAML: UpdateInputBufferFromKey
§

BufferInput(String)

Append/buffer the given string into the input buffer.

Type: { BufferInput = “string” }

Example:

  • Lua: { BufferInput = "foo" }
  • YAML: BufferInput: foo
§

BufferInputFromKey

Append/buffer the character read from a keyboard input into the input buffer.

Example:

  • Lua: "BufferInputFromKey"
  • YAML: BufferInputFromKey
§

SetInputBuffer(String)

Set/rewrite the input buffer with the given string. When the input buffer is not-null (even if empty string) it will show in the UI.

Type: { SetInputBuffer = “string” }

Example:

  • Lua: { SetInputBuffer = "foo" }
  • YAML: SetInputBuffer: foo
§

RemoveInputBufferLastCharacter

Remove input buffer’s last character.

Example:

  • Lua: "RemoveInputBufferLastCharacter"
  • YAML: RemoveInputBufferLastCharacter
§

RemoveInputBufferLastWord

Remove input buffer’s last word.

Example:

  • Lua: "RemoveInputBufferLastWord"
  • YAML: RemoveInputBufferLastWord
§

ResetInputBuffer

Reset the input buffer back to null. It will not show in the UI.

Example:

  • Lua: "ResetInputBuffer"
  • YAML: ResetInputBuffer
§

SwitchMode(String)

§Switching Mode —————————————————–

Switch input mode.

Type : { SwitchMode = “string” }

Example:

  • Lua: { SwitchMode = "default" }
  • YAML: SwitchMode: default

NOTE: To be specific about which mode to switch to, use SwitchModeBuiltin or SwitchModeCustom instead.

§

SwitchModeKeepingInputBuffer(String)

Switch input mode. It keeps the input buffer.

Type: { SwitchModeKeepingInputBuffer = “string” }

Example:

  • Lua: { SwitchModeKeepingInputBuffer = "default" }
  • YAML: SwitchModeKeepingInputBuffer: default

NOTE: To be specific about which mode to switch to, use SwitchModeBuiltinKeepingInputBuffer or SwitchModeCustomKeepingInputBuffer instead.

§

SwitchModeBuiltin(String)

Switch to a builtin mode. It clears the input buffer.

Type: { SwitchModeBuiltin = “string” }

Example:

  • Lua: { SwitchModeBuiltin = "default" }
  • YAML: SwitchModeBuiltin: default
§

SwitchModeBuiltinKeepingInputBuffer(String)

Switch to a builtin mode. It keeps the input buffer.

Type: { SwitchModeBuiltinKeepingInputBuffer = “string” }

Example:

  • Lua: { SwitchModeBuiltinKeepingInputBuffer = "default" }
  • YAML: SwitchModeBuiltinKeepingInputBuffer: default
§

SwitchModeCustom(String)

Switch to a custom mode. It clears the input buffer.

Type: { SwitchModeCustom = “string” }

Example:

  • Lua: { SwitchModeCustom = "my_custom_mode" }
  • YAML: SwitchModeCustom: my_custom_mode
§

SwitchModeCustomKeepingInputBuffer(String)

Switch to a custom mode. It keeps the input buffer.

Type: { SwitchModeCustomKeepingInputBuffer = “string” }

Example:

  • Lua: { SwitchModeCustomKeepingInputBuffer = "my_custom_mode" }
  • YAML: SwitchModeCustomKeepingInputBuffer: my_custom_mode
§

PopMode

Pop the last mode from the history and switch to it. It clears the input buffer.

Example:

  • Lua: "PopMode"
  • YAML: PopMode
§

PopModeKeepingInputBuffer

Pop the last mode from the history and switch to it. It keeps the input buffer.

Example:

  • Lua: PopModeKeepingInputBuffer
  • YAML: PopModeKeepingInputBuffer
§

SwitchLayout(String)

§Switching Layout —————————————————

Switch layout.

Type: { SwitchLayout = “string” }

Example:

  • Lua: { SwitchLayout = "default" }
  • YAML: SwitchLayout: default

NOTE: To be specific about which layout to switch to, use SwitchLayoutBuiltin or SwitchLayoutCustom instead.

§

SwitchLayoutBuiltin(String)

Switch to a builtin layout.

Type: { SwitchLayoutBuiltin = “string” }

Example:

  • Lua: { SwitchLayoutBuiltin = "default" }
  • YAML: SwitchLayoutBuiltin: default
§

SwitchLayoutCustom(String)

Switch to a custom layout.

Type: { SwitchLayoutCustom = “string” }

Example:

  • Lua: { SwitchLayoutCustom = "my_custom_layout" }
  • YAML: SwitchLayoutCustom: my_custom_layout
§

Call(Command)

§Executing Commands ————————————————

Like Call0, but it uses \n as the delimiter in input/output pipes, hence it cannot handle files with \n in the name. You may want to use Call0 instead.

§

Call0(Command)

Call a shell command with the given arguments. Note that the arguments will be shell-escaped. So to read the variables, the -c option of the shell can be used. You may need to pass ExplorePwd depending on the expectation.

Type: { Call0 = { command = “string”, args = { “list”, “of”, “string” } }

Example:

  • Lua: { Call0 = { command = "bash", args = { "-c", "read -p test" } } }
  • YAML: Call0: { command: bash, args: ["-c", "read -p test"] }
§

CallSilently(Command)

Like CallSilently0, but it uses \n as the delimiter in input/output pipes, hence it cannot handle files with \n in the name. You may want to use CallSilently0 instead.

§

CallSilently0(Command)

Like Call0 but without the flicker. The stdin, stdout stderr will be piped to null. So it’s non-interactive.

Type: { CallSilently0 = { command = “string”, args = {“list”, “of”, “string”} } }

Example:

  • Lua: { CallSilently0 = { command = "tput", args = { "bell" } } }
  • YAML: CallSilently0: { command: tput, args: ["bell"] }
§

BashExec(String)

Like BashExec0, but it uses \n as the delimiter in input/output pipes, hence it cannot handle files with \n in the name. You may want to use BashExec0 instead.

§

BashExec0(String)

An alias to Call: {command: bash, args: ["-c", "{string}"], silent: false} where {string} is the given value.

Type: { BashExec0 = “string” }

Example:

  • Lua: { BashExec0 = "read -p test" }
  • YAML: BashExec0: "read -p test"
§

BashExecSilently(String)

Like BashExecSilently0, but it uses \n as the delimiter in input/output pipes, hence it cannot handle files with \n in the name. You may want to use BashExecSilently0 instead.

§

BashExecSilently0(String)

Like BashExec0 but without the flicker. The stdin, stdout stderr will be piped to null. So it’s non-interactive.

Type: { BashExecSilently0 = “string” }

Example:

  • Lua: { BashExecSilently0 = "tput bell" }
  • YAML: BashExecSilently0: "tput bell"
§

CallLua(String)

§Calling Lua Functions –––––––––––––––––––––––

Call a Lua function.

A Lua Context object will be passed to the function as argument. The function can optionally return a list of messages for xplr to handle after the executing the function.

Type: { CallLua = “string” }

Example:

  • Lua: { CallLua = "custom.some_custom_funtion" }
  • YAML: CallLua: custom.some_custom_funtion
§

CallLuaSilently(String)

Like CallLua but without the flicker. The stdin, stdout stderr will be piped to null. So it’s non-interactive.

Type: { CallLuaSilently = “string” }

Example:

  • Lua: { CallLuaSilently = "custom.some_custom_function" }
  • YAML: CallLuaSilently: custom.some_custom_function
§

LuaEval(String)

Execute Lua code without needing to define a function.

If the string is a callable, xplr will try to call it with with the Lua Context argument.

Type: { LuaEval = “string” }

Example:

  • Lua: { LuaEval = [[return { { LogInfo = io.read() } }]] }
  • Lua: { LuaEval = [[function(app) return { { LogInfo = app.pwd } } end]] }
  • YAML: LuaEval: "return { { LogInfo = io.read() } }"
  • YAML: LuaEval: "function(app) return { { LogInfo = app.pwd } } end"
§

LuaEvalSilently(String)

Like LuaEval but without the flicker. The stdin, stdout stderr will be piped to null. So it’s non-interactive.

Type: { LuaEvalSilently = “string” }

Example:

  • Lua: { LuaEvalSilently = [[return { { LogInfo = "foo" } }]] }
  • YAML: LuaEvalSilently: "return { { LogInfo = 'foo' } }"
§

Select

§Select Operations –––––––––––––––––––––––––

Select the focused node.

Example:

  • Lua: "Select"
  • YAML: Select
§

SelectAll

Select all the visible nodes.

Example:

  • Lua: "SelectAll"
  • YAML: SelectAll
§

SelectPath(String)

Select the given path.

Type: { SelectPath = “string” }

Example:

  • Lua: { SelectPath = "/path/to/file" }
  • YAML: SelectPath: /path/to/file
§

UnSelect

Unselect the focused node.

Example:

  • Lua: "UnSelect"
  • YAML: UnSelect
§

UnSelectAll

Unselect all the visible nodes.

Example:

  • Lua: "UnSelectAll"
  • YAML: UnSelectAll
§

UnSelectPath(String)

UnSelect the given path.

Type: { UnSelectPath = “string)” }

Example:

  • Lua: { UnSelectPath = "/path/to/file" }
  • YAML: UnSelectPath: /path/to/file
§

ToggleSelection

Toggle selection on the focused node.

Example:

  • Lua: "ToggleSelection"
  • YAML ToggleSelection
§

ToggleSelectAll

Toggle between select all and unselect all. Example:

  • Lua: "ToggleSelectAll"
  • YAML: ToggleSelectAll
§

ToggleSelectionByPath(String)

Toggle selection by file path.

Type: { ToggleSelectionByPath = “string” }

Example:

  • Lua: { ToggleSelectionByPath = "/path/to/file" }
  • YAML: ToggleSelectionByPath: /path/to/file
§

ClearSelection

Clear the selection.

Example:

  • Lua: "ClearSelection"
  • YAML: ClearSelection
§

AddNodeFilter(NodeFilterApplicable)

§Filter Operations –––––––––––––––––––––––––

Add a filter to exclude nodes while exploring directories. You need to call ExplorePwd or ExplorePwdAsync explicitly. Filters get automatically cleared when changing directories.

Type: { AddNodeFilter = { filter = Filter, input = “string” }

Example:

  • Lua: { AddNodeFilter = { filter = "RelativePathDoesStartWith", input = "foo" } }
  • YAML: AddNodeFilter: { filter: RelativePathDoesStartWith, input: foo }
§

RemoveNodeFilter(NodeFilterApplicable)

Remove an existing filter. You need to call ExplorePwd or ExplorePwdAsync explicitly.

Type: { RemoveNodeFilter = { filter = Filter, input = “string” }

Example:

  • Lua: { RemoveNodeFilter: { filter: "RelativePathDoesStartWith", input: "foo" } }
  • YAML: RemoveNodeFilter: { filter: RelativePathDoesStartWith, input: foo }
§

ToggleNodeFilter(NodeFilterApplicable)

Remove a filter if it exists, else, add a it. You need to call ExplorePwd or ExplorePwdAsync explicitly.

Type: { ToggleNodeFilter = { filter = Filter, input = “string” }

Example:

  • Lua: { ToggleNodeFilter = { filter = "RelativePathDoesStartWith", input = "foo" } }
  • YAML: ToggleNodeFilter: { filter: RelativePathDoesStartWith, input: foo }
§

AddNodeFilterFromInput(NodeFilter)

Add a node filter reading the input from the buffer. You need to call ExplorePwd or ExplorePwdAsync explicitly.

Type: { AddNodeFilterFromInput = Filter }

Example:

  • Lua: { AddNodeFilterFromInput = "RelativePathDoesStartWith" }
  • YAML: AddNodeFilterFromInput: RelativePathDoesStartWith
§

RemoveNodeFilterFromInput(NodeFilter)

Remove a node filter reading the input from the buffer. You need to call ExplorePwd or ExplorePwdAsync explicitly.

Type: { RemoveNodeFilterFromInput = Filter }

Example:

  • Lua: { RemoveNodeFilterFromInput = "RelativePathDoesStartWith" }
  • YAML: RemoveNodeFilterFromInput: RelativePathDoesStartWith
§

RemoveLastNodeFilter

Remove the last node filter. You need to call ExplorePwd or ExplorePwdAsync explicitly.

Example:

  • Lua: "RemoveLastNodeFilter"
  • YAML: RemoveLastNodeFilter
§

ResetNodeFilters

Reset the node filters back to the default configuration. You need to call ExplorePwd or ExplorePwdAsync explicitly.

Example:

  • Lua: "ResetNodeFilters"
  • YAML: ResetNodeFilters
§

ClearNodeFilters

Clear all the node filters. You need to call ExplorePwd or ExplorePwdAsync explicitly.

Example:

  • Lua: "ClearNodeFilters"
  • YAML: ClearNodeFilters
§

AddNodeSorter(NodeSorterApplicable)

§Sort Operations ––––––––––––––––––––––––––

Add a sorter to sort nodes while exploring directories. You need to call ExplorePwd or ExplorePwdAsync explicitly.

Type: { AddNodeSorter = { sorter = Sorter, reverse = bool } }

Example:

  • Lua: { AddNodeSorter = { sorter = "ByRelativePath", reverse = false } }
  • YAML: AddNodeSorter: { sorter: ByRelativePath, reverse: false }
§

RemoveNodeSorter(NodeSorter)

Remove an existing sorter. You need to call ExplorePwd or ExplorePwdAsync explicitly.

Type: { RemoveNodeSorter = Sorter }

Example:

  • Lua: { RemoveNodeSorter = "ByRelativePath" }
  • YAML: RemoveNodeSorter: ByRelativePath
§

ReverseNodeSorter(NodeSorter)

Reverse a node sorter. You need to call ExplorePwd or ExplorePwdAsync explicitly.

Type: { ReverseNodeSorter = Sorter }

Example:

  • Lua: { ReverseNodeSorter = "ByRelativePath" }
  • YAML: ReverseNodeSorter: ByRelativePath
§

ToggleNodeSorter(NodeSorterApplicable)

Remove a sorter if it exists, else, add a it. You need to call ExplorePwd or ExplorePwdAsync explicitly.

Type: { ToggleNodeSorter = { sorter = Sorter, reverse = bool } }

Example:

  • Lua: { ToggleSorterSorter: { sorter = "ByRelativePath", reverse = false } }
  • YAML: ToggleSorterSorter: {sorter: ByRelativePath, reverse: false }
§

ReverseNodeSorters

Reverse the node sorters. You need to call ExplorePwd or ExplorePwdAsync explicitly.

Example:

  • Lua: "ReverseNodeSorters"
  • YAML: ReverseNodeSorters
§

RemoveLastNodeSorter

Remove the last node sorter. You need to call ExplorePwd or ExplorePwdAsync explicitly.

Example:

  • Lua: "RemoveLastNodeSorter"
  • YAML: RemoveLastNodeSorter
§

ResetNodeSorters

Reset the node sorters back to the default configuration. You need to call ExplorePwd or ExplorePwdAsync explicitly.

Example:

  • Lua: "ResetNodeSorters"
  • YAML: ResetNodeSorters
§

ClearNodeSorters

Clear all the node sorters. You need to call ExplorePwd or ExplorePwdAsync explicitly.

Example:

  • Lua: "ClearNodeSorters"
  • YAML: ClearNodeSorters
§

Search(String)

§Search Operations –––––––––––––––––––––––––

Search files using the current or default (fuzzy) search algorithm. You need to call ExplorePwd or ExplorePwdAsync explicitly. It gets reset automatically when changing directory.

Type: { Search = “string” }

Example:

  • Lua: { Search = "pattern" }
  • YAML: Search: pattern
§

SearchFromInput

Calls Search with the input taken from the input buffer.

Example:

  • Lua: "SearchFromInput"
  • YAML: SearchFromInput
§

SearchFuzzy(String)

Search files using fuzzy match algorithm. It keeps the filters, but overrides the sorters. You need to call ExplorePwd or ExplorePwdAsync explicitly. It gets reset automatically when changing directory.

Type: { SearchFuzzy = “string” }

Example:

  • Lua: { SearchFuzzy = "pattern" }
  • YAML: SearchFuzzy: pattern
§

SearchFuzzyFromInput

Calls SearchFuzzy with the input taken from the input buffer. You need to call ExplorePwd or ExplorePwdAsync explicitly. It gets reset automatically when changing directory.

Example:

  • Lua: "SearchFuzzyFromInput"
  • YAML: SearchFuzzyFromInput
§

SearchFuzzyUnordered(String)

Like SearchFuzzy, but doesn’t not perform rank based sorting. You need to call ExplorePwd or ExplorePwdAsync explicitly. It gets reset automatically when changing directory.

Type: { SearchFuzzyUnordered = “string” }

Example:

  • Lua: { SearchFuzzyUnordered = "pattern" }
  • YAML: SearchFuzzyUnordered: pattern
§

SearchFuzzyUnorderedFromInput

Calls SearchFuzzyUnordered with the input taken from the input buffer. You need to call ExplorePwd or ExplorePwdAsync explicitly. It gets reset automatically when changing directory.

Example:

  • Lua: "SearchFuzzyUnorderedFromInput"
  • YAML: SearchFuzzyUnorderedFromInput
§

SearchRegex(String)

Search files using regex match algorithm. It keeps the filters, but overrides the sorters. You need to call ExplorePwd or ExplorePwdAsync explicitly. It gets reset automatically when changing directory.

Type: { SearchRegex = “string” }

Example:

  • Lua: { SearchRegex = "pattern" }
  • YAML: SearchRegex: pattern
§

SearchRegexFromInput

Calls SearchRegex with the input taken from the input buffer. You need to call ExplorePwd or ExplorePwdAsync explicitly. It gets reset automatically when changing directory.

Example:

  • Lua: "SearchRegexFromInput"
  • YAML: SearchRegexFromInput
§

SearchRegexUnordered(String)

Like SearchRegex, but doesn’t not perform rank based sorting. You need to call ExplorePwd or ExplorePwdAsync explicitly. It gets reset automatically when changing directory.

Type: { SearchRegexUnordered = “string” }

Example:

  • Lua: { SearchRegexUnordered = "pattern" }
  • YAML: SearchRegexUnordered: pattern
§

SearchRegexUnorderedFromInput

Calls SearchRegexUnordered with the input taken from the input buffer. You need to call ExplorePwd or ExplorePwdAsync explicitly. It gets reset automatically when changing directory.

Example:

  • Lua: "SearchRegexUnorderedFromInput"
  • YAML: SearchRegexUnorderedFromInput
§

ToggleSearchAlgorithm

Toggles between different search algorithms, without changing the input buffer You need to call ExplorePwd or ExplorePwdAsync explicitly.

Example:

  • Lua: "ToggleSearchAlgorithm"
  • YAML: ToggleSearchAlgorithm
§

EnableSearchOrder

Enables ranked search without changing the input buffer. You need to call ExplorePwd or ExplorePwdAsync explicitly.

Example:

  • Lua: "EnableOrderedSearch"
  • YAML: EnableSearchOrder
§

DisableSearchOrder

Disabled ranked search without changing the input buffer. You need to call ExplorePwd or ExplorePwdAsync explicitly.

Example:

  • Lua: "DisableSearchOrder"
  • YAML: DisableSearchOrder
§

ToggleSearchOrder

Toggles ranked search without changing the input buffer.

Example:

  • Lua: "ToggleSearchOrder"
  • YAML: ToggleSearchOrder
§

AcceptSearch

Accepts the search by keeping the latest focus while in search mode. Automatically calls ExplorePwd.

Example:

  • Lua: "AcceptSearch"
  • YAML: AcceptSearch
§

CancelSearch

Cancels the search by discarding the latest focus and recovering the focus before search. Automatically calls ExplorePwd.

Example:

  • Lua: "CancelSearch"
  • YAML: CancelSearch
§

EnableMouse

§Mouse Operations —————————————————

Enable mouse

Example:

  • Lua: "EnableMouse"
  • YAML: EnableMouse
§

DisableMouse

Disable mouse

Example:

  • Lua: "DisableMouse"
  • YAML: DisableMouse
§

ToggleMouse

Toggle mouse

Example:

  • Lua: "ToggleMouse"
  • YAML: ToggleMouse
§

StartFifo(String)

§Fifo Operations ––––––––––––––––––––––––––

Start piping the focused path to the given fifo path

Type: { StartFifo = “string” }

Example:

  • Lua: { StartFifo = "/tmp/xplr.fifo }
  • YAML: StartFifo: /tmp/xplr.fifo
§

StopFifo

Close the active fifo and stop piping.

Example:

  • Lua: "StopFifo"
  • YAML: StopFifo
§

ToggleFifo(String)

Toggle between {Start|Stop}Fifo

Type: { ToggleFifo = “string” }

Example:

  • Lua: { ToggleFifo = "/path/to/fifo" }
  • YAML: ToggleFifo: /path/to/fifo
§

LogInfo(String)

§Logging ————————————————————

Log information message.

Type: { LogInfo = “string” }

Example:

  • Lua: { LogInfo = "launching satellite" }
  • YAML: LogInfo: launching satellite
§

LogSuccess(String)

Log a success message.

Type: { LogSuccess = “String” }

Example:

  • Lua: { LogSuccess = "satellite reached destination" }
  • YAML: LogSuccess: satellite reached destination
§

LogWarning(String)

Log an warning message.

Type: { LogWarning = “string” }

Example:

  • Lua: { LogWarning = "satellite is heating" }
  • YAML: LogWarning: satellite is heating
§

LogError(String)

Log an error message.

Type: { LogError = “string” }

Example:

  • Lua: { LogError = "satellite crashed" }
  • YAML: LogError: satellite crashed
§

Debug(String)

§Debugging –––––––––––––––––––––––––––––

Write the application state to a file, without quitting. Also helpful for debugging.

Type: { Debug = “string” }

Example:

  • Lua: { Debug = "/path/to/file" }
  • YAML: Debug: /path/to/file
§

Quit

§Quit Options —————————————————––

Example:

  • Lua: "Quit"
  • YAML: Quit

Quit with returncode zero (success).

§

PrintPwdAndQuit

Print $PWD and quit.

Example:

  • Lua: "PrintPwdAndQuit"
  • YAML: PrintPwdAndQuit
§

PrintFocusPathAndQuit

Print the path under focus and quit. It can be empty string if there’s nothing to focus.

Example:

  • Lua: "PrintFocusPathAndQuit"
  • YAML: PrintFocusPathAndQuit
§

PrintSelectionAndQuit

Print the selected paths and quit. It can be empty is no path is selected.

Example:

  • Lua: "PrintSelectionAndQuit"
  • YAML: PrintSelectionAndQuit
§

PrintResultAndQuit

Print the selected paths if it’s not empty, else, print the focused node’s path.

Example:

  • Lua: "PrintResultAndQuit"
  • YAML: PrintResultAndQuit
§

PrintAppStateAndQuit

Print the state of application in YAML format. Helpful for debugging or generating the default configuration file.

Example:

  • Lua: "PrintAppStateAndQuit"
  • YAML: PrintAppStateAndQuit
§

Terminate

Terminate the application with a non-zero return code.

Example:

  • Lua: "Terminate"
  • YAML: Terminate

Implementations§

Trait Implementations§

source§

impl Clone for ExternalMsg

source§

fn clone(&self) -> ExternalMsg

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for ExternalMsg

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for ExternalMsg

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl PartialEq for ExternalMsg

source§

fn eq(&self, other: &ExternalMsg) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Serialize for ExternalMsg

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Eq for ExternalMsg

source§

impl StructuralPartialEq for ExternalMsg

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> AsAny for T
where T: Any,

source§

fn as_any(&self) -> &(dyn Any + 'static)

source§

fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)

source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

source§

fn equivalent(&self, key: &K) -> bool

Checks if this value is equivalent to the given key. Read more
source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

source§

fn equivalent(&self, key: &K) -> bool

Compare self to key and return true if they are equal.
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> IntoEither for T

source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
source§

impl<T> Pointable for T

source§

const ALIGN: usize = _

The alignment of pointer.
§

type Init = T

The type for initializers.
source§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
source§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
source§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
source§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
source§

impl<T> Serialize for T
where T: Serialize + ?Sized,

source§

fn erased_serialize(&self, serializer: &mut dyn Serializer) -> Result<(), Error>

source§

fn do_erased_serialize( &self, serializer: &mut dyn Serializer ) -> Result<(), ErrorImpl>

source§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,