public static void Save(ApplicationConfig cfg, string path) { AppConsole.WriteLine("Saving configuration to file: " + path); File.WriteAllText(path, JsonConvert.SerializeObject(cfg, Formatting.Indented)); }
public static void Load(string path) { AppConsole.WriteLine("Loading configuration from file: " + path); Shared = JsonConvert.DeserializeObject <ApplicationConfig>(File.ReadAllText(path)); }