mirror of
https://github.com/janet-lang/janet
synced 2024-11-24 09:17:17 +00:00
Add JANET_PATH back in.
This commit is contained in:
parent
732de8f88d
commit
8d9a88e759
11
janet.1
11
janet.1
@ -67,7 +67,7 @@ Quiet output. Don't print a repl prompt or expression results to stdout.
|
||||
.BR \-m\ syspath
|
||||
Set the variable module/*syspath* to the string syspath so that Janet will load system modules
|
||||
from a directory different than the default. The default is set when Janet is built, and defaults to
|
||||
/usr/local/lib/janet on Linux/Posix, and C:/Janet/Library on Windows.
|
||||
/usr/local/lib/janet on Linux/Posix, and C:/Janet/Library on Windows. This option supersedes JANET_PATH.
|
||||
|
||||
.TP
|
||||
.BR \-c\ source\ output
|
||||
@ -86,5 +86,14 @@ or repl.
|
||||
Stop parsing command line arguments. All arguments after this one will be considered file names
|
||||
and then arguments to the script.
|
||||
|
||||
.SH ENVIRONMENT
|
||||
|
||||
.B JANET_PATH
|
||||
.RS
|
||||
The location to look for Janet libraries. This is the only environment variable Janet needs to
|
||||
find native and source code modules. If no JANET_PATH is set, Janet will look in
|
||||
the default location set at compile time.
|
||||
.RE
|
||||
|
||||
.SH AUTHOR
|
||||
Written by Calvin Rose <calsrose@gmail.com>
|
||||
|
@ -9,6 +9,8 @@
|
||||
(var *handleopts* true)
|
||||
(var *exit-on-error* true)
|
||||
|
||||
(if-let [jp (os/getenv "JANET_PATH")] (set module/*syspath* jp))
|
||||
|
||||
# Flag handlers
|
||||
(def handlers :private
|
||||
{"h" (fn [&]
|
||||
|
Loading…
Reference in New Issue
Block a user