mirror of
https://github.com/jwetzell/showbridge-go.git
synced 2026-04-26 21:05:30 +00:00
fix import
This commit is contained in:
@@ -8,6 +8,7 @@ import (
|
|||||||
"os/signal"
|
"os/signal"
|
||||||
|
|
||||||
"github.com/jwetzell/showbridge-go"
|
"github.com/jwetzell/showbridge-go"
|
||||||
|
"github.com/jwetzell/showbridge-go/internal/config"
|
||||||
"github.com/urfave/cli/v3"
|
"github.com/urfave/cli/v3"
|
||||||
"sigs.k8s.io/yaml"
|
"sigs.k8s.io/yaml"
|
||||||
)
|
)
|
||||||
@@ -54,18 +55,18 @@ func main() {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func readConfig(configPath string) (showbridge.Config, error) {
|
func readConfig(configPath string) (config.Config, error) {
|
||||||
|
config := config.Config{}
|
||||||
|
|
||||||
configBytes, err := os.ReadFile(configPath)
|
configBytes, err := os.ReadFile(configPath)
|
||||||
|
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return showbridge.Config{}, err
|
return config, err
|
||||||
}
|
}
|
||||||
|
|
||||||
config := showbridge.Config{}
|
|
||||||
|
|
||||||
err = yaml.Unmarshal(configBytes, &config)
|
err = yaml.Unmarshal(configBytes, &config)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return showbridge.Config{}, err
|
return config, err
|
||||||
}
|
}
|
||||||
|
|
||||||
return config, nil
|
return config, nil
|
||||||
|
|||||||
Reference in New Issue
Block a user