Documentation
¶
Overview ¶
Package cli implements the graphnest command-line tool.
Index ¶
Constants ¶
This section is empty.
Variables ¶
var Version string
Version is set at build time with -ldflags "-X github.com/balcsida/graphnest/internal/cli.Version=<v>".
Functions ¶
Types ¶
type Environment ¶
type Environment struct {
Getenv func(string) string
ReadFile func(string) ([]byte, error)
Git func(ctx context.Context, dir string, args ...string) ([]byte, error) // runs the git binary; replaceable in tests
Now func() time.Time
// Sleep waits between upload attempts; it returns early with the context's error.
Sleep func(context.Context, time.Duration) error
// Repository reads commits and evaluates ignore rules for freshness verification.
Repository graphimport.Git
}
Environment holds everything Run reads from outside the process.
func OSEnvironment ¶
func OSEnvironment() Environment
OSEnvironment is the real process environment.