You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have been playing with miller for few days and it is awesome. DSL is so feature rich, complete and user-friendly. Few minor issues and feedback below. Thank you!
❯ {echo "foo,bar";echo "1,2"} | mlr --c2p cat -n
n foo bar
1 1 2
❯ cat ex.mlr
#!/usr/bin/env mlr -s
--c2p
cat -n
❯ {echo "foo,bar";echo "1,2"} | ./ex.mlr
/usr/bin/env: ‘mlr -s’: No such file or directory
/usr/bin/env: use -[v]S to pass options in shebang lines
env does not allow extra arguments to commands.
In newer GNU versions (~ last 5 years), env -S works. But does not work with other variants like alpine env.
Possible fixes
#!/usr/bin/env -S mlr -s
#!/usr/bin/mlr -s
#!mlr -s
Some functions stringify inputs unexpectedly
To check if a field is one of many values, below seem to work
I think it is better to fail when the first argument is an array/map than stringify. Also it may be useful to provide a easy to use function or in operator for checking if a value is one of many. I can see using any is the right way but makes it complicated with higher order function.
I have been playing with
miller
for few days and it is awesome. DSL is so feature rich, complete and user-friendly. Few minor issues and feedback below. Thank you!mlr shebang example is incorrect
env
does not allow extra arguments to commands.In newer GNU versions (~ last 5 years),
env -S
works. But does not work with other variants likealpine
env.Possible fixes
#!/usr/bin/env -S mlr -s
#!/usr/bin/mlr -s
#!mlr -s
Some functions stringify inputs unexpectedly
To check if a field is one of many values, below seem to work
It appears as if
contains
also work with arrays. But it actually stringifies the first argument and can cause surprising errors like belowI think it is better to fail when the first argument is an array/map than stringify. Also it may be useful to provide a easy to use function or
in
operator for checking if a value is one of many. I can see usingany
is the right way but makes it complicated with higher order function.The text was updated successfully, but these errors were encountered: