dialog-box
is a simple tool that allows you to create a graphical dialog box from the command line using fyne. The name of the chosen button will be printed to stdout. The intended use is to create a pop-up dialog box in shell scripts.
dialog-box [OPTION]... BUTTONS Create graphical dialog box with BUTTONS that have the specified names. Options: -p specify text in prompt (default "Pick an option") -w specify window title (default "Dialog Box") -h show usage
In order to compile and run this program, you will need:
go
, the programming language- The dependencies required for
fyne
, found here.
First, clone this repository into your desired directory and enter the repo directory:
git clone https://github.com/Rasmustex/dialog-box
cd dialog-box
Then, download the fyne
go module:
go get fyne.io/fyne/v2
go mod tidy
Now, you can compile dialog-box
using go:
go build .
Alternatively, if you want to install it to your $GOPATH/bin
, use go install .