Go library for building applications. Dramatically simple. For a CLI tool see acmd.
- Simple API.
- Dependency-free.
- Dramatically simple.
See GUIDE.md for more details
Go version 1.17+
go get github.com/cristalhq/appx
import (
"context"
"os"
"github.com/cristalhq/appx"
)
func main() {
ctx := appx.Context()
if err := run(ctx, os.Args[1:]); err != nil {
panic(err)
}
}
func run(ctx context.Context, args []string) error {
// do good things
return nil
}
Also see examples: examples_test.go.
See these docs.