diff options
| author | Jeff Carr <[email protected]> | 2024-01-07 18:50:36 -0600 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2024-01-07 18:50:36 -0600 |
| commit | 360002f785af6df4b03cdeda1a39b1c2bcb25f59 (patch) | |
| tree | 56a9b5163cac900d8a5dd2865944a4bbf0d9f513 /main.go | |
| parent | 9a975d82b89103d5a1cbd5710545679d8c20d722 (diff) | |
misc updates
Signed-off-by: Jeff Carr <[email protected]>
Diffstat (limited to 'main.go')
| -rw-r--r-- | main.go | 18 |
1 files changed, 10 insertions, 8 deletions
@@ -1,6 +1,7 @@ package main import ( + "os" "time" "go.wit.com/log" @@ -17,6 +18,10 @@ func main() { // initialize a new GO GUI instance myGui = gui.New().Default() + if os.Getenv("DIGITALOCEAN_TOKEN") == "" { + log.Warn("your DIGITALOCEAN_TOKEN environment variable is not set") + } + // draw the main window cloudApp(myGui) @@ -25,15 +30,7 @@ func main() { myDo.Update() myDo.Show() - if debugger.ArgDebug() { - log.Sleep(2) - debugger.DebugWindow(myGui) - } - doUpdate() - // This is just a optional goroutine to watch that things are alive - gui.Watchdog() - gui.StandardExit() } func cloudApp(n *gui.Node) *gui.Node { @@ -69,6 +66,11 @@ func cloudApp(n *gui.Node) *gui.Node { }) grid.NewLabel("makes a new droplet") + grid.NewButton("gui debugger", func () { + debugger.DebugWindow(myGui) + }) + grid.NewLabel("make sure you have $ENV(DIGITALOCEAN_TOKEN} set to your API token") + return win } |
