LinuxCommandLibrary
GitHubF-DroidGoogle Play Store

guile

GNU Ubiquitous Intelligent Language for Extensions

TLDR

Start interactive REPL
$ guile
copy
Run a script file
$ guile -s [script.scm]
copy
Evaluate an expression and exit
$ guile -c "(display \"Hello\")"
copy
Load a file then enter interactive REPL
$ guile -l [library.scm] --
copy
Run a script with a specific entry point function
$ guile -e [main] -s [script.scm] [args]
copy
Add a directory to the module load path
$ guile -L [/path/to/modules] -s [script.scm]
copy
Load SRFI extensions
$ guile --use-srfi=[1,13] -s [script.scm]
copy
Start with debugging VM enabled
$ guile --debug [script.scm]
copy

SYNOPSIS

guile [-L directory] [-l file] [-e function] [\\] [-c expr] [-s script] [--] [script] [args]

DESCRIPTION

Guile is the GNU Ubiquitous Intelligent Language for Extensions. It implements the R5RS and R6RS Scheme standards and is used for scripting and extending applications.Guile provides full Scheme functionality plus extensions for practical programming including a module system, POSIX interfaces, networking, and SRFI support. It is designed to be embeddable in C/C++ applications as GNU's official extension language. Source files are automatically compiled to bytecode for faster execution.

PARAMETERS

-s SCRIPT

Load Scheme source from SCRIPT and execute as a script.
-c EXPR
Evaluate EXPR as a Scheme expression and exit.
-l FILE
Load Scheme source code from FILE.
-e FUNCTION
After reading script, apply FUNCTION to command-line arguments.
-L DIRECTORY
Add DIRECTORY to the front of Guile's module load path.
-x EXTENSION
Add EXTENSION to the Guile load extension list.
-ds
Carry out -s SCRIPT at this point in the option sequence (used with -l).
--
Stop argument processing and start Guile in interactive mode.
\\
Meta switch for working around limitations in #! scripts.
--debug
Start with the debugging VM (default in interactive mode).
--no-debug
Start without the debugging VM.
--auto-compile
Compile source files automatically (default).
--no-auto-compile
Disable automatic source file compilation.
--listen[=P]
Listen on port or socket P for remote REPL connections.
--use-srfi=N,M,...
Load SRFI extensions N, M, etc.
-q
Suppress loading the user's initialization file in interactive mode.
-v, --version
Display version information.
-h, --help
Display help information.

CAVEATS

Scheme syntax differs from other Lisps. Extension libraries and APIs may vary between Guile 2.x and 3.x. The GUILELOADPATH and GUILELOADCOMPILED_PATH environment variables control module search paths.

HISTORY

Guile was created by the GNU Project as its official extension language, first released in 1993.

SEE ALSO

scheme(1), racket(1), clisp(1), emacs(1)

Copied to clipboard
Kai