Misc style and other minor changes

This commit is contained in:
Noi 2022-08-25 18:40:57 -07:00
parent b03905afda
commit dfec87672f
3 changed files with 4 additions and 12 deletions

View file

@ -4,7 +4,6 @@ using System.Diagnostics.CodeAnalysis;
using System.Reflection;
namespace RegexBot;
/// <summary>
/// Contains essential instance configuration for this bot including Discord connection settings, service configuration,
/// and command-line options.
@ -67,17 +66,10 @@ class InstanceConfig {
return default;
}
/// <summary>
/// Command line options
/// </summary>
class CommandLineParameters {
[Option('c', "config", Default = null,
HelpText = "Custom path to instance configuration. Defaults to instance.json in bot directory.")]
public string ConfigFile { get; set; } = null!;
[Option('c', "config", Default = null)]
public string? ConfigFile { get; set; } = null!;
/// <summary>
/// Command line arguments parsed here. Depending on inputs, the program can exit here.
/// </summary>
public static CommandLineParameters? Parse(string[] args) {
CommandLineParameters? result = null;

View file

@ -1,4 +1,4 @@
#pragma warning disable CA1822 // "Mark members as static" - will not make static to encourage better structure
#pragma warning disable CA1822 // "Mark members as static" - members should only be callable by code with access to this instance
using Discord.Net;
namespace RegexBot.Services.CommonFunctions;

View file

@ -1,4 +1,4 @@
#pragma warning disable CA1822 // "Mark members as static" - will not make static to encourage better structure
#pragma warning disable CA1822 // "Mark members as static" - members should only be callable by code with access to this instance
using Microsoft.EntityFrameworkCore;
using RegexBot.Common;
using RegexBot.Data;