SIMPLE SOLUTIONS

UTOP(1) - Linux man page online | User commands

Universal toplevel for OCaml.

Chapter
August 2011
UTOP(1) General Commands Manual UTOP(1)

NAME

utop - Universal toplevel for OCaml

SYNOPSIS

utop [ options ] [ object-files ] [ script-file ]

DESCRIPTION

utop is a enhanced toplevel for OCaml with many features, including context sensitive com‐ pletion. When you start utop what you see is the prompt followed by a bar containing words. This is the completion bar, it contains the possible completion and is updated as you type. The highlighted word in the completion bar is the selected word. You can navigate using the keys Alt+Left and Alt+Right and you can complete using the currently selected word by pressing Alt+Tab (you can configure these bindings in the file ~/.lambda-term-inputrc , see lambda-term-inputrc(5) for details). utop supports completion on: * directives and directive arguments * identifiers * record fields * variants * function labels * object methods Colors are by default configured for terminals with dark colors, such as white on black, so the prompt may looks too bright on light colors terminals. You can change that by set‐ ting the color profile of utop. For that type: UTop.set_profile UTop.Light;; You can then add this line to your ~/.ocamlinit file. You can enable basic syntax highlighting in utop by writing a ~/.utoprc file. See uto‐ prc(5) for that. Finally utop can run in emacs. For that you have to add the following line to your ~/.emacs file: (autoload 'utop "utop" "Toplevel for OCaml" t) then you can run utop by pressing M-x and typing "utop". utop support completion in emacs mode. Just press Tab to complete a word. You can also integrate it with the tuareg, caml or typerex mode. For that add the following lines to your ~/.emacs file: (autoload 'utop-minor-mode "utop" "Minor mode for utop" t) (add-hook 'tuareg-mode-hook 'utop-minor-mode)

OPTIONS

Same as ocaml(1).

FILES

~/.ocamlinit The initialization file of the toplevel. ~/.utoprc The configuration file for utop. See utoprc(5). ~/.lambda-term-inputrc The file containing key bindings. See lambda-term-inputrc(5).

AUTHOR

Jérémie Dimino <@dimino.org>

SEE ALSO

utoprc(5), lambda-term-inputrc(5), ocaml(1).
August 2011 UTOP(1)
This manual Reference Other manuals
utop(1) referred by utop-full(1) | utoprc(5)
refer to lambda-term-inputrc(5) | ocaml(1) | utoprc(5)
Download raw manual
Main page General Commands Manual (+12866) № 1 (+39907)
Go top