1
0
mirror of https://github.com/janet-lang/janet synced 2024-11-18 14:44:48 +00:00

Merge pull request #1012 from Techcable/doc/clarify-flag-E

Clarify the documentation of janet -E flag
This commit is contained in:
Calvin Rose 2022-08-21 13:45:17 -05:00 committed by GitHub
commit 6dcf5bf077
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -164,10 +164,15 @@ Execute a string of Janet source. Source code is executed in the order it is enc
arguments are executed before later ones.
.TP
.BR \-E\ code arguments
.BR \-E\ code\ arguments...
Execute a single Janet expression as a Janet short-fn, passing the remaining command line arguments to the expression. This allows
more concise one-liners with command line arguments.
Example: janet -E '(print $0)' 12 is equivalent to '((short-fn (print $0)) 12)', which is in turn equivalent to
`((fn [k] (print k)) 12)`
See docs for the `short-fn` function for more details.
.TP
.BR \-d
Enable debug mode. On all terminating signals as well the debug signal, this will