Skip to content

Commit d50d6fa

Browse files
committed
update readme to document nimib's define flags
1 parent bb9dc90 commit d50d6fa

File tree

2 files changed

+14
-2
lines changed

2 files changed

+14
-2
lines changed

README.md

+7-1
Original file line numberDiff line numberDiff line change
@@ -257,6 +257,13 @@ Nimib options:
257257
The value of options are available in `nb.options` field which also
258258
tracks further options in `nb.options.other: seq[tuple[kind: CmdLineKind; name, value: string]]`.
259259

260+
### define flags
261+
262+
nimib's behavior can be further turned via Nim's define flags:
263+
264+
* `-d:nimibNoLog`: Completely disables nimib's logging to stdout
265+
* `-d:nimibCodeFromAst`: Makes nimib capture block code from AST of body (as opposed to from file source; see next section). Available since version 0.3
266+
260267
### Code capture
261268

262269
The code capture of a block like `nbCode` (or other custom blocks)
@@ -268,7 +275,6 @@ can happen in two different ways:
268275
is rendered from AST of body. This means that only documentation comments
269276
are shown (since normal comments are not part of the AST) and that the source show
270277
might be different from original source.
271-
Since version 0.3 this is available through compile time switch `nimibCodeFromAst`.
272278

273279
## 🐝 API <!-- Api means bees in Italian -->
274280

docsrc/index.nim

+7-1
Original file line numberDiff line numberDiff line change
@@ -220,6 +220,13 @@ nbText: hlMdF"""
220220
The value of options are available in `nb.options` field which also
221221
tracks further options in `nb.options.other: seq[tuple[kind: CmdLineKind; name, value: string]]`.
222222
223+
### define flags
224+
225+
nimib's behavior can be further turned via Nim's define flags:
226+
227+
* `-d:nimibNoLog`: Completely disables nimib's logging to stdout
228+
* `-d:nimibCodeFromAst`: Makes nimib capture block code from AST of body (as opposed to from file source; see next section). Available since version 0.3
229+
223230
### Code capture
224231
225232
The code capture of a block like `nbCode` (or other custom blocks)
@@ -231,7 +238,6 @@ can happen in two different ways:
231238
is rendered from AST of body. This means that only documentation comments
232239
are shown (since normal comments are not part of the AST) and that the source show
233240
might be different from original source.
234-
Since version 0.3 this is available through compile time switch `nimibCodeFromAst`.
235241
236242
## :honeybee: API <!-- Api means bees in Italian -->
237243

0 commit comments

Comments
 (0)