diff options
| author | Jeff Carr <[email protected]> | 2024-11-15 20:04:22 -0600 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2024-11-15 20:04:22 -0600 |
| commit | fd65e8f02e59f115c33fe73475742693027eebbd (patch) | |
| tree | a7ddfc89b33322648948985e015fbbf1a0663a37 | |
| parent | 8a144eb5fd1ea8a799af51d93518b8080e6624f1 (diff) | |
try to add --no-guiv0.22.6
| -rw-r--r-- | Makefile | 21 | ||||
| -rw-r--r-- | argv.go (renamed from args.go) | 3 | ||||
| -rw-r--r-- | main.go | 4 |
3 files changed, 8 insertions, 20 deletions
@@ -1,26 +1,12 @@ all: - @GO111MODULE=off go build @echo @echo This is the core gui package 'go.wit.com/gui/gui' @echo @echo It creates a binary tree of widgets @echo The widgets are things like Windows, Buttons, Labels, etc @echo - @go vet - -note-about-golang: -ifeq ($(GO111MODULE),) - @echo - @echo If you are compiling this here, you probably want to set GO111MODULE - @echo - @echo Setting GO111MODULE means that the version you are compiling has plugins - @echo that get compiled against this current running version of the code - @echo Otherwise, the GO language plugins can complain about being compiled against - @echo mis-matched versions - @echo - @echo export GO111MODULE=off - @echo -endif + @GO111MODULE=off go vet + @echo go vet: this go library package builds okay goimports: goimports -w *.go @@ -38,6 +24,3 @@ update: doc: godoc -v - -submit-to-docs: - GOPROXY=https://proxy.golang.org GO111MODULE=on go get go.wit.com/[email protected] @@ -11,7 +11,8 @@ This struct can be used with the go-arg package. These are the generic default command line arguments for the 'GUI' package */ type ArgsGui struct { - GuiPlugin string `arg:"--gui" help:"Use this gui toolkit [andlabs,gocui,nocui,nogui]"` + NoGui bool `arg:"--no-gui" help:"ignore all these gui problems"` + GuiPlugin string `arg:"--gui" help:"Use this gui toolkit [andlabs,gocui,nocui,stdin]"` GuiVerbose bool `arg:"--gui-verbose" help:"enable all logging"` } @@ -263,6 +263,10 @@ func New() *Node { // try to load andlabs, if that doesn't work, fall back to the console func (n *Node) Default() *Node { var err error + if argGui.NoGui { + log.Log(WARN, "--no-gui chill Winston. I don't need no gui") + return n + } if argGui.GuiPlugin != "" { log.Log(WARN, "New.Default() try toolkit =", argGui.GuiPlugin) if n, err = n.LoadToolkit(argGui.GuiPlugin); err == nil { |
