public static void WriteSection(string section) { SETTINGS js = JsonConvert.DeserializeObject <SETTINGS>(File.ReadAllText($@"settings.json")); SETTINGS se = new SETTINGS { git = js.git, api = js.api, minimumValue = js.minimumValue, verbose = js.verbose, ssf = js.ssf, section = section }; var raw = JsonConvert.SerializeObject(se, Formatting.Indented); File.WriteAllText($@"settings.json", raw); }
public static string GetSection() { SETTINGS j = JsonConvert.DeserializeObject <SETTINGS>(File.ReadAllText("settings.json")); return(j.section); }
public static bool GetSSF() { SETTINGS j = JsonConvert.DeserializeObject <SETTINGS>(File.ReadAllText("settings.json")); return(j.ssf); }
public static int GetMinimumValue() { SETTINGS j = JsonConvert.DeserializeObject <SETTINGS>(File.ReadAllText("settings.json")); return(j.minimumValue); }