top level functions for easy jbang one liners #1289
Unanswered
maxandersen
asked this question in
Ideas
Replies: 2 comments 3 replies
-
I find Perhaps we can do something similar to Another option would be to create toplevel methods |
Beta Was this translation helpful? Give feedback.
3 replies
-
Also something to say "give me all lines" as lines() in itself can be too verbose:
|
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Been playing with jbang -c lately and seen some constructs that could be easier.
simple repeat
Having to do foreach is verbose IntStream.range() kinda works:
But maybe we should have
times(int)
method akin groovy5.times(lambda)
:Argument parsing
Passing arguments to a oneline is tedious:
Maybe make a
iargs(pos)
as shorthand:others ?
Beta Was this translation helpful? Give feedback.
All reactions