5cb5699eaf
Bumps [golang.org/x/image](https://github.com/golang/image) from 0.15.0 to 0.16.0. - [Commits](https://github.com/golang/image/compare/v0.15.0...v0.16.0) --- updated-dependencies: - dependency-name: golang.org/x/image dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> |
||
---|---|---|
.github | ||
cmd/zenity | ||
internal | ||
scripts | ||
testdata | ||
.gitignore | ||
color.go | ||
color_darwin.go | ||
color_test.go | ||
color_unix.go | ||
color_windows.go | ||
date.go | ||
date_darwin.go | ||
date_test.go | ||
date_unix.go | ||
date_windows.go | ||
entry.go | ||
entry_darwin.go | ||
entry_test.go | ||
entry_unix.go | ||
entry_windows.go | ||
file.go | ||
file_darwin.go | ||
file_filter_test.go | ||
file_test.go | ||
file_unix.go | ||
file_util_test.go | ||
file_windows.go | ||
go.mod | ||
go.sum | ||
LICENSE | ||
list.go | ||
list_darwin.go | ||
list_test.go | ||
list_unix.go | ||
list_windows.go | ||
main_test.go | ||
msg.go | ||
msg_darwin.go | ||
msg_test.go | ||
msg_unix.go | ||
msg_windows.go | ||
notify.go | ||
notify_darwin.go | ||
notify_test.go | ||
notify_unix.go | ||
notify_windows.go | ||
progress.go | ||
progress_darwin.go | ||
progress_test.go | ||
progress_unix.go | ||
progress_windows.go | ||
pwd.go | ||
pwd_darwin.go | ||
pwd_test.go | ||
pwd_unix.go | ||
pwd_windows.go | ||
README.md | ||
util.go | ||
util_darwin.go | ||
util_test.go | ||
util_windows.go | ||
zenity.go | ||
zenity_darwin.go | ||
zenity_test.go | ||
zenity_unix.go | ||
zenity_windows.go |
Zenity dialogs for Golang, Windows and macOS
This repo includes:
- a cross-platform Go package providing Zenity-like dialogs (simple dialogs that interact graphically with the user)
- a “port” of the
zenity
command to both Windows and macOS based on that library.
Implemented dialogs:
- message (error, info, question, warning)
- text entry
- list (simple)
- password
- file selection
- color selection
- calendar
- progress
- notification
Behavior on Windows, macOS and other Unixes might differ slightly. Some of that is intended (reflecting platform differences), other bits are unfortunate limitations.
Installing
The Go package:
go get github.com/ncruces/zenity@latest
The zenity
command on macOS/WSL using Homebrew 🍺:
brew install ncruces/tap/zenity
The zenity
command on Windows using Scoop 🍨:
scoop install https://ncruces.github.io/scoop/zenity.json
The zenity
command on macOS/Windows, if you have Go:
go install github.com/ncruces/zenity/cmd/zenity@latest
Or download the latest release.
Using
For the Go package, consult the documentation and examples.
The zenity
command does its best to be compatible with the GNOME version.
Consult the documentation
and man page of that command.
Why?
Benefits of the Go package:
- no
cgo
(see benefits, mostly cross-compilation) - no main loop (or any other threading or initialization requirements)
- cancelation through
context
- on Windows:
- no additional dependencies
- Explorer shell not required
- works in Server Core
- Unicode support
- High DPI (no manifest required)
- Visual Styles (no manifest required)
- WSL/Cygwin/MSYS2 support
- no additional dependencies
- on macOS:
- only dependency is
osascript
- only dependency is
- on other Unixes:
- wraps either one of
zenity
,matedialog
,qarma
- wraps either one of
Zenity wrappers
Zenity wrappers for languages other than Go can benefit from our zenity
command. On Unix (Linux, FreeBSD, etc) they can use the original tool, and on Windows/macOS they may use the command from this repo for portability.
Examples:
- NodeJS
dialog-gui
by @SnurfDev - Crystal
zenity.cr
by @kojix2
Credits
I'd like to thank all contributors,
but @gen2brain in particular
for dlgs
,
which was instrumental to the Windows port of zenity
.