FENNEL(1)

πŸ“¦
version 1.6.1 Β· 2 versions
, in alpine 3.24, arch rolling, epel 10, epel 9, fedora 43, fedora 44, nixos 26.05, nixpkgs unstable, ubuntu resolute, ubuntu stonking

πŸ’– FENNEL(1) β€” General Commands Manual πŸ’–

okay bestie, sit down, we're learning fennel πŸ’… this is the section 1 page (general commands, iykyk) and it's literally the whole main-character entry point of the language.


✨ NAME ✨

fennel β€” a lisp programming language that runs on Lua πŸ¦‹


🌸 SYNOPSIS 🌸

fennel [--repl] | [--compile filename] | [--eval source] | [filename]
[args ...]

πŸŽ€ DESCRIPTION πŸŽ€

So this manual page documents the fennel command briefly β€” it's the vibe-check summary, not the whole lore.

fennel is the main entry point for Fennel, which is a lisp programming language that runs on Lua runtimes. And when you run it with no options and no arguments? It just drops you straight into an interactive Read-Eval-Print loop (that's a REPL, babe 🫢).

Give it a filename as the first argument and it runs that file, passing along the arguments that come after it. Want ahead-of-time compilation instead? That's the --compile flag's whole thing. And if you just wanna evaluate a tiny snippet real quick, --eval has you covered ✨


πŸ’… OPTIONS πŸ’…

Here's the summary of your options, queen. Every single one, no skipping πŸ‘‘

  • --repl β€” Start an interactive repl session. This is literally the default when you give it no arguments at all. main character energy, no notes.
  • --compile filename β€” Do ahead-of-time compilation on the file you handed over, and write the Lua output to standard out. AOT girlies rise πŸ™Œ
  • --eval source β€” Evaluate a given piece of source code and print the result.
  • --no-searcher β€” When you're running a repl or a file, fennel.searcher gets installed by default so that the require function can load Fennel files in addition to Lua files. This flag disables that behavior. Heads up: it has no effect for ahead-of-time compilation.
  • --add-package-path path β€” Add the given path to package.path so the require function knows to look there when it's searching for Lua modules.
  • --add-fennel-path path β€” Same as above, but for Fennel's path, the one it uses when searching for Fennel modules.
  • --globals VAR1[,VAR2...] β€” Allow VAR1, VAR2, etc. as globals on top of the standard set of globals. This enables strict global checking even in ahead-of-time compilation, where it otherwise would be disabled. Use "*" to disable globals checking entirely.
  • --globals-only VAR1[,VAR2...] β€” Same as above, but without the inclusion of the standard set of globals.
  • --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, fr fr.
  • --to-be-closed β€” When compiling with-open, use the to-be-closed feature of Lua 5.4+ to avoid interfering with traces.
  • --assert-as-repl β€” Calls to the built-in function assert from Fennel get replaced with calls to assert-repl, so that when the assertion fails, a REPL starts up and you can interactively debug. glow up debugging πŸ’–
  • --lambda-as-fn β€” Replace lambda function definitions with fn, removing the runtime overhead from arity checking.
  • --use-bit-lib β€” Compile bitwise operations to use LuaJIT's bitop library instead of Lua 5.3+ bitwise operators.
  • --load FILE β€” Load the specified FILE before any command is run.
  • --compile-binary FILE OUT LUA_LIB LUA_DIR β€” Compile FILE to a standalone binary OUT using LUA_LIB and the Lua header files in LUA_DIR. See --compile-binary --help for details.
  • --no-compiler-sandbox β€” Do not limit the compiler environment (the one used in macros) to the minimal sandbox. πŸ‘€
  • --keywords KEYWORD1[,KEYWORD2...] β€” Treat these symbols as reserved Lua keywords.
  • -h, --help β€” Print a help message and exit.
  • -v, --version β€” Print the version number and exit.
Pro tip, bestie: use the NO_COLOR environment variable to disable escape codes in error messages. (yes it's shouty-caps, it's a thing, trust 🌈)

πŸ”₯ SEE ALSO πŸ”₯

The semantics are very close to Lua, so Lua's reference manual is also helpful if you want more reading material πŸ“


🌈 COMMUNITY 🌈


πŸ‘‘ AUTHORS πŸ‘‘

Calvin Rose and Phil Hagelberg and contributors: https://github.com/bakpakin/Fennel/graphs/contributors


⭐ LICENSE ⭐

Copyright Β© 2016-2025, Released under the MIT/X11 license


and that's the whole page, babe πŸ¦‹ this was FENNEL(1) from the General Commands Manual β€” go forth, require things, run that repl, and remember: the footer still says FENNEL(1) because that's just how manpages sign off ✨ mwah πŸ’