I'm a newbie in Crystal lang, and I just wanted to know how to get a list (array) of command-line arguments in Crystal. I am aware that there's OptionParser
. But I just want to get a list of arguments users typed in.
Asked
Active
Viewed 250 times
4

bichanna
- 954
- 2
- 21
2 Answers
4
ARGV
is a Top Level Constant that contains all command line arguments.
Documentation can be found here: https://crystal-lang.org/api/1.3.2/toplevel.html

grepsedawk
- 3,324
- 2
- 26
- 49