forked from bakpakin/Fennel
-
Notifications
You must be signed in to change notification settings - Fork 0
/
fennel.1
115 lines (106 loc) · 3.21 KB
/
fennel.1
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
.TH FENNEL 1
.SH NAME
fennel \- a lisp programming language that runs on Lua
.SH SYNOPSIS
.B fennel
[\fB--repl\fR] |
[\fB--compile \fIfilename\fR] |
[\fB--eval \fIsource\fR] |
[\fIfilename\fP] [\fIargs ...\fR]
.SH DESCRIPTION
This manual page documents briefly the
.B fennel
command.
.PP
.B fennel
is the main entry point for Fennel, a lisp programming language that
runs on Lua runtimes. With no options or arguments, it runs an
interactive Read-Eval-Print loop (REPL).
.PP
Given a filename as its first argument, it runs that file and passes
it the subsequent arguments. Ahead-of-time compilation can be invoked
with the
.B --compile
flag.
.SH OPTIONS
A summary of options is included below.
.TP
.B \-\-repl
Start an interactive repl session.
.TP
.B \-\-compile \fIfilename\fP
Perform ahead-of-time compilation on the provided file and write the
Lua output to stdout.
.TP
.B \-\-eval \fIsource\fP
Evaluate a piece of source code and print the result.
.TP
.B \-\-no-searcher
When running a repl or a file,
.B fennel.searcher
is installed by default so that the
.B require
function can load Fennel files in addition to Lua files. This flag
disables that behavior. Has no effect for ahead-of-time compilation.
.TP
.B \-\-indent \fIval\fP
When compiling, use the given string as indentation for the compiler
output. This should consist of whitespace.
.TP
.B \-\-add-package-path \fIpath\fP
Add the given path to
.B package.path
so that the
.B require
function will know to look there when searching for Lua modules.
.TP
.B \-\-add-fennel-path \fIpath\fP
Same as above, but for Fennel's path used when searching for Fennel
modules.
.TP
.B \-\-globals \fIVAR1[,VAR2...]\fP
Allow VAR1, VAR2, etc as globals in addition to the standard set of
globals. This enables strict global checking even in ahead-of-time
compilation where it otherwise would be disabled.
.TP
.B \-\-globals-only \fIVAR1[,VAR2...]\fP
Same as above, but without the addition of the standard set of globals.
.TP
.B \-\-require-as-include
Instead of loading required modules at runtime, compile them inline
into the main file being compiled. Only useful during ahead-of-time
compilation.
.TP
.B \-\-use-bit-lib
Compile bitwise operations to use LuaJIT's bitop library instead of Lua
5.3+ bitwise operators.
.TP
.B \-\-load \fIFILE\fP
Load the specified file before any command is run.
.TP
.B \-\-compile-binary \fIFILE\fP \fIOUT\fP \fILUA_LIB\fP \fILUA_DIR\fP
Compile FILE to a standalone binary OUT using LUA_LIB and the Lua
header files in LUA_DIR. See
.B \-\-compile-binary \-\-help
for details.
.TP
.B \-\-no\-compiler\-sandbox
Do not limit compiler environment to minimal sandbox.
.TP
.B \-h, \-\-help
Print a help message and exit
.TP
.B \-v, \-\-version
Print the version number and exit
.SH DOCUMENTATION
See https://fennel-lang.org for documentation on Fennel. The syntax is
based on the lisp family of languages while the semantics are very
close to Lua, so Lua's reference manual is helpful.
.SH COMMUNITY
The mailing list is at https://lists.sr.ht/~technomancy/fennel while
the issue tracker is at https://todo.sr.ht/~technomancy/fennel.
.SH AUTHOR
Calvin Rose and contributors:
https://git.sr.ht/~technomancy/fennel/contributors
.SH LICENSE
Copyright © 2016-2021, Released under the MIT/X11 license