Syntax
int getopt_long_only ( string argv, string optstring, string long_options))
Description
getopt_long breaks up command lines for easier parsing. It examines a list of arguments for only long options.
The function works in posixly correct mode and does not reorder arguments. However, if you unset the POSIXLY_CORRECT environment option, it reorders the argv variable as it scans, placing all nonoptions at the end of the list.
Example
while ((option = getopt_long_only(args, "vh",{"verbose","help"})) !=""){
print("Matched option",option);
}