CLI backend to manage layout and inputs
Signed-off-by: Solomon Hykes <sh.github.6811@hykes.org>
This commit is contained in:
@@ -33,7 +33,7 @@ var downCmd = &cobra.Command{
|
||||
|
||||
// TODO: Implement options: --no-cache
|
||||
if err := route.Down(ctx, nil); err != nil {
|
||||
lg.Fatal().Err(err).Str("route-name", routeName).Str("route-id", route.ID).Msg("failed to up the route")
|
||||
lg.Fatal().Err(err).Str("route-name", routeName).Str("route-id", route.ID()).Msg("failed to up the route")
|
||||
}
|
||||
},
|
||||
}
|
||||
|
@@ -37,12 +37,12 @@ var newCmd = &cobra.Command{
|
||||
if err != nil {
|
||||
lg.Fatal().Err(err).Msg("failed to create route")
|
||||
}
|
||||
lg.Info().Str("route-id", route.ID).Str("route-name", routeName).Msg("created route")
|
||||
lg.Info().Str("route-id", route.ID()).Str("route-name", routeName).Msg("created route")
|
||||
|
||||
if upRoute {
|
||||
lg.Info().Str("route-id", route.ID).Msg("bringing route online")
|
||||
lg.Info().Str("route-id", route.ID()).Msg("bringing route online")
|
||||
if err := route.Up(ctx, nil); err != nil {
|
||||
lg.Fatal().Err(err).Str("route-id", route.ID).Msg("failed to create route")
|
||||
lg.Fatal().Err(err).Str("route-id", route.ID()).Msg("failed to create route")
|
||||
}
|
||||
}
|
||||
},
|
||||
|
@@ -36,7 +36,7 @@ var queryCmd = &cobra.Command{
|
||||
|
||||
out, err := route.Query(ctx, expr, nil)
|
||||
if err != nil {
|
||||
lg.Fatal().Err(err).Str("route-name", routeName).Str("route-id", route.ID).Msg("failed to query route")
|
||||
lg.Fatal().Err(err).Str("route-name", routeName).Str("route-id", route.ID()).Msg("failed to query route")
|
||||
}
|
||||
|
||||
fmt.Println(out)
|
||||
|
@@ -33,7 +33,7 @@ var upCmd = &cobra.Command{
|
||||
|
||||
// TODO: Implement options: --no-cache
|
||||
if err := route.Up(ctx, nil); err != nil {
|
||||
lg.Fatal().Err(err).Str("route-name", routeName).Str("route-id", route.ID).Msg("failed to up the route")
|
||||
lg.Fatal().Err(err).Str("route-name", routeName).Str("route-id", route.ID()).Msg("failed to up the route")
|
||||
}
|
||||
},
|
||||
}
|
||||
|
Reference in New Issue
Block a user