Ejemplo n.º 1
0
    public static int Main(string[] args)
    {
        string?source      = null;
        string?destination = null;
        bool   isUnix      = false;

        var options = new OptionSet()
        {
            { "source=", "Path to binaries", (string s) => source = s },
            { "destination=", "Output path", (string s) => destination = s },
            {
                "unix",
                "If true, prepares tests for unix environment instead of Windows",
                o => isUnix = o is object
            }
        };

        options.Parse(args);

        if (source is null)
        {
            Console.Error.WriteLine("--source argument must be provided");
            return(ExitFailure);
        }

        if (destination is null)
        {
            Console.Error.WriteLine("--destination argument must be provided");
            return(ExitFailure);
        }

        MinimizeUtil.Run(source, destination, isUnix);
        return(ExitSuccess);
    }
Ejemplo n.º 2
0
    public static int Main(string[] args)
    {
        if (args.Length != 2)
        {
            Console.WriteLine("preparetests <path to binaries> <output path>");
            return(ExitFailure);
        }

        MinimizeUtil.Run(args[0], args[1]);
        return(ExitSuccess);
    }