[
  {
    "path": ".gitignore",
    "content": ".vs\nbin\nobj\nDebug\nRelease\n*.DotSettings\n*.user\n*.suo\npackages"
  },
  {
    "path": "Brenner.SilentCmd/ArgumentParser.cs",
    "content": "﻿using System.Globalization;\n\nnamespace Brenner.SilentCmd\n{\n    public static class ArgumentParser\n    {\n        public static bool IsName(string arg, string name)\n        {\n            return arg.StartsWith(name, true, CultureInfo.InvariantCulture) &&\n                (name.Length == arg.Length || arg[name.Length] == ':');\n        }\n\n        public static bool TryGetValue(string arg, string name, out string value)\n        {\n            if (IsName(arg, name))\n            {\n                int startPosition = name.Length + 1;   // +1 because of colon separator\n                value = arg.Substring(startPosition).Trim('\"');\n                return true;\n            }\n\n            value = null;\n            return false;\n        }\n\n    }\n}\n"
  },
  {
    "path": "Brenner.SilentCmd/Brenner.SilentCmd.csproj",
    "content": "﻿<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<Project ToolsVersion=\"12.0\" DefaultTargets=\"Build\" xmlns=\"http://schemas.microsoft.com/developer/msbuild/2003\">\n  <PropertyGroup>\n    <Configuration Condition=\" '$(Configuration)' == '' \">Debug</Configuration>\n    <Platform Condition=\" '$(Platform)' == '' \">x86</Platform>\n    <ProductVersion>8.0.30703</ProductVersion>\n    <SchemaVersion>2.0</SchemaVersion>\n    <ProjectGuid>{461E6475-6450-40ED-B68C-7F012701E6C6}</ProjectGuid>\n    <OutputType>WinExe</OutputType>\n    <AppDesignerFolder>Properties</AppDesignerFolder>\n    <RootNamespace>Brenner.SilentCmd</RootNamespace>\n    <AssemblyName>SilentCMD</AssemblyName>\n    <TargetFrameworkVersion>v4.8</TargetFrameworkVersion>\n    <TargetFrameworkProfile>\n    </TargetFrameworkProfile>\n    <FileAlignment>512</FileAlignment>\n    <PublishUrl>publish\\</PublishUrl>\n    <Install>true</Install>\n    <InstallFrom>Disk</InstallFrom>\n    <UpdateEnabled>false</UpdateEnabled>\n    <UpdateMode>Foreground</UpdateMode>\n    <UpdateInterval>7</UpdateInterval>\n    <UpdateIntervalUnits>Days</UpdateIntervalUnits>\n    <UpdatePeriodically>false</UpdatePeriodically>\n    <UpdateRequired>false</UpdateRequired>\n    <MapFileExtensions>true</MapFileExtensions>\n    <ApplicationRevision>0</ApplicationRevision>\n    <ApplicationVersion>1.5.0.%2a</ApplicationVersion>\n    <IsWebBootstrapper>false</IsWebBootstrapper>\n    <UseApplicationTrust>false</UseApplicationTrust>\n    <BootstrapperEnabled>true</BootstrapperEnabled>\n  </PropertyGroup>\n  <PropertyGroup Condition=\"'$(Configuration)|$(Platform)' == 'Debug|AnyCPU'\">\n    <DebugSymbols>true</DebugSymbols>\n    <OutputPath>bin\\Debug\\</OutputPath>\n    <DefineConstants>DEBUG;TRACE</DefineConstants>\n    <DebugType>full</DebugType>\n    <PlatformTarget>AnyCPU</PlatformTarget>\n    <CodeAnalysisLogFile>bin\\Debug\\SilentCMD.exe.CodeAnalysisLog.xml</CodeAnalysisLogFile>\n    <CodeAnalysisUseTypeNameInSuppression>true</CodeAnalysisUseTypeNameInSuppression>\n    <CodeAnalysisModuleSuppressionsFile>GlobalSuppressions.cs</CodeAnalysisModuleSuppressionsFile>\n    <ErrorReport>prompt</ErrorReport>\n    <CodeAnalysisRuleSet>MinimumRecommendedRules.ruleset</CodeAnalysisRuleSet>\n    <CodeAnalysisRuleSetDirectories>;C:\\Program Files (x86)\\Microsoft Visual Studio 10.0\\Team Tools\\Static Analysis Tools\\\\Rule Sets</CodeAnalysisRuleSetDirectories>\n    <CodeAnalysisRuleDirectories>;C:\\Program Files (x86)\\Microsoft Visual Studio 10.0\\Team Tools\\Static Analysis Tools\\FxCop\\\\Rules</CodeAnalysisRuleDirectories>\n    <Prefer32Bit>false</Prefer32Bit>\n  </PropertyGroup>\n  <PropertyGroup Condition=\"'$(Configuration)|$(Platform)' == 'Release|AnyCPU'\">\n    <OutputPath>bin\\Release\\</OutputPath>\n    <DefineConstants>TRACE</DefineConstants>\n    <Optimize>true</Optimize>\n    <TreatWarningsAsErrors>true</TreatWarningsAsErrors>\n    <DebugType>pdbonly</DebugType>\n    <PlatformTarget>AnyCPU</PlatformTarget>\n    <CodeAnalysisLogFile>bin\\Release\\SilentCMD.exe.CodeAnalysisLog.xml</CodeAnalysisLogFile>\n    <CodeAnalysisUseTypeNameInSuppression>true</CodeAnalysisUseTypeNameInSuppression>\n    <CodeAnalysisModuleSuppressionsFile>GlobalSuppressions.cs</CodeAnalysisModuleSuppressionsFile>\n    <ErrorReport>prompt</ErrorReport>\n    <CodeAnalysisRuleSet>MinimumRecommendedRules.ruleset</CodeAnalysisRuleSet>\n    <CodeAnalysisRuleSetDirectories>;C:\\Program Files (x86)\\Microsoft Visual Studio 10.0\\Team Tools\\Static Analysis Tools\\\\Rule Sets</CodeAnalysisRuleSetDirectories>\n    <CodeAnalysisIgnoreBuiltInRuleSets>false</CodeAnalysisIgnoreBuiltInRuleSets>\n    <CodeAnalysisRuleDirectories>;C:\\Program Files (x86)\\Microsoft Visual Studio 10.0\\Team Tools\\Static Analysis Tools\\FxCop\\\\Rules</CodeAnalysisRuleDirectories>\n    <Prefer32Bit>false</Prefer32Bit>\n  </PropertyGroup>\n  <ItemGroup>\n    <Reference Include=\"System\" />\n    <Reference Include=\"System.Data\" />\n    <Reference Include=\"System.Deployment\" />\n    <Reference Include=\"System.Drawing\" />\n    <Reference Include=\"System.Windows.Forms\" />\n    <Reference Include=\"System.Xml\" />\n  </ItemGroup>\n  <ItemGroup>\n    <Compile Include=\"ArgumentParser.cs\" />\n    <Compile Include=\"Configuration.cs\" />\n    <Compile Include=\"Engine.cs\" />\n    <Compile Include=\"LogWriter.cs\" />\n    <Compile Include=\"Program.cs\" />\n    <Compile Include=\"Properties\\AssemblyInfo.cs\" />\n    <EmbeddedResource Include=\"Properties\\Resources.resx\">\n      <Generator>ResXFileCodeGenerator</Generator>\n      <LastGenOutput>Resources.Designer.cs</LastGenOutput>\n      <SubType>Designer</SubType>\n    </EmbeddedResource>\n    <Compile Include=\"Properties\\Resources.Designer.cs\">\n      <AutoGen>True</AutoGen>\n      <DependentUpon>Resources.resx</DependentUpon>\n      <DesignTime>True</DesignTime>\n    </Compile>\n    <None Include=\"app.config\">\n      <SubType>Designer</SubType>\n    </None>\n    <None Include=\"Properties\\Settings.settings\">\n      <Generator>SettingsSingleFileGenerator</Generator>\n      <LastGenOutput>Settings.Designer.cs</LastGenOutput>\n    </None>\n    <Compile Include=\"Properties\\Settings.Designer.cs\">\n      <AutoGen>True</AutoGen>\n      <DependentUpon>Settings.settings</DependentUpon>\n      <DesignTimeSharedInput>True</DesignTimeSharedInput>\n    </Compile>\n  </ItemGroup>\n  <ItemGroup>\n    <BootstrapperPackage Include=\".NETFramework,Version=v4.8\">\n      <Visible>False</Visible>\n      <ProductName>Microsoft .NET Framework 4.8 %28x86 and x64%29</ProductName>\n      <Install>true</Install>\n    </BootstrapperPackage>\n    <BootstrapperPackage Include=\"Microsoft.Net.Framework.3.5.SP1\">\n      <Visible>False</Visible>\n      <ProductName>.NET Framework 3.5 SP1</ProductName>\n      <Install>false</Install>\n    </BootstrapperPackage>\n  </ItemGroup>\n  <Import Project=\"$(MSBuildToolsPath)\\Microsoft.CSharp.targets\" />\n  <!-- To modify your build process, add your task inside one of the targets below and uncomment it. \n       Other similar extension points exist, see Microsoft.Common.targets.\n  <Target Name=\"BeforeBuild\">\n  </Target>\n  <Target Name=\"AfterBuild\">\n  </Target>\n  -->\n</Project>"
  },
  {
    "path": "Brenner.SilentCmd/Configuration.cs",
    "content": "﻿using Brenner.SilentCmd.Properties;\nusing System;\nusing System.Collections.Generic;\nusing System.Globalization;\nusing System.Text;\n\nnamespace Brenner.SilentCmd\n{\n    public class Configuration\n    {\n        public bool LogAppend { get; private set; }\n        public string LogFilePath { get; private set; }\n        public long MaxLogSize { get; private set; }\n        public string BatchFilePath { get; set; }\n        public string BatchFileArguments { get; private set; }\n        public TimeSpan Delay { get; private set; }\n        public bool ShowHelp { get; private set; }\n\n        public Configuration()\n        {\n            LogAppend = Settings.Default.DefaultLogAppend;\n            LogFilePath = Settings.Default.DefaultLogFilePath;\n            MaxLogSize = Settings.Default.DefaultLogSize;\n            BatchFilePath = Settings.Default.DefaultBatchFilePath;\n            BatchFileArguments = Settings.Default.DefaultBatchFileArguments;\n            Delay = Settings.Default.DefaultDelay;\n        }\n\n        public void ParseArguments(IEnumerable<string> args)\n        {\n            var argumentsBuilder = new StringBuilder();\n            var batchFilePathWasRead = false;\n            string argValue;\n\n            foreach (string arg in args)\n            {\n                if (ArgumentParser.TryGetValue(arg, \"/LOG+\", out argValue))\n                {\n                    LogAppend = true;\n                    LogFilePath = argValue;\n                    continue;\n                }\n\n                if (ArgumentParser.TryGetValue(arg, \"/LOG\", out argValue))\n                {\n                    LogAppend = false;\n                    LogFilePath = argValue;\n                    continue;\n                }\n\n                if (ArgumentParser.TryGetValue(arg, \"/LOGSIZE\", out argValue))\n                {\n                    MaxLogSize = Convert.ToInt64(argValue);\n                    continue;\n                }\n\n                if (ArgumentParser.TryGetValue(arg, \"/DELAY\", out argValue))\n                {\n                    Delay = TimeSpan.FromSeconds(Convert.ToDouble(argValue));\n                    continue;\n                }\n\n                if (ArgumentParser.IsName(arg, \"/?\"))\n                {\n                    ShowHelp = true;\n                }\n\n                if (!batchFilePathWasRead)\n                {\n                    BatchFilePath = arg;\n                    batchFilePathWasRead = true;\n                    continue;\n                }\n\n                if (arg.Contains(\" \"))\n                {\n                    argumentsBuilder.AppendFormat(\"\\\"{0}\\\" \", arg);\n                    continue;\n                }\n\n                argumentsBuilder.AppendFormat(\"{0} \", arg);\n            }\n\n            if (argumentsBuilder.Length > 0)\n            {\n                BatchFileArguments = argumentsBuilder.ToString();\n            }\n        }\n    }\n}\n"
  },
  {
    "path": "Brenner.SilentCmd/Engine.cs",
    "content": "﻿using System;\nusing System.Diagnostics;\nusing System.Reflection;\nusing System.Windows.Forms;\nusing Brenner.SilentCmd.Properties;\nusing System.IO;\nusing System.Linq;\nusing System.Threading;\n\nnamespace Brenner.SilentCmd\n{\n    internal class Engine\n    {\n        private Configuration _config = new Configuration();\n        private readonly LogWriter _logWriter = new LogWriter();\n        \n        /// <summary>\n        /// Executes the batch file defined in the arguments\n        /// </summary>\n        public int Execute(string[] args)\n        {\n            try\n            {\n                _config.ParseArguments(args);\n                _logWriter.Initialize(_config.LogFilePath, _config.LogAppend, _config.MaxLogSize);\n\n                if (_config.ShowHelp)\n                {\n                    ShowHelp();\n                    return 0;\n                }\n\n                DelayIfNecessary();\n                ResolveBatchFilePath();\n\n                using (var process = new Process())\n                {\n                    process.StartInfo = new ProcessStartInfo(_config.BatchFilePath, _config.BatchFileArguments)\n                    {\n                        RedirectStandardOutput = true,\n                        RedirectStandardError = true,\n                        UseShellExecute = false,   // CreateNoWindow only works, if shell is not used\n                        CreateNoWindow = true\n                    };\n\n                    process.OutputDataReceived += OutputHandler;\n                    process.ErrorDataReceived += OutputHandler;\n                    process.Start();\n                    _logWriter.WriteLine(Resources.StartingCommand, _config.BatchFilePath, process.Id);\n\n                    process.BeginOutputReadLine();\n                    process.WaitForExit();\n                    return process.ExitCode;\n                }\n            }\n            catch (Exception e)\n            {\n                _logWriter.WriteLine(Resources.Error, e.Message);\n                return 1;\n            }\n            finally\n            {\n                _logWriter.WriteLine(Resources.FinishedCommand, _config.BatchFilePath);\n                _logWriter.Dispose();                \n            }\n        }\n\n        private void DelayIfNecessary()\n        {\n            if (_config.Delay <= TimeSpan.FromSeconds(0)) return;\n\n            _logWriter.WriteLine(Resources.Delay, _config.Delay.TotalSeconds);\n            Thread.Sleep(_config.Delay);\n        }\n\n        private static void ShowHelp()\n        {\n            Assembly assembly = Assembly.GetExecutingAssembly();\n            AssemblyName name = assembly.GetName();\n            string userManual = string.Format(Resources.UserManual, name.Version);\n            MessageBox.Show(userManual, Resources.ProgramTitle);\n        }\n\n        private void ResolveBatchFilePath()\n        {\n            if (string.IsNullOrEmpty(_config.BatchFilePath)) return;\n\n            if (!string.IsNullOrEmpty(Path.GetDirectoryName(_config.BatchFilePath))) return;\n\n            if (string.IsNullOrEmpty(Path.GetExtension(_config.BatchFilePath)))\n            {\n                if (FindPath(_config.BatchFilePath + \".bat\")) return;\n                FindPath(_config.BatchFilePath + \".cmd\");\n            }\n            else\n            {\n                FindPath(_config.BatchFilePath);\n            }\n        }\n\n        /// <returns>True if file was found</returns>\n        private bool FindPath(string filename)\n        {\n            string currentPath = Path.Combine(Environment.CurrentDirectory, filename);\n            if (File.Exists(currentPath)) return true;\n\n            var enviromentPath = System.Environment.GetEnvironmentVariable(\"PATH\");\n\n            var paths = enviromentPath.Split(';');\n            var fullPath = paths.Select(x => Path.Combine(x, filename))\n                               .Where(x => File.Exists(x))\n                               .FirstOrDefault();\n\n            if (!string.IsNullOrEmpty(fullPath))\n            {\n                _config.BatchFilePath = fullPath;\n                return true;\n            }\n\n            return false;\n        }\n\n        private void OutputHandler(object sender, DataReceivedEventArgs e)\n        {\n            _logWriter.WriteLine(e.Data);\n        }\n    }\n}\n"
  },
  {
    "path": "Brenner.SilentCmd/LogWriter.cs",
    "content": "﻿using System;\nusing System.Diagnostics;\nusing System.IO;\n\nnamespace Brenner.SilentCmd\n{\n    internal class LogWriter : IDisposable\n    {\n        private string _fullPath;\n        private StreamWriter _writer;\n        private long _maxSize;\n        private bool _append;\n\n        public bool Initialized { get { return _writer != null; } }\n\n        /// <summary>\n        /// Initializies a log writer that logs to the specified path.\n        /// </summary>\n        /// <param name=\"logPath\">Path to the destination log file.</param>\n        /// <param name=\"append\">True if entrie should be added to an existing log file</param>\n        public void Initialize(string logPath = null, bool append = false, long maxSize = 0)\n        {\n            try\n            {\n                if (string.IsNullOrEmpty(logPath)) return;   // No logging if no path specified\n                _fullPath = Environment.ExpandEnvironmentVariables(logPath);\n\n                _append = append;\n                _maxSize = maxSize;\n\n                if (_writer != null) _writer.Dispose();\n                _writer = new StreamWriter(_fullPath, _append);\n            }\n            catch (Exception e)\n            {\n                Trace.WriteLine(e);\n            }            \n        }\n\n        private void RotateLogFile()\n        {\n            try\n            {\n                if (_maxSize <= 0) return;   // Ignore if no max size specified\n\n                if (_writer != null && _writer.BaseStream != null && _writer.BaseStream.Length > _maxSize)\n                {\n                    _writer.Dispose();\n                    File.Copy(_fullPath, _fullPath + \".old\", true);\n                    File.Delete(_fullPath);\n                    _writer = new StreamWriter(_fullPath, _append);\n                }\n            }\n            catch (Exception e)\n            {\n                Trace.WriteLine(e);\n            }\n        }\n\n        public void Dispose()\n        {\n            try\n            {\n                if (_writer != null)\n                {\n                    _writer.Dispose();\n                }\n            }\n            catch (Exception e)\n            {\n                Trace.WriteLine(e);\n            }\n            GC.SuppressFinalize(this);\n        }\n\n        public void WriteLine(string format, params object[] args)\n        {\n            try\n            {\n                RotateLogFile();\n\n                if (_writer != null && format != null)\n                {\n                    string message = string.Format(format, args);\n                    string timestamp = DateTime.Now.ToString(\"yyyy-MM-dd HH:mm:ss.fff\");\n                    _writer.WriteLine(\"{0} - {1}\", timestamp, message);\n                }\n            }\n            catch (Exception e)\n            {\n                Trace.WriteLine(e);\n            }\n        }\n    }\n}\n"
  },
  {
    "path": "Brenner.SilentCmd/Program.cs",
    "content": "﻿using System;\n\nnamespace Brenner.SilentCmd\n{\n    public static class Program\n    {\n        /// <summary>\n        /// The main entry point for the application.\n        /// </summary>\n        [STAThread]\n        public static int Main(string[] args)\n        {\n            var engine = new Engine();\n            return engine.Execute(args);\n        }\n    }\n}\n"
  },
  {
    "path": "Brenner.SilentCmd/Properties/AssemblyInfo.cs",
    "content": "﻿using System.Reflection;\nusing System.Runtime.InteropServices;\n\n// General Information about an assembly is controlled through the following \n// set of attributes. Change these attribute values to modify the information\n// associated with an assembly.\n[assembly: AssemblyTitle(\"SilentCMD\")]\n[assembly: AssemblyDescription(\"\")]\n[assembly: AssemblyConfiguration(\"\")]\n[assembly: AssemblyCompany(\"Stephan Brenner\")]\n[assembly: AssemblyProduct(\"SilentCMD\")]\n[assembly: AssemblyCopyright(\"Copyright © 2011-2025 Stephan Brenner\")]\n[assembly: AssemblyTrademark(\"\")]\n[assembly: AssemblyCulture(\"\")]\n\n// Setting ComVisible to false makes the types in this assembly not visible \n// to COM components.  If you need to access a type in this assembly from \n// COM, set the ComVisible attribute to true on that type.\n[assembly: ComVisible(false)]\n\n// The following GUID is for the ID of the typelib if this project is exposed to COM\n[assembly: Guid(\"57e768d9-0964-47e5-ad1c-201a6b296cb2\")]\n\n// Version information for an assembly consists of the following four values:\n//\n//      Major Version\n//      Minor Version \n//      Build Number\n//      Revision\n//\n// You can specify all the values or you can default the Build and Revision Numbers \n// by using the '*' as shown below:\n// [assembly: AssemblyVersion(\"1.0.*\")]\n[assembly: AssemblyVersion(\"1.5.0.0\")]\n[assembly: AssemblyFileVersion(\"1.5.0.0\")]\n"
  },
  {
    "path": "Brenner.SilentCmd/Properties/Resources.Designer.cs",
    "content": "﻿//------------------------------------------------------------------------------\n// <auto-generated>\n//     This code was generated by a tool.\n//     Runtime Version:4.0.30319.42000\n//\n//     Changes to this file may cause incorrect behavior and will be lost if\n//     the code is regenerated.\n// </auto-generated>\n//------------------------------------------------------------------------------\n\nnamespace Brenner.SilentCmd.Properties {\n    using System;\n    \n    \n    /// <summary>\n    ///   A strongly-typed resource class, for looking up localized strings, etc.\n    /// </summary>\n    // This class was auto-generated by the StronglyTypedResourceBuilder\n    // class via a tool like ResGen or Visual Studio.\n    // To add or remove a member, edit your .ResX file then rerun ResGen\n    // with the /str option, or rebuild your VS project.\n    [global::System.CodeDom.Compiler.GeneratedCodeAttribute(\"System.Resources.Tools.StronglyTypedResourceBuilder\", \"18.0.0.0\")]\n    [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]\n    [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]\n    internal class Resources {\n        \n        private static global::System.Resources.ResourceManager resourceMan;\n        \n        private static global::System.Globalization.CultureInfo resourceCulture;\n        \n        [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute(\"Microsoft.Performance\", \"CA1811:AvoidUncalledPrivateCode\")]\n        internal Resources() {\n        }\n        \n        /// <summary>\n        ///   Returns the cached ResourceManager instance used by this class.\n        /// </summary>\n        [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]\n        internal static global::System.Resources.ResourceManager ResourceManager {\n            get {\n                if (object.ReferenceEquals(resourceMan, null)) {\n                    global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager(\"Brenner.SilentCmd.Properties.Resources\", typeof(Resources).Assembly);\n                    resourceMan = temp;\n                }\n                return resourceMan;\n            }\n        }\n        \n        /// <summary>\n        ///   Overrides the current thread's CurrentUICulture property for all\n        ///   resource lookups using this strongly typed resource class.\n        /// </summary>\n        [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]\n        internal static global::System.Globalization.CultureInfo Culture {\n            get {\n                return resourceCulture;\n            }\n            set {\n                resourceCulture = value;\n            }\n        }\n        \n        /// <summary>\n        ///   Looks up a localized string similar to Delaying execution by {0} seconds.\n        /// </summary>\n        internal static string Delay {\n            get {\n                return ResourceManager.GetString(\"Delay\", resourceCulture);\n            }\n        }\n        \n        /// <summary>\n        ///   Looks up a localized string similar to Error: {0}.\n        /// </summary>\n        internal static string Error {\n            get {\n                return ResourceManager.GetString(\"Error\", resourceCulture);\n            }\n        }\n        \n        /// <summary>\n        ///   Looks up a localized string similar to Finished &quot;{0}&quot;.\n        /// </summary>\n        internal static string FinishedCommand {\n            get {\n                return ResourceManager.GetString(\"FinishedCommand\", resourceCulture);\n            }\n        }\n        \n        /// <summary>\n        ///   Looks up a localized string similar to SilentCMD.\n        /// </summary>\n        internal static string ProgramTitle {\n            get {\n                return ResourceManager.GetString(\"ProgramTitle\", resourceCulture);\n            }\n        }\n        \n        /// <summary>\n        ///   Looks up a localized string similar to Started &quot;{0}&quot; (PID {1}).\n        /// </summary>\n        internal static string StartingCommand {\n            get {\n                return ResourceManager.GetString(\"StartingCommand\", resourceCulture);\n            }\n        }\n        \n        /// <summary>\n        ///   Looks up a localized string similar to SilentCMD [Options] BatchFile [BatchArguments]\n        ///\n        ///Options:\n        ////? :: Show help\n        ////LOG:file :: Output status to log file (overwrite existing log).\n        ////LOG+:file :: Output status to log file (append to existing log).\n        ////LOGSIZE:bytes :: Maximum log file size after which it is truncated\n        ////DELAY:seconds :: Delay the execution of batch file by x seconds\n        ///\n        ///Examples\n        ///SilentCMD c:\\DoSomething.bat\n        ///SilentCMD /LOG:c:\\MyLog.txt c:\\MyBatch.cmd MyParam1\n        ///SilentCMD /LOG+:c:\\MyLog.txt /LOGSIZE:1000000 c:\\MyBatch.cmd\n        ///SilentCMD  [rest of string was truncated]&quot;;.\n        /// </summary>\n        internal static string UserManual {\n            get {\n                return ResourceManager.GetString(\"UserManual\", resourceCulture);\n            }\n        }\n    }\n}\n"
  },
  {
    "path": "Brenner.SilentCmd/Properties/Resources.resx",
    "content": "﻿<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<root>\n  <!-- \n    Microsoft ResX Schema \n    \n    Version 2.0\n    \n    The primary goals of this format is to allow a simple XML format \n    that is mostly human readable. The generation and parsing of the \n    various data types are done through the TypeConverter classes \n    associated with the data types.\n    \n    Example:\n    \n    ... ado.net/XML headers & schema ...\n    <resheader name=\"resmimetype\">text/microsoft-resx</resheader>\n    <resheader name=\"version\">2.0</resheader>\n    <resheader name=\"reader\">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>\n    <resheader name=\"writer\">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>\n    <data name=\"Name1\"><value>this is my long string</value><comment>this is a comment</comment></data>\n    <data name=\"Color1\" type=\"System.Drawing.Color, System.Drawing\">Blue</data>\n    <data name=\"Bitmap1\" mimetype=\"application/x-microsoft.net.object.binary.base64\">\n        <value>[base64 mime encoded serialized .NET Framework object]</value>\n    </data>\n    <data name=\"Icon1\" type=\"System.Drawing.Icon, System.Drawing\" mimetype=\"application/x-microsoft.net.object.bytearray.base64\">\n        <value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>\n        <comment>This is a comment</comment>\n    </data>\n                \n    There are any number of \"resheader\" rows that contain simple \n    name/value pairs.\n    \n    Each data row contains a name, and value. The row also contains a \n    type or mimetype. Type corresponds to a .NET class that support \n    text/value conversion through the TypeConverter architecture. \n    Classes that don't support this are serialized and stored with the \n    mimetype set.\n    \n    The mimetype is used for serialized objects, and tells the \n    ResXResourceReader how to depersist the object. This is currently not \n    extensible. For a given mimetype the value must be set accordingly:\n    \n    Note - application/x-microsoft.net.object.binary.base64 is the format \n    that the ResXResourceWriter will generate, however the reader can \n    read any of the formats listed below.\n    \n    mimetype: application/x-microsoft.net.object.binary.base64\n    value   : The object must be serialized with \n            : System.Runtime.Serialization.Formatters.Binary.BinaryFormatter\n            : and then encoded with base64 encoding.\n    \n    mimetype: application/x-microsoft.net.object.soap.base64\n    value   : The object must be serialized with \n            : System.Runtime.Serialization.Formatters.Soap.SoapFormatter\n            : and then encoded with base64 encoding.\n\n    mimetype: application/x-microsoft.net.object.bytearray.base64\n    value   : The object must be serialized into a byte array \n            : using a System.ComponentModel.TypeConverter\n            : and then encoded with base64 encoding.\n    -->\n  <xsd:schema id=\"root\" xmlns=\"\" xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\" xmlns:msdata=\"urn:schemas-microsoft-com:xml-msdata\">\n    <xsd:import namespace=\"http://www.w3.org/XML/1998/namespace\" />\n    <xsd:element name=\"root\" msdata:IsDataSet=\"true\">\n      <xsd:complexType>\n        <xsd:choice maxOccurs=\"unbounded\">\n          <xsd:element name=\"metadata\">\n            <xsd:complexType>\n              <xsd:sequence>\n                <xsd:element name=\"value\" type=\"xsd:string\" minOccurs=\"0\" />\n              </xsd:sequence>\n              <xsd:attribute name=\"name\" use=\"required\" type=\"xsd:string\" />\n              <xsd:attribute name=\"type\" type=\"xsd:string\" />\n              <xsd:attribute name=\"mimetype\" type=\"xsd:string\" />\n              <xsd:attribute ref=\"xml:space\" />\n            </xsd:complexType>\n          </xsd:element>\n          <xsd:element name=\"assembly\">\n            <xsd:complexType>\n              <xsd:attribute name=\"alias\" type=\"xsd:string\" />\n              <xsd:attribute name=\"name\" type=\"xsd:string\" />\n            </xsd:complexType>\n          </xsd:element>\n          <xsd:element name=\"data\">\n            <xsd:complexType>\n              <xsd:sequence>\n                <xsd:element name=\"value\" type=\"xsd:string\" minOccurs=\"0\" msdata:Ordinal=\"1\" />\n                <xsd:element name=\"comment\" type=\"xsd:string\" minOccurs=\"0\" msdata:Ordinal=\"2\" />\n              </xsd:sequence>\n              <xsd:attribute name=\"name\" type=\"xsd:string\" use=\"required\" msdata:Ordinal=\"1\" />\n              <xsd:attribute name=\"type\" type=\"xsd:string\" msdata:Ordinal=\"3\" />\n              <xsd:attribute name=\"mimetype\" type=\"xsd:string\" msdata:Ordinal=\"4\" />\n              <xsd:attribute ref=\"xml:space\" />\n            </xsd:complexType>\n          </xsd:element>\n          <xsd:element name=\"resheader\">\n            <xsd:complexType>\n              <xsd:sequence>\n                <xsd:element name=\"value\" type=\"xsd:string\" minOccurs=\"0\" msdata:Ordinal=\"1\" />\n              </xsd:sequence>\n              <xsd:attribute name=\"name\" type=\"xsd:string\" use=\"required\" />\n            </xsd:complexType>\n          </xsd:element>\n        </xsd:choice>\n      </xsd:complexType>\n    </xsd:element>\n  </xsd:schema>\n  <resheader name=\"resmimetype\">\n    <value>text/microsoft-resx</value>\n  </resheader>\n  <resheader name=\"version\">\n    <value>2.0</value>\n  </resheader>\n  <resheader name=\"reader\">\n    <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>\n  </resheader>\n  <resheader name=\"writer\">\n    <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>\n  </resheader>\n  <data name=\"UserManual\" xml:space=\"preserve\">\n    <value>SilentCMD [Options] BatchFile [BatchArguments]\n\nOptions:\n/? :: Show help\n/LOG:file :: Output status to log file (overwrite existing log).\n/LOG+:file :: Output status to log file (append to existing log).\n/LOGSIZE:bytes :: Maximum log file size after which it is truncated\n/DELAY:seconds :: Delay the execution of batch file by x seconds\n\nExamples\nSilentCMD c:\\DoSomething.bat\nSilentCMD /LOG:c:\\MyLog.txt c:\\MyBatch.cmd MyParam1\nSilentCMD /LOG+:c:\\MyLog.txt /LOGSIZE:1000000 c:\\MyBatch.cmd\nSilentCMD /DELAY:3600 c:\\MyBatch.cmd\n\nVersion {0}\nFree software under MIT license\nMore information on https://www.stephan-brenner.com</value>\n  </data>\n  <data name=\"ProgramTitle\" xml:space=\"preserve\">\n    <value>SilentCMD</value>\n  </data>\n  <data name=\"Error\" xml:space=\"preserve\">\n    <value>Error: {0}</value>\n  </data>\n  <data name=\"StartingCommand\" xml:space=\"preserve\">\n    <value>Started \"{0}\" (PID {1})</value>\n  </data>\n  <data name=\"FinishedCommand\" xml:space=\"preserve\">\n    <value>Finished \"{0}\"</value>\n  </data>\n  <data name=\"Delay\" xml:space=\"preserve\">\n    <value>Delaying execution by {0} seconds</value>\n  </data>\n</root>"
  },
  {
    "path": "Brenner.SilentCmd/Properties/Settings.Designer.cs",
    "content": "﻿//------------------------------------------------------------------------------\n// <auto-generated>\n//     This code was generated by a tool.\n//     Runtime Version:4.0.30319.42000\n//\n//     Changes to this file may cause incorrect behavior and will be lost if\n//     the code is regenerated.\n// </auto-generated>\n//------------------------------------------------------------------------------\n\nnamespace Brenner.SilentCmd.Properties {\n    \n    \n    [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]\n    [global::System.CodeDom.Compiler.GeneratedCodeAttribute(\"Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator\", \"17.14.0.0\")]\n    internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase {\n        \n        private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));\n        \n        public static Settings Default {\n            get {\n                return defaultInstance;\n            }\n        }\n        \n        [global::System.Configuration.ApplicationScopedSettingAttribute()]\n        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]\n        [global::System.Configuration.DefaultSettingValueAttribute(\"\")]\n        public string DefaultBatchFilePath {\n            get {\n                return ((string)(this[\"DefaultBatchFilePath\"]));\n            }\n        }\n        \n        [global::System.Configuration.ApplicationScopedSettingAttribute()]\n        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]\n        [global::System.Configuration.DefaultSettingValueAttribute(\"\")]\n        public string DefaultBatchFileArguments {\n            get {\n                return ((string)(this[\"DefaultBatchFileArguments\"]));\n            }\n        }\n        \n        [global::System.Configuration.ApplicationScopedSettingAttribute()]\n        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]\n        [global::System.Configuration.DefaultSettingValueAttribute(\"%temp%\\\\SilentCMD.log\")]\n        public string DefaultLogFilePath {\n            get {\n                return ((string)(this[\"DefaultLogFilePath\"]));\n            }\n        }\n        \n        [global::System.Configuration.ApplicationScopedSettingAttribute()]\n        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]\n        [global::System.Configuration.DefaultSettingValueAttribute(\"False\")]\n        public bool DefaultLogAppend {\n            get {\n                return ((bool)(this[\"DefaultLogAppend\"]));\n            }\n        }\n        \n        [global::System.Configuration.ApplicationScopedSettingAttribute()]\n        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]\n        [global::System.Configuration.DefaultSettingValueAttribute(\"00:00:00\")]\n        public global::System.TimeSpan DefaultDelay {\n            get {\n                return ((global::System.TimeSpan)(this[\"DefaultDelay\"]));\n            }\n        }\n        \n        [global::System.Configuration.ApplicationScopedSettingAttribute()]\n        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]\n        [global::System.Configuration.DefaultSettingValueAttribute(\"0\")]\n        public long DefaultLogSize {\n            get {\n                return ((long)(this[\"DefaultLogSize\"]));\n            }\n        }\n    }\n}\n"
  },
  {
    "path": "Brenner.SilentCmd/Properties/Settings.settings",
    "content": "﻿<?xml version='1.0' encoding='utf-8'?>\n<SettingsFile xmlns=\"http://schemas.microsoft.com/VisualStudio/2004/01/settings\" CurrentProfile=\"(Default)\" GeneratedClassNamespace=\"Brenner.SilentCmd.Properties\" GeneratedClassName=\"Settings\">\n  <Profiles />\n  <Settings>\n    <Setting Name=\"DefaultBatchFilePath\" Type=\"System.String\" Scope=\"Application\">\n      <Value Profile=\"(Default)\" />\n    </Setting>\n    <Setting Name=\"DefaultBatchFileArguments\" Type=\"System.String\" Scope=\"Application\">\n      <Value Profile=\"(Default)\" />\n    </Setting>\n    <Setting Name=\"DefaultLogFilePath\" Type=\"System.String\" Scope=\"Application\">\n      <Value Profile=\"(Default)\">%temp%\\SilentCMD.log</Value>\n    </Setting>\n    <Setting Name=\"DefaultLogAppend\" Type=\"System.Boolean\" Scope=\"Application\">\n      <Value Profile=\"(Default)\">False</Value>\n    </Setting>\n    <Setting Name=\"DefaultDelay\" Type=\"System.TimeSpan\" Scope=\"Application\">\n      <Value Profile=\"(Default)\">00:00:00</Value>\n    </Setting>\n    <Setting Name=\"DefaultLogSize\" Type=\"System.Int64\" Scope=\"Application\">\n      <Value Profile=\"(Default)\">0</Value>\n    </Setting>\n  </Settings>\n</SettingsFile>"
  },
  {
    "path": "Brenner.SilentCmd/app.config",
    "content": "<?xml version=\"1.0\"?>\n<configuration>\n<configSections>\n    <sectionGroup name=\"applicationSettings\" type=\"System.Configuration.ApplicationSettingsGroup, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089\" >\n        <section name=\"Brenner.SilentCmd.Properties.Settings\" type=\"System.Configuration.ClientSettingsSection, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089\" requirePermission=\"false\" />\n    </sectionGroup>\n</configSections>\n<startup>\n  <supportedRuntime version=\"v4.0\"/>\n  <supportedRuntime version=\"v2.0.50727\"/>\n</startup>\n  <applicationSettings>\n        <Brenner.SilentCmd.Properties.Settings>\n              <setting name=\"DefaultBatchFilePath\" serializeAs=\"String\">\n                    <value />\n              </setting>\n              <setting name=\"DefaultBatchFileArguments\" serializeAs=\"String\">\n                    <value />\n              </setting>\n              <setting name=\"DefaultLogFilePath\" serializeAs=\"String\">\n                    <value>%temp%\\SilentCMD.log</value>\n              </setting>\n              <setting name=\"DefaultLogAppend\" serializeAs=\"String\">\n                    <value>False</value>\n              </setting>\n              <setting name=\"DefaultDelay\" serializeAs=\"String\">\n                    <value>00:00:00</value>\n              </setting>\n              <setting name=\"DefaultLogSize\" serializeAs=\"String\">\n                    <value>0</value>\n              </setting>\n        </Brenner.SilentCmd.Properties.Settings>\n    </applicationSettings>\n</configuration>\n"
  },
  {
    "path": "Brenner.SilentCmd.Tests/Brenner.SilentCmd.Tests.csproj",
    "content": "﻿<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<Project ToolsVersion=\"15.0\" xmlns=\"http://schemas.microsoft.com/developer/msbuild/2003\">\n  <Import Project=\"..\\packages\\xunit.runner.visualstudio.2.4.1\\build\\net20\\xunit.runner.visualstudio.props\" Condition=\"Exists('..\\packages\\xunit.runner.visualstudio.2.4.1\\build\\net20\\xunit.runner.visualstudio.props')\" />\n  <Import Project=\"..\\packages\\xunit.core.2.4.1\\build\\xunit.core.props\" Condition=\"Exists('..\\packages\\xunit.core.2.4.1\\build\\xunit.core.props')\" />\n  <Import Project=\"$(MSBuildExtensionsPath)\\$(MSBuildToolsVersion)\\Microsoft.Common.props\" Condition=\"Exists('$(MSBuildExtensionsPath)\\$(MSBuildToolsVersion)\\Microsoft.Common.props')\" />\n  <PropertyGroup>\n    <Configuration Condition=\" '$(Configuration)' == '' \">Debug</Configuration>\n    <Platform Condition=\" '$(Platform)' == '' \">AnyCPU</Platform>\n    <ProjectGuid>{A2A99298-3567-4D16-8FEF-1FD0DACA3178}</ProjectGuid>\n    <OutputType>Library</OutputType>\n    <AppDesignerFolder>Properties</AppDesignerFolder>\n    <RootNamespace>Brenner.SilentCmd.Tests</RootNamespace>\n    <AssemblyName>Brenner.SilentCmd.Tests</AssemblyName>\n    <TargetFrameworkVersion>v4.8</TargetFrameworkVersion>\n    <FileAlignment>512</FileAlignment>\n    <Deterministic>true</Deterministic>\n    <NuGetPackageImportStamp>\n    </NuGetPackageImportStamp>\n    <TargetFrameworkProfile />\n  </PropertyGroup>\n  <PropertyGroup Condition=\" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' \">\n    <DebugSymbols>true</DebugSymbols>\n    <DebugType>full</DebugType>\n    <Optimize>false</Optimize>\n    <OutputPath>bin\\Debug\\</OutputPath>\n    <DefineConstants>DEBUG;TRACE</DefineConstants>\n    <ErrorReport>prompt</ErrorReport>\n    <WarningLevel>4</WarningLevel>\n  </PropertyGroup>\n  <PropertyGroup Condition=\" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' \">\n    <DebugType>pdbonly</DebugType>\n    <Optimize>true</Optimize>\n    <OutputPath>bin\\Release\\</OutputPath>\n    <DefineConstants>TRACE</DefineConstants>\n    <ErrorReport>prompt</ErrorReport>\n    <WarningLevel>4</WarningLevel>\n  </PropertyGroup>\n  <ItemGroup>\n    <Reference Include=\"System\" />\n    <Reference Include=\"System.Core\" />\n    <Reference Include=\"System.Xml.Linq\" />\n    <Reference Include=\"System.Data.DataSetExtensions\" />\n    <Reference Include=\"Microsoft.CSharp\" />\n    <Reference Include=\"System.Data\" />\n    <Reference Include=\"System.Net.Http\" />\n    <Reference Include=\"System.Xml\" />\n    <Reference Include=\"xunit.abstractions, Version=2.0.0.0, Culture=neutral, PublicKeyToken=8d05b1bb7a6fdb6c, processorArchitecture=MSIL\">\n      <HintPath>..\\packages\\xunit.abstractions.2.0.3\\lib\\net35\\xunit.abstractions.dll</HintPath>\n    </Reference>\n    <Reference Include=\"xunit.assert, Version=2.4.1.0, Culture=neutral, PublicKeyToken=8d05b1bb7a6fdb6c, processorArchitecture=MSIL\">\n      <HintPath>..\\packages\\xunit.assert.2.4.1\\lib\\netstandard1.1\\xunit.assert.dll</HintPath>\n    </Reference>\n    <Reference Include=\"xunit.core, Version=2.4.1.0, Culture=neutral, PublicKeyToken=8d05b1bb7a6fdb6c, processorArchitecture=MSIL\">\n      <HintPath>..\\packages\\xunit.extensibility.core.2.4.1\\lib\\net452\\xunit.core.dll</HintPath>\n    </Reference>\n    <Reference Include=\"xunit.execution.desktop, Version=2.4.1.0, Culture=neutral, PublicKeyToken=8d05b1bb7a6fdb6c, processorArchitecture=MSIL\">\n      <HintPath>..\\packages\\xunit.extensibility.execution.2.4.1\\lib\\net452\\xunit.execution.desktop.dll</HintPath>\n    </Reference>\n  </ItemGroup>\n  <ItemGroup>\n    <Compile Include=\"ConfigurationTest.cs\" />\n    <Compile Include=\"Properties\\AssemblyInfo.cs\" />\n  </ItemGroup>\n  <ItemGroup>\n    <None Include=\"packages.config\" />\n  </ItemGroup>\n  <ItemGroup>\n    <Analyzer Include=\"..\\packages\\xunit.analyzers.0.10.0\\analyzers\\dotnet\\cs\\xunit.analyzers.dll\" />\n  </ItemGroup>\n  <ItemGroup>\n    <ProjectReference Include=\"..\\Brenner.SilentCmd\\Brenner.SilentCmd.csproj\">\n      <Project>{461e6475-6450-40ed-b68c-7f012701e6c6}</Project>\n      <Name>Brenner.SilentCmd</Name>\n    </ProjectReference>\n  </ItemGroup>\n  <Import Project=\"$(MSBuildToolsPath)\\Microsoft.CSharp.targets\" />\n  <Target Name=\"EnsureNuGetPackageBuildImports\" BeforeTargets=\"PrepareForBuild\">\n    <PropertyGroup>\n      <ErrorText>This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them.  For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>\n    </PropertyGroup>\n    <Error Condition=\"!Exists('..\\packages\\xunit.core.2.4.1\\build\\xunit.core.props')\" Text=\"$([System.String]::Format('$(ErrorText)', '..\\packages\\xunit.core.2.4.1\\build\\xunit.core.props'))\" />\n    <Error Condition=\"!Exists('..\\packages\\xunit.core.2.4.1\\build\\xunit.core.targets')\" Text=\"$([System.String]::Format('$(ErrorText)', '..\\packages\\xunit.core.2.4.1\\build\\xunit.core.targets'))\" />\n    <Error Condition=\"!Exists('..\\packages\\xunit.runner.visualstudio.2.4.1\\build\\net20\\xunit.runner.visualstudio.props')\" Text=\"$([System.String]::Format('$(ErrorText)', '..\\packages\\xunit.runner.visualstudio.2.4.1\\build\\net20\\xunit.runner.visualstudio.props'))\" />\n  </Target>\n  <Import Project=\"..\\packages\\xunit.core.2.4.1\\build\\xunit.core.targets\" Condition=\"Exists('..\\packages\\xunit.core.2.4.1\\build\\xunit.core.targets')\" />\n</Project>"
  },
  {
    "path": "Brenner.SilentCmd.Tests/ConfigurationTest.cs",
    "content": "﻿using System;\nusing Xunit;\n\nnamespace Brenner.SilentCmd.Tests\n{\n    public class ConfigurationTest\n    {\n        [Fact]\n        public void Log()\n        {\n            Configuration config = new Configuration();\n            config.ParseArguments(new string[] {@\"/LOG:c:\\temp\\test.log\"});\n            Assert.False(config.LogAppend);\n            Assert.Equal(@\"c:\\temp\\test.log\", config.LogFilePath);\n        }\n\n        [Fact]\n        public void NotLog()\n        {\n            Configuration config = new Configuration();\n            config.ParseArguments(new string[] { @\"/LOGA:c:\\temp\\test.log\" });\n            Assert.Null(config.LogFilePath);\n        }\n\n        [Fact]\n        public void LogPlus()\n        {\n            Configuration config = new Configuration();\n            config.ParseArguments(new string[] { \"/LOG+:\\\"c:\\\\My Files\\\\test.log\\\"\" });\n            Assert.True(config.LogAppend);\n            Assert.Equal(@\"c:\\My Files\\test.log\", config.LogFilePath);\n        }\n\n        [Fact]\n        public void Delay()\n        {\n            Configuration config = new Configuration();\n            config.ParseArguments(new string[] { \"/DELAY:1234\" });\n            Assert.Equal(TimeSpan.FromSeconds(1234), config.Delay);\n        }\n\n        [Fact]\n        public void Help()\n        {\n            Configuration config = new Configuration();\n            config.ParseArguments(new string[] { \"/?\" });\n            Assert.True(config.ShowHelp);\n        }\n\n    }\n}\n"
  },
  {
    "path": "Brenner.SilentCmd.Tests/Dummy.cmd",
    "content": "@echo off\necho This is a test batch file for SilentCMD\necho Parameter 1: %1\necho Date: %date%\nTIMEOUT /T 5\nexit /B 1234"
  },
  {
    "path": "Brenner.SilentCmd.Tests/Properties/AssemblyInfo.cs",
    "content": "﻿using System.Reflection;\nusing System.Runtime.CompilerServices;\nusing System.Runtime.InteropServices;\n\n// General Information about an assembly is controlled through the following\n// set of attributes. Change these attribute values to modify the information\n// associated with an assembly.\n[assembly: AssemblyTitle(\"Brenner.SilentCmd.Tests\")]\n[assembly: AssemblyDescription(\"\")]\n[assembly: AssemblyConfiguration(\"\")]\n[assembly: AssemblyCompany(\"Avira Operations GmbH & Co. KG;\")]\n[assembly: AssemblyProduct(\"Brenner.SilentCmd.Tests\")]\n[assembly: AssemblyCopyright(\"Copyright © Avira Operations GmbH & Co. KG; 2019\")]\n[assembly: AssemblyTrademark(\"\")]\n[assembly: AssemblyCulture(\"\")]\n\n// Setting ComVisible to false makes the types in this assembly not visible\n// to COM components.  If you need to access a type in this assembly from\n// COM, set the ComVisible attribute to true on that type.\n[assembly: ComVisible(false)]\n\n// The following GUID is for the ID of the typelib if this project is exposed to COM\n[assembly: Guid(\"a2a99298-3567-4d16-8fef-1fd0daca3178\")]\n\n// Version information for an assembly consists of the following four values:\n//\n//      Major Version\n//      Minor Version\n//      Build Number\n//      Revision\n//\n// You can specify all the values or you can default the Build and Revision Numbers\n// by using the '*' as shown below:\n// [assembly: AssemblyVersion(\"1.0.*\")]\n[assembly: AssemblyVersion(\"1.0.0.0\")]\n[assembly: AssemblyFileVersion(\"1.0.0.0\")]\n"
  },
  {
    "path": "Brenner.SilentCmd.Tests/TestDelay.cmd",
    "content": "@echo off\n\"%~dp0\\..\\Brenner.SilentCmd\\bin\\Debug\\SilentCMD.exe\" \"%~dp0\\Dummy.cmd\" param /LOG:\"%temp%\\TestDelay.log\" /DELAY:5"
  },
  {
    "path": "Brenner.SilentCmd.Tests/packages.config",
    "content": "﻿<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<packages>\n  <package id=\"xunit\" version=\"2.4.1\" targetFramework=\"net452\" />\n  <package id=\"xunit.abstractions\" version=\"2.0.3\" targetFramework=\"net452\" />\n  <package id=\"xunit.analyzers\" version=\"0.10.0\" targetFramework=\"net452\" />\n  <package id=\"xunit.assert\" version=\"2.4.1\" targetFramework=\"net452\" />\n  <package id=\"xunit.core\" version=\"2.4.1\" targetFramework=\"net452\" />\n  <package id=\"xunit.extensibility.core\" version=\"2.4.1\" targetFramework=\"net452\" />\n  <package id=\"xunit.extensibility.execution\" version=\"2.4.1\" targetFramework=\"net452\" />\n  <package id=\"xunit.runner.visualstudio\" version=\"2.4.1\" targetFramework=\"net452\" developmentDependency=\"true\" />\n</packages>"
  },
  {
    "path": "LICENSE",
    "content": "The MIT License (MIT)\n\nCopyright (c) 2011 Stephan Brenner\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n\n"
  },
  {
    "path": "README.md",
    "content": "# SilentCMD\n\nSilentCMD executes a batch file without opening the command prompt window. If required, the console output can be redirected to a log file.\n\n<table>\n<tr><td>Download:</td><td><a href=\"https://github.com/ymx/SilentCMD/releases/download/v1.5/SilentCMD-1.5.zip\"><strong>SilentCMD-1.5.zip</strong></a> (7 KB)</td></tr>\n<tr><td>Operating System:</td><td>Windows 10 or newer</td></tr>\n<tr><td>License:</td><td><a href=\"/LICENSE?raw=true\">MIT</a></td></tr>\n</table>\n\n### Command Line Syntax\n```\nSilentCMD [Options] BatchFile [BatchArguments]\n\nOptions:\n\n   /? :: Show help\n   /LOG:file :: Output status to LOG file (overwrite existing log)\n   /LOG+:file :: Output status to LOG file (append to existing log)\n   /LOGSIZE:bytes :: Maximum log file size after which it is truncated\n   /DELAY:seconds :: Delay the execution of batch file by x seconds\n```\n\n#### Examples\n\n```\nSilentCMD c:\\DoSomething.bat\nSilentCMD /LOG:c:\\MyLog.txt c:\\MyBatch.cmd MyParam1\nSilentCMD /LOG+:c:\\MyLog.txt /LOGSIZE:1000000 c:\\MyBatch.cmd\nSilentCMD /DELAY:3600 c:\\MyBatch.cmd\n```\n\n### Use Cases\n\nYou can use SilentCMD for running batch files from the Windows Task Scheduler. With the tool you do not get interrupted by the command prompt window that normally would pop up.\n\nYou can call SilentCMD without parameters if required (e.g. when double-clicking it in Windows Explorer). In that case you have to specify the default parameters in SilentCMD.exe.config.\n\n```\n<setting name=\"DefaultBatchFilePath\" serializeAs=\"String\">\n    <value>c:\\temp\\test.cmd</value>\n</setting>\n<setting name=\"DefaultBatchFileArguments\" serializeAs=\"String\">\n    <value>arg1 arg2=xyz</value>\n</setting>\n```\n"
  },
  {
    "path": "SilentCmd.sln",
    "content": "﻿\nMicrosoft Visual Studio Solution File, Format Version 12.00\n# Visual Studio 15\nVisualStudioVersion = 15.0.28307.168\nMinimumVisualStudioVersion = 10.0.40219.1\nProject(\"{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}\") = \"Brenner.SilentCmd\", \"Brenner.SilentCmd\\Brenner.SilentCmd.csproj\", \"{461E6475-6450-40ED-B68C-7F012701E6C6}\"\nEndProject\nProject(\"{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}\") = \"Brenner.SilentCmd.Tests\", \"Brenner.SilentCmd.Tests\\Brenner.SilentCmd.Tests.csproj\", \"{A2A99298-3567-4D16-8FEF-1FD0DACA3178}\"\nEndProject\nGlobal\n\tGlobalSection(SolutionConfigurationPlatforms) = preSolution\n\t\tDebug|Any CPU = Debug|Any CPU\n\t\tRelease|Any CPU = Release|Any CPU\n\tEndGlobalSection\n\tGlobalSection(ProjectConfigurationPlatforms) = postSolution\n\t\t{461E6475-6450-40ED-B68C-7F012701E6C6}.Debug|Any CPU.ActiveCfg = Debug|Any CPU\n\t\t{461E6475-6450-40ED-B68C-7F012701E6C6}.Debug|Any CPU.Build.0 = Debug|Any CPU\n\t\t{461E6475-6450-40ED-B68C-7F012701E6C6}.Release|Any CPU.ActiveCfg = Release|Any CPU\n\t\t{461E6475-6450-40ED-B68C-7F012701E6C6}.Release|Any CPU.Build.0 = Release|Any CPU\n\t\t{A2A99298-3567-4D16-8FEF-1FD0DACA3178}.Debug|Any CPU.ActiveCfg = Debug|Any CPU\n\t\t{A2A99298-3567-4D16-8FEF-1FD0DACA3178}.Debug|Any CPU.Build.0 = Debug|Any CPU\n\t\t{A2A99298-3567-4D16-8FEF-1FD0DACA3178}.Release|Any CPU.ActiveCfg = Release|Any CPU\n\t\t{A2A99298-3567-4D16-8FEF-1FD0DACA3178}.Release|Any CPU.Build.0 = Release|Any CPU\n\tEndGlobalSection\n\tGlobalSection(SolutionProperties) = preSolution\n\t\tHideSolutionNode = FALSE\n\tEndGlobalSection\n\tGlobalSection(ExtensibilityGlobals) = postSolution\n\t\tSolutionGuid = {6AE95268-5757-4AF5-B1FB-50DB017CF1DA}\n\tEndGlobalSection\nEndGlobal\n"
  }
]