docs / cli
gru · 0.7.0
CLI
Public packaging and scaffold tool under cmd/gru. Prefer this over ad-hoc scripts.
go run ./cmd/gru <command> …
# after install onto PATH:
gru <command> …
new
Scaffold an app directory from the hello or webviewhello templates.
go run ./cmd/gru new myapp
go run ./cmd/gru new myapp --webview
| Flag | Template |
|---|---|
| (default) | Native sample based on cmd/hello |
--webview | FillClient WebView shell (cmd/webviewhello) |
Requires WebView2 Runtime for --webview on Windows.
build
Compile a known product into dist/.
go run ./cmd/gru build hello [-o path]
go run ./cmd/gru build webviewhello -webview2 [-o path]
go run ./cmd/gru build demo [-webview2] [-o path]
| Product | What it builds |
|---|---|
hello | Native sample |
webviewhello | WebView sample; use -webview2 for live host |
demo | Curated demo launcher (-tags grudemo) |
Default output lands under dist/. See gru build -h for platform args.
package
Zip a built product with the fonts and assets it needs at runtime.
go run ./cmd/gru package hello windows
go run ./cmd/gru package webviewhello windows
go run ./cmd/gru package demo windows
Stages fonts/assets needed at runtime into a release zip. Prefer packaging after a successful build of the same product.
Build tags (cheat sheet)
| Tag | When |
|---|---|
grudemo | Curated demo catalog |
webview2 | Live WebView2 host (Windows) |
x11 | Linux hello path |
More smoke detail lives in the repo’s BUILD.md.
Next: Start · WebView · Composition