diff options
Diffstat (limited to 'writer')
| -rw-r--r-- | writer/Program.cs | 25 | ||||
| -rw-r--r-- | writer/Properties/AssemblyInfo.cs | 10 |
2 files changed, 17 insertions, 18 deletions
diff --git a/writer/Program.cs b/writer/Program.cs index 2d4128f..ec8706b 100644 --- a/writer/Program.cs +++ b/writer/Program.cs @@ -21,18 +21,21 @@ namespace writer return; } - foreach (var err in errors.x) + Console.Write("Bad settings: \n\n{0}", errors); + } + + static void Main(string[] args) + { + try { - Console.WriteLine(err + (settings.combineMagnitudes ? "" : " (x)")); + VersionHelper.ValidateAndGetDriverVersion(typeof(Program).Assembly.GetName().Version); } - foreach (var err in errors.y) + catch (VersionException e) { - Console.WriteLine(err + " (y)"); + Console.WriteLine(e.Message); + return; } - } - static void Main(string[] args) - { if (args.Length != 1 || args[0].Equals("help")) { Console.WriteLine("USAGE: {0} <file>", System.AppDomain.CurrentDomain.FriendlyName); @@ -59,15 +62,11 @@ namespace writer } catch (JsonException e) { - Console.WriteLine("Settings invalid:\n{0}", e.Message.ToString()); - } - catch (DriverNotInstalledException) - { - Console.WriteLine("Driver is not installed"); + Console.WriteLine("Settings invalid:\n{0}", e.Message); } catch (Exception e) { - Console.WriteLine("Error: {0}", e.Message.ToString()); + Console.WriteLine("Error: {0}", e); } } } diff --git a/writer/Properties/AssemblyInfo.cs b/writer/Properties/AssemblyInfo.cs index 37e79ad..fc6a1ca 100644 --- a/writer/Properties/AssemblyInfo.cs +++ b/writer/Properties/AssemblyInfo.cs @@ -5,12 +5,12 @@ using System.Runtime.InteropServices; // General Information about an assembly is controlled through the following // set of attributes. Change these attribute values to modify the information // associated with an assembly. -[assembly: AssemblyTitle("writer")] +[assembly: AssemblyTitle("Raw Accel settings writer")] [assembly: AssemblyDescription("")] [assembly: AssemblyConfiguration("")] [assembly: AssemblyCompany("")] -[assembly: AssemblyProduct("writer")] -[assembly: AssemblyCopyright("Copyright © 2020")] +[assembly: AssemblyProduct("Raw Accel")] +[assembly: AssemblyCopyright("")] [assembly: AssemblyTrademark("")] [assembly: AssemblyCulture("")] @@ -32,5 +32,5 @@ using System.Runtime.InteropServices; // You can specify all the values or you can default the Build and Revision Numbers // by using the '*' as shown below: // [assembly: AssemblyVersion("1.0.*")] -[assembly: AssemblyVersion("1.0.0.0")] -[assembly: AssemblyFileVersion("1.0.0.0")] +[assembly: AssemblyVersion(RawAccelVersion.value)] +[assembly: AssemblyFileVersion(RawAccelVersion.value)] |