engine: Pass through the program version
We forgot this in a few places.
This commit is contained in:
@@ -43,6 +43,7 @@ const (
|
|||||||
// Engine encapsulates a generic graph and manages its operations.
|
// Engine encapsulates a generic graph and manages its operations.
|
||||||
type Engine struct {
|
type Engine struct {
|
||||||
Program string
|
Program string
|
||||||
|
Version string
|
||||||
Hostname string
|
Hostname string
|
||||||
World engine.World
|
World engine.World
|
||||||
|
|
||||||
@@ -198,6 +199,7 @@ func (obj *Engine) Commit() error {
|
|||||||
Vertex: vertex,
|
Vertex: vertex,
|
||||||
|
|
||||||
Program: obj.Program,
|
Program: obj.Program,
|
||||||
|
Version: obj.Version,
|
||||||
Hostname: obj.Hostname,
|
Hostname: obj.Hostname,
|
||||||
|
|
||||||
World: obj.World,
|
World: obj.World,
|
||||||
|
|||||||
@@ -40,6 +40,7 @@ type State struct {
|
|||||||
Vertex pgraph.Vertex
|
Vertex pgraph.Vertex
|
||||||
|
|
||||||
Program string
|
Program string
|
||||||
|
Version string
|
||||||
Hostname string
|
Hostname string
|
||||||
World engine.World
|
World engine.World
|
||||||
|
|
||||||
@@ -154,6 +155,7 @@ func (obj *State) Init() error {
|
|||||||
|
|
||||||
obj.init = &engine.Init{
|
obj.init = &engine.Init{
|
||||||
Program: obj.Program,
|
Program: obj.Program,
|
||||||
|
Version: obj.Version,
|
||||||
Hostname: obj.Hostname,
|
Hostname: obj.Hostname,
|
||||||
|
|
||||||
// Watch:
|
// Watch:
|
||||||
|
|||||||
@@ -87,6 +87,9 @@ type Init struct {
|
|||||||
// Program is the name of the program.
|
// Program is the name of the program.
|
||||||
Program string
|
Program string
|
||||||
|
|
||||||
|
// Version is the version of the program.
|
||||||
|
Version string
|
||||||
|
|
||||||
// Hostname is the uuid for the host.
|
// Hostname is the uuid for the host.
|
||||||
Hostname string
|
Hostname string
|
||||||
|
|
||||||
|
|||||||
@@ -70,6 +70,7 @@ type CliInfo struct {
|
|||||||
// Data is the set of input values passed into the GAPI structs via Init.
|
// Data is the set of input values passed into the GAPI structs via Init.
|
||||||
type Data struct {
|
type Data struct {
|
||||||
Program string // name of the originating program
|
Program string // name of the originating program
|
||||||
|
Version string // version of the originating program
|
||||||
Hostname string // uuid for the host, required for GAPI
|
Hostname string // uuid for the host, required for GAPI
|
||||||
World engine.World
|
World engine.World
|
||||||
Noop bool
|
Noop bool
|
||||||
|
|||||||
@@ -178,6 +178,7 @@ func (obj *GAPI) Init(data *gapi.Data) error {
|
|||||||
|
|
||||||
dataLang := &gapi.Data{
|
dataLang := &gapi.Data{
|
||||||
Program: obj.data.Program,
|
Program: obj.data.Program,
|
||||||
|
Version: obj.data.Version,
|
||||||
Hostname: obj.data.Hostname,
|
Hostname: obj.data.Hostname,
|
||||||
World: obj.data.World,
|
World: obj.data.World,
|
||||||
Noop: obj.data.Noop,
|
Noop: obj.data.Noop,
|
||||||
@@ -189,6 +190,7 @@ func (obj *GAPI) Init(data *gapi.Data) error {
|
|||||||
}
|
}
|
||||||
dataPuppet := &gapi.Data{
|
dataPuppet := &gapi.Data{
|
||||||
Program: obj.data.Program,
|
Program: obj.data.Program,
|
||||||
|
Version: obj.data.Version,
|
||||||
Hostname: obj.data.Hostname,
|
Hostname: obj.data.Hostname,
|
||||||
World: obj.data.World,
|
World: obj.data.World,
|
||||||
Noop: obj.data.Noop,
|
Noop: obj.data.Noop,
|
||||||
|
|||||||
@@ -490,6 +490,7 @@ func (obj *Main) Run() error {
|
|||||||
|
|
||||||
obj.ge = &graph.Engine{
|
obj.ge = &graph.Engine{
|
||||||
Program: obj.Program,
|
Program: obj.Program,
|
||||||
|
Version: obj.Version,
|
||||||
Hostname: hostname,
|
Hostname: hostname,
|
||||||
World: world,
|
World: world,
|
||||||
Prefix: fmt.Sprintf("%s/", path.Join(prefix, "engine")),
|
Prefix: fmt.Sprintf("%s/", path.Join(prefix, "engine")),
|
||||||
@@ -579,6 +580,7 @@ func (obj *Main) Run() error {
|
|||||||
|
|
||||||
data := &gapi.Data{
|
data := &gapi.Data{
|
||||||
Program: obj.Program,
|
Program: obj.Program,
|
||||||
|
Version: obj.Version,
|
||||||
Hostname: hostname,
|
Hostname: hostname,
|
||||||
World: world,
|
World: world,
|
||||||
Noop: mainDeploy.Noop,
|
Noop: mainDeploy.Noop,
|
||||||
|
|||||||
Reference in New Issue
Block a user