Standard/common/popular command-line arg parser?

I used ArgMacros.jl for one of my Julia scripts. But it’s been broken with Julia 1.12.0. The initial bug report was 3 weeks ago (for the pre-release version of 1.12.0). I’m not complaining at all. I just wonder whether this means that very few people are using this package.

So, my question is, is there any standard/common/popular command-line parser? Or, perhaps, there aren’t many people who use command line arguments for their scripts?

If there is no hope of getting a standard command-line parser soon, I’ll just write ad-hoc code to handle command-line args for each script.

As far as I know, ArgParse.jl (which is also mentioned in the topic you link to) is the most popular package for argument parsing. This works without any issues on Julia 1.12.

There’s also SimpleArgParse.jl which I’ve used in the past, but on Julia 1.12 I seem to get (precompilation) errors. (Presumably this is not new in Julia 1.12: GitHub · Where software is built .)

I’ve been using ArgParse.jl, but I’m slightly uncomfortable with it, since I cannot memorize its macro syntax, and I always end up copying and pasting the basic boilerplate when I start writing a new program.

@ryofurue thanks for using ArgMacros! If you are still interested in using it, the Julia 1.12 compatibility is now fixed. Just update to the latest version 0.2.5.

In Julia, there is no such thing as “standard”. Ok, there is the standard library. But even if this functionality were added to the standard library, it would not help with older Julia versions.

So just use the parser library of your choice, and if it has a bug, try to fix it.

And don’t be too fast to use new, major Julia versions. I will wait for Julia 1.12.1 or 1.12.2 before using it.

1 Like

The standard and commonly used command-line argument parsers vary depending on the programming language.