private static PackageExporterArguments ParseCommandLineArguments() { PackageExporterArguments arguments = new PackageExporterArguments(); // Redirect Console.Error output to Unity Console.SetError(new UnityDebugLogErrorWriter()); Parser.Default.ParseArguments(Environment.GetCommandLineArgs(), arguments); // Unset console output Console.SetError(TextWriter.Null); return(arguments); }
public static void Export() { PackageExporterArguments args = ParseCommandLineArguments(); try { Export(args.Config); } catch (Exception ex) { Debug.LogError(ex); if (Application.isBatchMode) { EditorApplication.Exit(1); } } }
public static void Export() { PackageExporterArguments args = ParseCommandLineArguments(); Export(args.Config); }