tAdd command to force refreshing HTML - scoreboard - Interactive scoreboard for CTF-like games
 (HTM) git clone git://git.z3bra.org/scoreboard.git
 (DIR) Log
 (DIR) Files
 (DIR) Refs
       ---
 (DIR) commit ac7a16acf57a92cb886b8a5d4fd0071237b4e959
 (DIR) parent 528d94f22d463e41294bd92095b4953f52dc1fdd
 (HTM) Author: Willy Goiffon <dev@z3bra.org>
       Date:   Wed,  7 Dec 2022 17:25:14 +0100
       
       Add command to force refreshing HTML
       
       Diffstat:
         M main.go                             |       9 ++++++++-
       
       1 file changed, 8 insertions(+), 1 deletion(-)
       ---
 (DIR) diff --git a/main.go b/main.go
       t@@ -179,9 +179,16 @@ func main() {
        
                args := flag.Args()
        
       -        if len(args) > 1 || (len(args) == 1 && args[0] == "help") {
       +        if len(args) > 1 {
                        usage()
                } else if len(args) == 1 {
       +                if args[0] == "help" {
       +                        usage()
       +                }
       +                if args[0] == "refresh" {
       +                        cyboard.GenerateHTML()
       +                        os.Exit(0)
       +                }
                        switch cyboard.flag = flagid(args[0]) + 1; cyboard.flag {
                        case 1:
                                cyboard.player.flag = cyboard.flag