public static void Main(string [] args)
{
// Parse the command line options
bool show_help = false;
OptionSet option_set = new OptionSet () {
{ "v|version", _("Print version information"), v => { PrintVersion (); } },
{ "h|help", _("Show this help text"), v => show_help = v != null }
};
try {
option_set.Parse (args);
} catch (OptionException e) {
Console.Write ("SparkleShare: ");
Console.WriteLine (e.Message);
Console.WriteLine ("Try `sparkleshare --help' for more information.");
}
if (show_help)
ShowHelp (option_set);
// Initialize the controller this way so that
// there aren't any exceptions in the OS specific UI's
Controller = new SparkleController ();
Controller.Initialize ();
if (Controller != null) {
UI = new SparkleUI ();
UI.Run ();
}
}