aboutsummaryrefslogtreecommitdiff
path: root/lib/tools
diff options
context:
space:
mode:
Diffstat (limited to 'lib/tools')
-rwxr-xr-xlib/tools/repl.nom7
-rwxr-xr-xlib/tools/replace.nom2
2 files changed, 8 insertions, 1 deletions
diff --git a/lib/tools/repl.nom b/lib/tools/repl.nom
index 029df4a..5e8336f 100755
--- a/lib/tools/repl.nom
+++ b/lib/tools/repl.nom
@@ -70,6 +70,13 @@ command line program with $args:
unless $tree:
do next
+ if ($tree.type == "Comment"):
+ say (dim "Comment:\($tree.1)")
+ do next
+
+ if ($tree.type != "FileChunks"):
+ $tree = [$tree]
+
for $chunk in $tree:
try:
$lua = ($chunk as lua)
diff --git a/lib/tools/replace.nom b/lib/tools/replace.nom
index 7337447..314834e 100755
--- a/lib/tools/replace.nom
+++ b/lib/tools/replace.nom
@@ -107,7 +107,7 @@ command line program with $args:
$matched = {}
$user_answers = {}
($tree with replacements) means
- $tree, map
+ $tree, with
for $t:
$values = ($t matches $pattern_tree with {})
if $values: