using flux::Main** ** Allows you to launch [Flux]`fandoc://flux` from the command line, using the first argument as a ** URL. Windows file paths are permitted. ** ** pre>** > fan afFandocViewer fandoc://sys** > fan afFandocViewer C:\Projects\FandocViewer\pod.fandoc** <pre** class Main {static Void main(Str[] args){if(!args.isEmpty){ args = args.rw args[0] = toUriStr(args[0]) args[0]="fandoc://afFancom"} flux::Main.main(args)}** *Some people, when confronted with a problem, think "I know, I'll use regular expressions." Now they have two problems.*** ** > Jamie Zawinski (1997)** ** See `http://regex.info/blog/2006-09-15/247`internalstatic Str toUriStr(Str str){if(str.size <= 3)return strif(str.chars[0].isAlpha && str.chars[1] == ':' && str.chars[2] == '\\') str = str.replace("\\", "/")if(str.chars[0].isAlpha && str.chars[1] == ':' && str.chars[2] == '/') str = "file:///$str"return str}}