Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GenerateToken ¶
GenerateToken returns a cryptographically random 32-byte hex string.
func LoadOrCreateToken ¶
LoadOrCreateToken reads the token from disk, or generates and persists a new one.
Types ¶
type BrowserOpener ¶ added in v0.7.0
BrowserOpener opens a URL in the browser. Extracted for testability.
type Request ¶
type Request struct {
Version string `json:"version"`
Token string `json:"token"`
Args []string `json:"args"`
Env map[string]string `json:"env,omitempty"`
}
Request is sent from the client to the daemon (one JSON line per connection).
type Response ¶
type Response struct {
Stdout string `json:"stdout"`
Stderr string `json:"stderr"`
ExitCode int `json:"exit_code"`
AwaitCallback bool `json:"await_callback,omitempty"`
Callback string `json:"callback,omitempty"`
}
Response is sent from the daemon back to the client (one or more JSON lines per connection).
Click to show internal directories.
Click to hide internal directories.