dev

package
v0.0.0-...-82de0c3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 23, 2022 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DevFileName = "dev.nix"
View Source
var ErrNoDevFile = errors.New("no dev.nix file found")

Functions

This section is empty.

Types

type Child

type Child struct {
	Path string            `json:"path"`
	Env  map[string]string `json:"env"`
}

type Config

type Config struct {
	Init     string             `json:"init"`
	Env      map[string]string  `json:"env"`
	Services map[string]Service `json:"services"`
	Children []Child            `json:"children"`
}

type Dev

type Dev struct {
	Path string
}

func Get

func Get(wd string) (Dev, error)

func (*Dev) DB

func (d *Dev) DB() *db.DB

func (*Dev) Init

func (d *Dev) Init()

func (*Dev) Start

func (d *Dev) Start()

func (*Dev) Stop

func (d *Dev) Stop()

type Logger

type Logger struct {
	Processes []db.Process
}

func NewLogger

func NewLogger(dev Dev, services ...string) (*Logger, error)

func (*Logger) Watch

func (l *Logger) Watch()

type ProcessLogEmitter

type ProcessLogEmitter struct {
	db.Process
	// contains filtered or unexported fields
}

func NewProcessLogEmitter

func NewProcessLogEmitter(process db.Process, logCh chan string) *ProcessLogEmitter

func (*ProcessLogEmitter) Write

func (e *ProcessLogEmitter) Write(p []byte) (int, error)

type Service

type Service struct {
	Cmd string            `json:"cmd"`
	Env map[string]string `json:"env"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL