Skip to content

Commit

Permalink
puppeth exit with error code when fails
Browse files Browse the repository at this point in the history
  • Loading branch information
wanwiset25 committed Dec 20, 2023
1 parent ef0be66 commit 78c8d23
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions cmd/puppeth/wizard_genesis_file.go
Original file line number Diff line number Diff line change
Expand Up @@ -99,12 +99,14 @@ func (w *wizard) makeGenesisFile() {
configFile, err := ioutil.ReadFile(w.options.filePath)
if err != nil {
fmt.Println("read file error ", err)
os.Exit(1)
return
}
var input = NewGenesisInput()
// Unmarshal our input YAML file
if err := yaml.Unmarshal(configFile, &input); err != nil {
fmt.Println("parse YAML error ", err)
os.Exit(1)
return
}
SetDefaultAfterInputRead(input)
Expand Down

0 comments on commit 78c8d23

Please sign in to comment.