forgepb/structs.go

35 lines
1.0 KiB
Go

package forgepb
import (
sync "sync"
"go.wit.com/lib/protobuf/gitpb"
)
// maybe an interface someday?
type Forge struct {
// one-time initialized data
once sync.Once
initErr error // init error, if any
goWork bool // means the user is currently using a go.work file
Config *ForgeConfigs // config repos for readonly, private, etc
Repos *gitpb.Repos // the repo protobufs
configSave bool // if you need to save the config because things changed
hostname string // your hostname
rillX int // used for Rill()
rillY int // used for Rill()
Patchsets *Patchsets // patches that are in progress
goSrc string // the path to go/src
// forgeURL string // URL to use to forge.wit.com
// configDir string // normally ~/.config/forge
// patchDir string // where patches are stored
}
func (f *Forge) GetGoSrc() string {
return f.goSrc
}
func (f *Forge) IsGoWork() bool {
return f.goWork
}