← 返回命令列表

Linux command

ledit 命令

文本

复制后可按需替换文件名、目录或参数。

常用示例

Run command with line editing

ledit [command]

Run OCaml with line editing

ledit ocaml

Use vi-style editing

ledit -v [command]

Specify history file

ledit -h [~/.ledit_history] [command]

说明

ledit provides line editing capabilities to programs that read from standard input. It wraps commands to add readline-style editing, command history, and line completion. ledit is particularly useful with interpreters and REPLs that lack built-in line editing support, such as older versions of OCaml.

参数

-v
Use vi-style editing mode.
-e
Use emacs-style editing mode (default).
-h _file_
Specify history file.
-x
Expand history on space.

FAQ

What is the ledit command used for?

ledit provides line editing capabilities to programs that read from standard input. It wraps commands to add readline-style editing, command history, and line completion. ledit is particularly useful with interpreters and REPLs that lack built-in line editing support, such as older versions of OCaml.

How do I run a basic ledit example?

Run `ledit [command]` in a terminal, then adjust file names, paths, flags, or remote targets for your system.

What does -v do in ledit?

Use vi-style editing mode.