2using static System.Console;
6 public static double GetDouble(string text, Func<double, bool> validate, string falseText) {
10 if (double.TryParse(ReadLine(), out res) && validate(res)) {
19 public static double GetDouble(string text, string falseText) {
20 return GetDouble(text, _ => { return true; }, falseText);
23 public static float GetFloat(string text, Func<float, bool> validate, string falseText) {
27 if (float.TryParse(ReadLine(), out res) && validate(res)) {
36 public static float GetFloat(string text, string falseText) {
37 return GetFloat(text, _ => { return true; }, falseText);
40 public static int GetInt(string text, Func<int, bool> validate, string falseText) {
44 if (int.TryParse(ReadLine(), out res) && validate(res)) {
53 public static int GetInt(string text, string falseText) {
54 return GetInt(text, _ => { return true; }, falseText);
57 public static void Repeat(Action f) {
60 Write("Press Enter to repeat program. Press any other key to quit.");
61 } while (ReadKey().Key == ConsoleKey.Enter);
keysesc to close
- j k
- move down, up
- enter
- open
- esc
- back, or up a level
- 1 2 3 4
- readme, files, commits, refs
- /
- filter
- y
- copy the clone command
- c
- compare the chosen commit with another (or shift-click both)
- ?
- show or hide this list