Interactive help

From Rosetta Code
(Redirected from Interactive Help)
Interactive help is a draft programming task. It is not yet considered ready to be promoted as a complete task, for reasons that should be found in its talk page.


Demonstrate any interactive (or command line) help offered by the language implementation.

This can be for exploring features or syntax, or perhaps a simple message on where to find more information.


# syntax: GAWK --help
Usage: gawk [POSIX or GNU style options] -f progfile [--] file ...
Usage: gawk [POSIX or GNU style options] [--] 'program' file ...
POSIX options:          GNU long options: (standard)
        -f progfile             --file=progfile
        -F fs                   --field-separator=fs
        -v var=val              --assign=var=val
Short options:          GNU long options: (extensions)
        -b                      --characters-as-bytes
        -c                      --traditional
        -C                      --copyright
        -d[file]                --dump-variables[=file]
        -D[file]                --debug[=file]
        -e 'program-text'       --source='program-text'
        -E file                 --exec=file
        -g                      --gen-pot
        -h                      --help
        -i includefile          --include=includefile
        -l library              --load=library
        -L [fatal]              --lint[=fatal]
        -n                      --non-decimal-data
        -M                      --bignum
        -N                      --use-lc-numeric
        -o[file]                --pretty-print[=file]
        -O                      --optimize
        -p[file]                --profile[=file]
        -P                      --posix
        -r                      --re-interval
        -S                      --sandbox
        -t                      --lint-old
        -V                      --version

To report bugs, see node `Bugs' in `', which is
section `Reporting Problems and Bugs' in the printed version.

gawk is a pattern scanning and processing language.
By default it reads standard input and writes standard output.

        gawk '{ sum += $1 }; END { print sum }' file
        gawk -F: '{ print $1 }' /etc/passwd

Common Lisp[edit]

Common Lisp supports several interactive features for exploring the language and runtime. The built-in functions documentation and describe will both present information on objects in the system.

CL-USER> (describe #'char-code)
  [compiled function]

Lambda-list: (CHAR)
Declared type: (FUNCTION (CHARACTER) (VALUES (MOD 1114112) &OPTIONAL))
  Return the integer code of CHAR.
Known attributes: foldable, flushable, unsafely-flushable, movable
; No value
CL-USER> (documentation #'char-code 'function)
"Return the integer code of CHAR."


$ factor -h

Usage: [Factor arguments] [script] [script arguments]

Factor arguments:
    -help               print this message and exit
    -version            print the Factor version and exit
    -i=<image>          load Factor image file <image> (default factor.image)
    -run=<vocab>        run the MAIN: entry point of <vocab>
        -run=listener   run terminal listener   run Factor development UI
    -e=<code>           evaluate <code>
    -no-user-init       suppress loading of .factor-rc
    -datastack=<int>    datastack size in KiB
    -retainstack=<int>  retainstack size in KiB
    -callstack=<int>    callstack size in KiB
    -callbacks=<int>    callback heap size in KiB
    -young=<int>        young gc generation 0 size in MiB
    -aging=<int>        aging gc generation 1 size in MiB
    -tenured=<int>      tenured gc generation 2 size in MiB
    -codeheap=<int>     codeheap size in MiB
    -pic=<int>          max pic size
    -fep                enter fep mode immediately
    -no-signals         turn off OS signal handling
    -console            open console if possible
    -roots=<paths>      a list of ";"-delimited extra vocab roots

    "command-line" help
from within Factor for more information.

Additionally, by pressing F1 in the listener, you can access the help browser, an offline version of Factor's documentation. Factor's help browser interfaces with the listener in various ways. For example, pressing ctrl+h while the cursor is over a word will take you to that word's documentation. Running "sequences" about in the listener will take you to the documentation for the sequences vocabulary.


See FB-manual-1.0x.chm for the complete manual, available in sourceforge, or online.

When invoked as fbc -help, or fbc --help at the command line:
usage: fbc [options] <input files>
input files:
  *.a = static library, *.o = object file, *.bas = source
  *.rc = resource script, *.res = compiled resource (win32)
  *.xpm = icon resource (*nix/*bsd)
  @<file>          Read more command line arguments from a file
  -a <file>        Treat file as .o/.a input file
  -arch <type>     Set target architecture (default: 486)
  -asm att|intel   Set asm format (-gen gcc|llvm, x86 or x86_64 only)
  -b <file>        Treat file as .bas input file
  -c               Compile only, do not link
  -C               Preserve temporary .o files
  -d <name>[=<val>]  Add a global #define
  -dll             Same as -dylib
  -dylib           Create a DLL (win32) or shared library (*nix/*BSD)
  -e               Enable runtime error checking
  -ex              -e plus RESUME support
  -exx             -ex plus array bounds/null-pointer checking
  -export          Export symbols for dynamic linkage
  -forcelang <name>  Override #lang statements in source code
  -fpmode fast|precise  Select floating-point math accuracy/speed
  -fpu x87|sse     Set target FPU
  -g               Add debug info, enable __FB_DEBUG__, and enable assert()
  -gen gas|gcc|llvm  Select code generation backend
  [-]-help         Show this help output
  -i <path>        Add an include file search path
  -include <file>  Pre-#include a file for each input .bas
  -l <name>        Link in a library
  -lang <name>     Select FB dialect: fb, deprecated, fblite, qb
  -lib             Create a static library
  -m <name>        Specify main module (default if not -c: first input .bas)
  -map <file>      Save linking map to file
  -maxerr <n>      Only show <n> errors
  -mt              Use thread-safe FB runtime
  -nodeflibs       Do not include the default libraries
  -noerrline       Do not show source context in error messages
  -noobjinfo       Do not read/write compile-time info from/to .o and .a files
  -nostrip         Do not strip symbol information from the output file
  -o <file>        Set .o (or -pp .bas) file name for prev/next input file
  -O <value>       Optimization level (default: 0)
  -p <path>        Add a library search path
  -pic             Generate position-independent code (non-x86 Unix shared libs)
  -pp              Write out preprocessed input file (.pp.bas) only
  -prefix <path>   Set the compiler prefix path
  -print host|target  Display host/target system name
  -print fblibdir  Display the compiler's lib/ path
  -print x         Display output binary/library file name (if known)
  -profile         Enable function profiling
  -r               Write out .asm/.c/.ll (-gen gas/gcc/llvm) only
  -rr              Write out the final .asm only
  -R               Preserve temporary .asm/.c/.ll/.def files
  -RR              Preserve the final .asm file
  -s console|gui   Select win32 subsystem
  -showincludes    Display a tree of file names of #included files
  -static          Prefer static libraries over dynamic ones when linking
  -strip           Omit all symbol information from the output file
  -t <value>       Set .exe stack size in kbytes, default: 1024 (win32/dos)
  -target <name>   Set cross-compilation target
  -title <name>    Set XBE display title (xbox)
  -v               Be verbose
  -vec <n>         Automatic vectorization level (default: 0)
  [-]-version      Show compiler version
  -w all|pedantic|<n>  Set min warning level: all, pedantic or a value
  -Wa <a,b,c>      Pass options to 'as'
  -Wc <a,b,c>      Pass options to 'gcc' (-gen gcc) or 'llc' (-gen llvm)
  -Wl <a,b,c>      Pass options to 'ld'
  -x <file>        Set output executable/library file name


The 'go doc' command line tool shows documentation for either a package or a symbol within a package.

For example, here we list the exported functions and types in the 'strings' package in the standard library:

$ go doc strings
package strings // import "strings"

Package strings implements simple functions to manipulate UTF-8 encoded

For information about UTF-8 strings in Go, see

func Compare(a, b string) int
func Contains(s, substr string) bool
func ContainsAny(s, chars string) bool
func ContainsRune(s string, r rune) bool
func Count(s, substr string) int
func EqualFold(s, t string) bool
func Fields(s string) []string
func FieldsFunc(s string, f func(rune) bool) []string
func HasPrefix(s, prefix string) bool
func HasSuffix(s, suffix string) bool
func Index(s, substr string) int
func IndexAny(s, chars string) int
func IndexByte(s string, c byte) int
func IndexFunc(s string, f func(rune) bool) int
func IndexRune(s string, r rune) int
func Join(a []string, sep string) string
func LastIndex(s, substr string) int
func LastIndexAny(s, chars string) int
func LastIndexByte(s string, c byte) int
func LastIndexFunc(s string, f func(rune) bool) int
func Map(mapping func(rune) rune, s string) string
func Repeat(s string, count int) string
func Replace(s, old, new string, n int) string
func Split(s, sep string) []string
func SplitAfter(s, sep string) []string
func SplitAfterN(s, sep string, n int) []string
func SplitN(s, sep string, n int) []string
func Title(s string) string
func ToLower(s string) string
func ToLowerSpecial(c unicode.SpecialCase, s string) string
func ToTitle(s string) string
func ToTitleSpecial(c unicode.SpecialCase, s string) string
func ToUpper(s string) string
func ToUpperSpecial(c unicode.SpecialCase, s string) string
func Trim(s string, cutset string) string
func TrimFunc(s string, f func(rune) bool) string
func TrimLeft(s string, cutset string) string
func TrimLeftFunc(s string, f func(rune) bool) string
func TrimPrefix(s, prefix string) string
func TrimRight(s string, cutset string) string
func TrimRightFunc(s string, f func(rune) bool) string
func TrimSpace(s string) string
func TrimSuffix(s, suffix string) string
type Builder struct{ ... }
type Reader struct{ ... }
    func NewReader(s string) *Reader
type Replacer struct{ ... }
    func NewReplacer(oldnew ...string) *Replacer

BUG: The rule Title uses for word boundaries does not handle Unicode punctuation properly.

We can now 'dig down' to obtain the documentation for the TrimSpace function wthin the strings package:

$ go doc strings.TrimSpace
func TrimSpace(s string) string
    TrimSpace returns a slice of the string s, with all leading and trailing
    white space removed, as defined by Unicode.

and to list the methods of the strings.Replacer struct:

$ go doc strings.Replacer
type Replacer struct {
	// Has unexported fields.
    Replacer replaces a list of strings with replacements. It is safe for
    concurrent use by multiple goroutines.

func NewReplacer(oldnew ...string) *Replacer
func (r *Replacer) Replace(s string) string
func (r *Replacer) WriteString(w io.Writer, s string) (n int, err error)

Finally, we obtain the documentation for the strings.Replacer.WriteString method:

$ go doc strings.Replacer.WriteString
func (r *Replacer) WriteString(w io.Writer, s string) (n int, err error)
    WriteString writes s to w with all replacements performed.

The 'go doc' tool also has some flags including a flag to list both exported and unexported symbols (-u) and to respect case when matching symbols (-c); normally lower- case letters match either case.


prompt$ jsish
Jsish interactive: see 'help [cmd]'
# help
Jsish interactive executes commands, uses tab for completions, and has help for the following builtin commands:

     Array Boolean CData CEnum CStruct CType Channel Debugger Event File
     Function Info Interp JSON Math Number Object RegExp Signal Socket
     Sqlite String System Util Vfs WebSocket Zvfs assert clearInterval
     console decodeURI encodeURI exec exit format isFinite isMain isNaN
     load log noOp parseFloat parseInt parseOpts printf provide puts quote
     require runModule setInterval setTimeout sleep source strftime strptime
     unload update 

Help can also take options.  For example to display in a web browser try:

    help -web true WebSocket

Module help can also be displayed (non-web), as in 'help Jsi_Websrv`.
Builtin modules include:

     Jsi_Archive Jsi_CData Jsi_Csspp Jsi_Debug Jsi_DebugUI Jsi_GenDeep
     Jsi_Help Jsi_Htmlpp Jsi_Jspp Jsi_Markdeep Jsi_Module Jsi_Safe Jsi_SqliteUI
     Jsi_UnitTest Jsi_Vfs Jsi_Websrv Jsi_Wget
# help File
Commands for accessing the filesystem
Methods: atime chdir chmod copy dirname executable exists extension glob isdir isfile isrelative join link lstat mkdir mknod mtime owned pwd read readable readlink realpath remove rename rootname size stat tail tempfile truncate type writable write

[File.glob options]
Option          Type    Description [Flags]
dir             STRING  The start directory: this path will not be prepended to results.
maxDepth        INT     Maximum directory depth to recurse into.
maxDiscard      INT     Maximum number of items to discard before giving up.
dirFilter       FUNC    Filter function for directories, returning false to discard. @function(dir:string)
filter          FUNC    Filter function to call with each file, returning false to discard. @function(file:string)
limit           INT     The maximum number of results to return/count.
noTypes         STRKEY  Filter files to exclude these "types".
prefix          STRKEY  String prefix to add to each file in list.
recurse         BOOL    Recurse into sub-directories.
retCount        BOOL    Return only the count of matches.
tails           BOOL    Returned only tail of path.
types           STRKEY  Filter files to include type: one or more of chars 'fdlpsbc' for file, directory, link, etc.


When Julia is run without a program file as argument, the REPL (Read-Evaluate-Print Loop) runs. Entering a ? at the prompt brings up help, with help on a specific topic obtained if the topic name is preceded by ? at the prompt.

> julia
   _       _ _(_)_     |  Documentation:
  (_)     | (_) (_)    |
   _ _   _| |_  __ _   |  Type "?" for help, "]?" for Pkg help.
  | | | | | | |/ _` |  |
  | | |_| | | | (_| |  |  Version 1.1.1 (2019-05-16)
 _/ |\__'_|_|_|\__'_|  |  Official release
|__/                   |

search: ⊻ ⊋ ⊊ ⊉ ⊈ ⊇ ⊆ ≥ ≤ ≢ ≡ ≠ ≉ ≈ ∪ ∩ ∛ √ ∘ ∌ ∋ ∉ ∈ ℯ π ÷ ~ | ^ \ > < : / - + * & % ! if do IO |> rm pi mv in im fd cp

  Welcome to Julia 1.1.1. The full manual is available at

  as well as many great tutorials and learning resources:

  For help on a specific function or macro, type ? followed by its name, e.g. ?cos, or ?@time, and press enter. Type ;
  to enter shell mode, ] to enter package mode.

help?> function
search: function Function functionloc @functionloc @cfunction


  Functions are defined with the function keyword:

  function add(a, b)
      return a + b

  Or the short form notation:

  add(a, b) = a + b

  The use of the return keyword is exactly the same as in other languages, but is often optional. A function without
  an explicit return statement will return the last expression in the function body.


The Nim compiler provides help. By simply typing nim without any option, we get:

Nim Compiler Version 1.4.8 [Linux: amd64]
Compiled at 2021-05-25
Copyright (c) 2006-2021 by Andreas Rumpf

    nim command [options] [projectfile] [arguments]

    compile, c              compile project with default code generator (C)
    r                       compile to $nimcache/projname, run with [arguments]
                            using backend specified by `--backend` (default: c)
    doc                     generate the documentation for inputfile for
                            backend specified by `--backend` (default: c)

  arguments are passed to the program being run (if --run option is selected)

  -p, --path:PATH           add path to search paths
  -d, --define:SYMBOL(:VAL)
                            define a conditional symbol
                            (Optionally: Define the value for that symbol,
                            see: "compile time define pragmas")
  -u, --undef:SYMBOL        undefine a conditional symbol
  -f, --forceBuild:on|off   force rebuilding of all modules
  --stackTrace:on|off       turn stack tracing on|off
  --lineTrace:on|off        turn line tracing on|off
  --threads:on|off          turn support for multi-threading on|off
  -x, --checks:on|off       turn all runtime checks on|off
  -a, --assertions:on|off   turn assertions on|off
  --opt:none|speed|size     optimize not at all or for speed|size
                            Note: use -d:release for a release build!
  --debugger:native         Use native debugger (gdb)
                            generate a console app|GUI app|DLL|static library
  -r, --run                 run the compiled program with given arguments
  --fullhelp                show all command line switches
  -h, --help                show this help
  -v, --version             show detailed version information

Note, single letter options that take an argument require a colon. E.g. -p:PATH

This is the basic help. We can get full help by typing nim --fullHelp:

Nim Compiler Version 1.4.8 [Linux: amd64]
Compiled at 2021-05-25
Copyright (c) 2006-2021 by Andreas Rumpf

    nim command [options] [projectfile] [arguments]

    compile, c              compile project with default code generator (C)
    r                       compile to $nimcache/projname, run with [arguments]
                            using backend specified by `--backend` (default: c)
    doc                     generate the documentation for inputfile for
                            backend specified by `--backend` (default: c)

  arguments are passed to the program being run (if --run option is selected)

  -p, --path:PATH           add path to search paths
  -d, --define:SYMBOL(:VAL)
                            define a conditional symbol
                            (Optionally: Define the value for that symbol,
                            see: "compile time define pragmas")
  -u, --undef:SYMBOL        undefine a conditional symbol
  -f, --forceBuild:on|off   force rebuilding of all modules
  --stackTrace:on|off       turn stack tracing on|off
  --lineTrace:on|off        turn line tracing on|off
  --threads:on|off          turn support for multi-threading on|off
  -x, --checks:on|off       turn all runtime checks on|off
  -a, --assertions:on|off   turn assertions on|off
  --opt:none|speed|size     optimize not at all or for speed|size
                            Note: use -d:release for a release build!
  --debugger:native         Use native debugger (gdb)
                            generate a console app|GUI app|DLL|static library
  -r, --run                 run the compiled program with given arguments
  --fullhelp                show all command line switches
  -h, --help                show this help
  -v, --version             show detailed version information

Note, single letter options that take an argument require a colon. E.g. -p:PATH.
Advanced commands:
    compileToC, cc          compile project with C code generator
    compileToCpp, cpp       compile project to C++ code
    compileToOC, objc       compile project to Objective C code
    js                      compile project to Javascript
    e                       run a Nimscript file
    rst2html                convert a reStructuredText file to HTML
                            use `--docCmd:skip` to skip compiling snippets
    rst2tex                 convert a reStructuredText file to TeX
    jsondoc                 extract the documentation to a json file
    ctags                   create a tags file
    buildIndex              build an index for the whole documentation
    genDepend               generate a DOT file containing the
                            module dependency graph
    dump                    dump all defined conditionals and search paths
                            see also: --dump.format:json (useful with: `| jq`)
    check                   checks the project for syntax and semantic

Runtime checks (see -x):
  --objChecks:on|off        turn obj conversion checks on|off
  --fieldChecks:on|off      turn case variant field checks on|off
  --rangeChecks:on|off      turn range checks on|off
  --boundChecks:on|off      turn bound checks on|off
  --overflowChecks:on|off   turn int over-/underflow checks on|off
  --floatChecks:on|off      turn all floating point (NaN/Inf) checks on|off
  --nanChecks:on|off        turn NaN checks on|off
  --infChecks:on|off        turn Inf checks on|off
  --refChecks:on|off        turn ref checks on|off (only for --newruntime)

Advanced options:
  -o:FILE, --out:FILE       set the output filename
  --outdir:DIR              set the path where the output file will be written
  --usenimcache             will use `outdir=$nimcache`, whichever it resolves
                            to after all options have been processed
  --stdout:on|off           output to stdout
  --colors:on|off           turn compiler messages coloring on|off
  --listFullPaths:on|off    list full paths in messages
  -w:on|off|list, --warnings:on|off|list
                            turn all warnings on|off or list all available
  --warning[X]:on|off       turn specific warning X on|off
  --hints:on|off|list       turn all hints on|off or list all available
  --hint[X]:on|off          turn specific hint X on|off
                            turn specific warning X into an error on|off
                            produce hints or errors for Nim identifiers that
                            do not adhere to Nim's official style guide
  --styleCheck:usages       only enforce consistent spellings of identifiers,
                            do not enforce the style on declarations
                            show all mismatching candidates in overloading
  --lib:PATH                set the system library path
  --import:PATH             add an automatically imported module
  --include:PATH            add an automatically included module
  --nimcache:PATH           set the path used for generated files
                            see also
  -c, --compileOnly:on|off  compile Nim files only; do not assemble or link
  --noLinking:on|off        compile Nim and generated files but do not link
  --noMain:on|off           do not generate a main procedure
  --genScript:on|off        generate a compile script (in the 'nimcache'
                            subdirectory named 'compile_$project$scriptext'),
                            implies --compileOnly
  --genDeps:on|off          generate a '.deps' file containing the dependencies
  --os:SYMBOL               set the target operating system (cross-compilation)
  --cpu:SYMBOL              set the target processor (cross-compilation)
  --debuginfo:on|off        enables debug information
  -t, --passC:OPTION        pass an option to the C compiler
  -l, --passL:OPTION        pass an option to the linker
  --cc:SYMBOL               specify the C compiler
  --cincludes:DIR           modify the C compiler header search path
  --clibdir:DIR             modify the linker library search path
  --clib:LIBNAME            link an additional C library
                            (you should omit platform-specific extensions)
  --project                 document the whole project (doc)
  --docRoot:path            `nim doc --docRoot:/foo --project --outdir:docs /foo/sub/main.nim`
                            generates: docs/sub/main.html
                            if path == @pkg, will use nimble file enclosing dir
                            if path == @path, will use first matching dir in `--path`
                            if path == @default (the default and most useful), will use
                            best match among @pkg,@path.
                            if these are nonexistent, will use project path
  -b, --backend:c|cpp|js|objc sets backend to use with commands like `nim doc` or `nim r`
  --docCmd:cmd              if `cmd == skip`, skips runnableExamples
                            else, runs runnableExamples with given options, e.g.:
                            `--docCmd:"-d:foo --threads:on"`
  --docSeeSrcUrl:url        activate 'see source' for doc command
                            (see doc.item.seesrc in config/nimdoc.cfg)
  --docInternal             also generate documentation for non-exported symbols
  --lineDir:on|off          generation of #line directive on|off
  --embedsrc:on|off         embeds the original source code as comments
                            in the generated output
  --threadanalysis:on|off   turn thread analysis on|off
  --tlsEmulation:on|off     turn thread local storage emulation on|off
  --taintMode:on|off        turn taint mode on|off
  --implicitStatic:on|off   turn implicit compile time evaluation on|off
  --trmacros:on|off         turn term rewriting macros on|off
  --multimethods:on|off     turn multi-methods on|off
  --memTracker:on|off       turn memory tracker on|off
                            turn support for hot code reloading on|off
                            stack traces use full file paths
  --stackTraceMsgs:on|off   enable user defined stack frame msgs via `setFrameMsg`
  --nilseqs:on|off          allow 'nil' for strings/seqs for
                            backwards compatibility
  --seqsv2:on|off           use the new string/seq implementation based on
  --skipCfg:on|off          do not read the nim installation's configuration file
  --skipUserCfg:on|off      do not read the user's configuration file
  --skipParentCfg:on|off    do not read the parent dirs' configuration files
  --skipProjCfg:on|off      do not read the project's configuration file
                            select the GC to use; default is 'refc'
                            select the exception handling implementation
  --index:on|off            turn index file generation on|off
  --putenv:key=value        set an environment variable
  --NimblePath:PATH         add a path for Nimble support
  --noNimblePath            deactivate the Nimble path
  --clearNimblePath         empty the list of Nimble package search paths
                            use the provided namespace for the generated C++ code,
                            if no namespace is provided "Nim" will be used
  --expandMacro:MACRO       dump every generated AST from MACRO
  --expandArc:PROCNAME      show how PROCNAME looks like after diverse optimizations
                            before the final backend phase (mostly ARC/ORC specific)
  --excludePath:PATH        exclude a path from the list of search paths
  --dynlibOverride:SYMBOL   marks SYMBOL so that dynlib:SYMBOL
                            has no effect and can be statically linked instead;
                            symbol matching is fuzzy so
                            that --dynlibOverride:lua matches
                            dynlib: ""
                            disables the effects of the dynlib pragma
  --listCmd                 list the compilation commands; can be combined with
                            `--hint:exec:on` and `--hint:link:on`
  --asm                     produce assembler code
  --parallelBuild:0|1|...   perform a parallel build
                            value = number of processors (0 for auto-detect)
  --incremental:on|off      only recompile the changed modules (experimental!)
  --verbosity:0|1|2|3       set Nim's verbosity level (1 is default)
  --errorMax:N              stop compilation after N errors; 0 means unlimited
  --maxLoopIterationsVM:N   set max iterations for all VM loops
                            enable experimental language feature
                            enable obsolete/legacy language feature
  --useVersion:1.0          emulate Nim version X of the Nim compiler
  --profiler:on|off         enable profiling; requires `import nimprof`, and
                            works better with `--stackTrace:on`
                            see also
  --benchmarkVM:on|off      enable benchmarking of VM code with cpuTime()
  --profileVM:on|off        enable compile time VM profiler
  --sinkInference:on|off    en-/disable sink parameter inference (default: on)
  --panics:on|off           turn panics into process terminations (default: off)
  --deepcopy:on|off         enable 'system.deepCopy' for ``--gc:arc|orc``

The nimble program used to install modules has it own help. Type nimble without any option:

Usage: nimble [nimbleopts] COMMAND [cmdopts]

  install      [pkgname, ...]     Installs a list of packages.
               [-d, --depsOnly]   Installs only dependencies of the package.
               [opts, ...]        Passes options to the Nim compiler.
  develop      [pkgname, ...]     Clones a list of packages for development.
                                  Symlinks the cloned packages or any package
                                  in the current working directory.
  check                           Verifies the validity of a package in the
                                  current working directory.
  init         [pkgname]          Initializes a new Nimble project in the
                                  current directory or if a name is provided a
                                  new directory of the same name.
               [--git, --hg]      Creates a git/hg repo in the new nimble project.
  publish                         Publishes a package on nim-lang/packages.
                                  The current working directory needs to be the
                                  toplevel directory of the Nimble package.
  uninstall    [pkgname, ...]     Uninstalls a list of packages.
               [-i, --inclDeps]   Uninstalls package and dependent package(s).
  build        [opts, ...] [bin]  Builds a package. Passes options to the Nim
  run          [opts, ...] [bin]  Builds and runs a package.
                                  Binary needs to be specified after any
                                  compilation options if there are several
                                  binaries defined. Any flags after the binary
                                  or -- arg are passed to the binary when it is run.
  c, cc, js    [opts, ...] f.nim  Builds a file inside a package. Passes options
                                  to the Nim compiler.
  test                            Compiles and executes tests.
               [-c, --continue]   Don't stop execution on a failed test.
               [opts, ...]        Passes options to the Nim compiler.
  doc, doc2    [opts, ...] f.nim  Builds documentation for a file inside a
                                  package. Passes options to the Nim compiler.
  refresh      [url]              Refreshes the package list. A package list URL
                                  can be optionally specified.
  search       pkg/tag            Searches for a specified package. Search is
                                  performed by tag and by name.
               [--ver]            Queries remote server for package version.
  list                            Lists all packages.
               [--ver]            Queries remote server for package version.
               [-i, --installed]  Lists all installed packages.
  tasks                           Lists the tasks specified in the Nimble
                                  package's Nimble file.
  path         pkgname ...        Shows absolute path to the installed packages
  dump         [pkgname]          Outputs Nimble package information for
                                  external tools. The argument can be a
                                  .nimble file, a project directory or
                                  the name of an installed package.
               [--ini, --json]    Selects the output format (the default is --ini).

Nimble Options:
  -h, --help                      Print this help message.
  -v, --version                   Print version information.
  -y, --accept                    Accept all interactive prompts.
  -n, --reject                    Reject all interactive prompts.
  -l, --localdeps                 Run in project local dependency mode
      --ver                       Query remote server for package version
                                  information when searching or listing packages.
      --nimbleDir:dirname         Set the Nimble directory.
      --nim:path                  Use specified path for Nim compiler
      --silent                    Hide all Nimble and Nim output
      --verbose                   Show all non-debug output.
      --debug                     Show all output including debug messages.
      --noColor                   Don't colorise output.
      --noSSLCheck                Don't check SSL certificates.

For more information read the Github readme:

And, last but not least, Nim provides nimsuggest which can be integrated in an IDE to provide completion and help when typing a program. The best integration is probably the one done for VSCode which is certainly the most used IDE for programming in Nim.


When invoked as perl -h at the command line:
Usage: perl [switches] [--] [programfile] [arguments]
  -0[octal]         specify record separator (\0, if no argument)
  -a                autosplit mode with -n or -p (splits $_ into @F)
  -C[number/list]   enables the listed Unicode features
  -c                check syntax only (runs BEGIN and CHECK blocks)
  -d[:debugger]     run program under debugger
  -D[number/list]   set debugging flags (argument is a bit mask or alphabets)
  -e program        one line of program (several -e's allowed, omit programfile)
  -E program        like -e, but enables all optional features
  -f                don't do $sitelib/ at startup
  -F/pattern/       split() pattern for -a switch (//'s are optional)
  -i[extension]     edit <> files in place (makes backup if extension supplied)
  -Idirectory       specify @INC/#include directory (several -I's allowed)
  -l[octal]         enable line ending processing, specifies line terminator
  -[mM][-]module    execute "use/no module..." before executing program
  -n                assume "while (<>) { ... }" loop around program
  -p                assume loop like -n but print line also, like sed
  -s                enable rudimentary parsing for switches after programfile
  -S                look for programfile using PATH environment variable
  -t                enable tainting warnings
  -T                enable tainting checks
  -u                dump core after parsing program
  -U                allow unsafe operations
  -v                print version, patchlevel and license
  -V[:variable]     print configuration summary (or a single variable)
  -w                enable many useful warnings
  -W                enable all warnings
  -x[directory]     ignore text before #!perl line (optionally cd to directory)
  -X                disable all warnings

Run 'perldoc perl' for more help with Perl.
Running perldoc perl, output includes (but is not limited to):
    The perldoc program gives you access to all the documentation that comes
    with Perl. You can get more documentation, tutorials and community
    support online at <>.

    If you're new to Perl, you should start by running "perldoc perlintro",
    which is a general intro for beginners and provides some background to
    help you navigate the rest of Perl's extensive documentation. Run
    "perldoc perldoc" to learn more things you can do with perldoc.

    For ease of access, the Perl manual has been split up into several

        perl                Perl overview (this section)
        perlintro           Perl introduction for beginners
        perlrun             Perl execution and options
        perltoc             Perl documentation table of contents

        perlreftut          Perl references short introduction
        perldsc             Perl data structures intro
        perllol             Perl data structures: arrays of arrays
        perlrequick         Perl regular expressions quick start
        perlretut           Perl regular expressions tutorial
        perlootut           Perl OO tutorial for beginners
        perlperf            Perl Performance and Optimization Techniques
        perlstyle           Perl style guide
        perlcheat           Perl cheat sheet
        perltrap            Perl traps for the unwary
        perldebtut          Perl debugging tutorial
        perlfaq             Perl frequently asked questions
          perlfaq1          General Questions About Perl
          perlfaq2          Obtaining and Learning about Perl
          perlfaq3          Programming Tools
          perlfaq4          Data Manipulation
          perlfaq5          Files and Formats
          perlfaq6          Regexes
          perlfaq7          Perl Language Issues
          perlfaq8          System Interaction
          perlfaq9          Networking

  Reference Manual
        perlsyn             Perl syntax
        perldata            Perl data structures
        perlop              Perl operators and precedence
        perlsub             Perl subroutines
        perlfunc            Perl built-in functions
        perlpod             Perl plain old documentation
        perldiag            Perl diagnostic messages
        perldeprecation     Perl deprecations
        perllexwarn         Perl warnings and their control
        perldebug           Perl debugging
        perlvar             Perl predefined variables
        perlre              Perl regular expressions, the rest of the story
        perlref             Perl references, the rest of the story
        perlobj             Perl objects
        perltie             Perl objects hidden behind simple variables
        perlipc             Perl interprocess communication
        perlfork            Perl fork() information
        perlnumber          Perl number semantics
        perlthrtut          Perl threads tutorial
        perlport            Perl portability guide
        perllocale          Perl locale support
        perlunicode         Perl Unicode support
        perlunifaq          Perl Unicode FAQ
        perlunitut          Perl Unicode tutorial
        perlsec             Perl security
        perlmod             Perl modules: how they work
        perlmodlib          Perl modules: how to write and use
        perlmodinstall      Perl modules: how to install from CPAN
        perlutil            utilities packaged with the Perl distribution
        perlglossary        Perl Glossary
        perlbook            Perl book information
        perlcommunity       Perl community information
        perldoc             Look up Perl documentation in Pod format
        perldelta           Perl changes since previous version


See docs\phix\phix.chm for the complete manual, or online.
When p -?, p -h, p -help, or p --help is entered:

interpret: <filename>
compile: -c <filename>

also: -d creates a list.asm file,
      -nodiag creates a smaller list.asm file,
      -norun may be useful in batch jobs,
      -test, tnn, b, bt, etc, and of course
      -c p, which rebuilds the compiler.
      for more details\options see pth.exw.

Wildcards are allowed, as long as they select a single file,
 with ".exw" assumed, eg "demo\tak*" runs demo\takeuchi.exw.

Press F7 to list prompt history, up/down to select.

Phix hybrid interpreter/compiler.

Version 1.0.2 (32 bit Windows) Copyright Pete Lomax 2006..2022

Enter ? for options or filename to execute:

(Pressing ? at that last prompt would re-display the text just shown.)


In the command line, raco docs <optional-query> will open internet browser and show locally-built Racket docs (main Racket and and any packages locally installed).

In the Racket REPL, help or (help <optional-query>) functions similar to raco docs. Note that if the query is an identifier, help will be able to extract lexical information attached to the identifier, resulting in a precise documentation lookup.

In Racket file, help could be obtained by (require racket/help)


(formerly Perl 6)

Raku help is generally in a specialized text format known as POD (Plain Old Documentation). It is sometimes referred to as POD6 to distinguish it from Perl 5 POD which is slightly different and not completely compatible. Raku has a local command line help app: p6doc. zef install p6doc It also has online browsable HTML documentation at If you want to download the HTML docs for a local copy, or just prefer to browse the documentation as a single page may be more to your preference. If you prefer a different format, there are utilities available to convert the POD docs to several different formats; Markdown, PDF, Latex, plain text, etc.

Individual Raku scripts are to some extent self-documenting. If the script has a MAIN sub, and it is called with improper parameters, it will display an automatically generated help message showing the various possible parameters, which are required, which are optional, and what type each takes:

sub MAIN(
    Str $run,             #= Task or file name
    Str :$lang = 'raku',  #= Language, default raku
    Int :$skip = 0,       #= Skip # to jump partially into a list
    Bool :f(:$force),     #= Override any skip parameter
) {
    # do whatever
When saved locally as main.raku and invoked with no (or wrong) passed parameters:
  main.raku [--lang=<Str>] [--skip=<Int>] [-f|--force] <run>
    <run>           Task or file name
    --lang=<Str>    Language, default raku
    --skip=<Int>    Skip # to jump partially into a list
    -f|--force      Override any skip parameter


Some REXXes offer interactive help   (via HELP or some other command).

Other REXXes have an HTML document or a PDF for showing command syntax and other general information on use of the language.

Each REXX has it's own documentation, and viewing it would depend on the host environment and the particular version of REXX.


The Rust compiler's help screen:

$ rustc --help
Usage: rustc [OPTIONS] INPUT

    -h, --help          Display this message
        --cfg SPEC      Configure the compilation environment
    -L [KIND=]PATH      Add a directory to the library search path. The
                        optional KIND can be one of dependency, crate, native,
                        framework, or all (the default).
    -l [KIND=]NAME      Link the generated crate(s) to the specified native
                        library NAME. The optional KIND can be one of
                        static, framework, or dylib (the default).
        --crate-type [bin|lib|rlib|dylib|cdylib|staticlib|proc-macro]
                        Comma separated list of types of crates
                        for the compiler to emit
        --crate-name NAME
                        Specify the name of the crate being built
        --edition 2015|2018
                        Specify which edition of the compiler to use when
                        compiling code.
        --emit [asm|llvm-bc|llvm-ir|obj|metadata|link|dep-info|mir]
                        Comma separated list of types of output for the
                        compiler to emit
        --print [crate-name|file-names|sysroot|cfg|target-list|target-cpus|target-features|relocation-models|code-models|tls-models|target-spec-json|native-static-libs]
                        Compiler information to print on stdout
    -g                  Equivalent to -C debuginfo=2
    -O                  Equivalent to -C opt-level=2
    -o FILENAME         Write output to <filename>
        --out-dir DIR   Write output to compiler-chosen filename in <dir>
        --explain OPT   Provide a detailed explanation of an error message
        --test          Build a test harness
        --target TARGET Target triple for which the code is compiled
    -W, --warn OPT      Set lint warnings
    -A, --allow OPT     Set lint allowed
    -D, --deny OPT      Set lint denied
    -F, --forbid OPT    Set lint forbidden
        --cap-lints LEVEL
                        Set the most restrictive lint level. More restrictive
                        lints are capped at this level
    -C, --codegen OPT[=VALUE]
                        Set a codegen option
    -V, --version       Print version info and exit
    -v, --verbose       Use verbose output

Additional help:
    -C help             Print codegen options
    -W help             Print 'lint' options and default settings
    -Z help             Print unstable compiler options
    --help -v           Print the full set of options rustc accepts

Cargo's help screen:

$ cargo --help
Rust's package manager


    -V, --version           Print version info and exit
        --list              List installed commands
        --explain <CODE>    Run `rustc --explain CODE`
    -v, --verbose           Use verbose output (-vv very verbose/ output)
    -q, --quiet             No output printed to stdout
        --color <WHEN>      Coloring: auto, always, never
        --frozen            Require Cargo.lock and cache are up to date
        --locked            Require Cargo.lock is up to date
        --offline           Run without accessing the network
    -Z <FLAG>...            Unstable (nightly-only) flags to Cargo, see 'cargo -Z help' for details
    -h, --help              Prints help information

Some common cargo commands are (see all commands with --list):
    build       Compile the current package
    check       Analyze the current package and report errors, but don't build object files
    clean       Remove the target directory
    doc         Build this package's and its dependencies' documentation
    new         Create a new cargo package
    init        Create a new cargo package in an existing directory
    run         Run a binary or example of the local package
    test        Run the tests
    bench       Run the benchmarks
    update      Update dependencies listed in Cargo.lock
    search      Search registry for crates
    publish     Package and upload this package to the registry
    install     Install a Rust binary. Default location is $HOME/.cargo/bin
    uninstall   Uninstall a Rust binary

See 'cargo help <command>' for more information on a specific command.


Interactive help for Wren-cli is currently minimal, just usage and version, viz:

$ wren_cli --help
Usage: wren [file] [arguments...]

Optional arguments:
  --help     Show command line usage
  --version  Show version

$ wren_cli --version
wren 0.3.0


See yabasic.htm for the complete manual, or online.

When invoked as yabasic -help, yabasic -h, or yabasic -? at the command line:
Usage:        yabasic [OPTIONS] [FILENAME [ARGUMENTS]]

FILENAME  : file, which contains the yabasic program; omit it to type
            in your program on the fly (terminated by a double newline)
ARGUMENTS : strings, that are available from within the yabasic program

Available OPTIONS:
   --help                  : print this message
   --version               : show version of yabasic
   -i,--infolevel [dnwefb] : set infolevel to debug,note,warning,error,fatal or bison+flex
   -e,--execute COMMANDS   : execute yabasic COMMANDS right away
   --bind BOUND            : bind interpreter with FILENAME into BOUND
   --geometry x+y          : position graphic window at x,y
   --font FONT             : font for graphic, supply style (decorative,dontcare,
                             modern,roman,script or swiss) and size, e.g. swiss10
   --docu NAME             : print embedded docu of program or library
   --check                 : check for possible compatibility problems
   --librarypath PATH      : directory to search libraries not found in
                             current dir (default d:\program files\yabasic\lib\)
   --                      : pass any subsequent words as arguments to yabasic

---Program done, press RETURN---