How can I expand wildcard commandline arguments in Julia?
The shell doesn't seem to expand them before they get there.
If I call my script as julia script.jl *.dat
, my output is just *.dat
for arg in ARGS
println(arg)
end
If I write the equivalent program in Java:
public class rejig {
public static void main(String[] args) throws Exception {
for(int i = 0; i < args.length; i++) {
System.out.println(args[i]);
}
}
}
and call it as java rejig *.dat
, I get a listing of all the DAT files in the current directory.
My searching along the lines of "command line", "wildcards", and the like hasn't got me very far.
How do I get Julia to give the same output as the Java code?