Skip to content

Commit

Permalink
Add missing probability flag
Browse files Browse the repository at this point in the history
  • Loading branch information
Felixoid committed Nov 4, 2024
1 parent 9de33eb commit b943a49
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions cmd/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,7 @@ func setDefaultConfig() {
viper.SetDefault("randomize", false)
viper.SetDefault("value", 10)
viper.SetDefault("deviation", 5)
viper.SetDefault("probability", 100)
viper.SetDefault("generators", []Custom{})
}

Expand Down
1 change: 1 addition & 0 deletions cmd/flags.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ func commonFlags(cmd *cobra.Command) {
f.Bool("randomize", viper.GetBool("randomize"), "toggle if starting point of generators should be randomized")
f.Float64("value", viper.GetFloat64("value"), "starting value for generators")
f.Float64("deviation", viper.GetFloat64("deviation"), "deviation for the next point in generator")
f.Uint8("probability", uint8(viper.GetUint("probability")), "probability of the points being sent, values in [1,100]")
f.Uint("step", viper.GetUint("step"), "generators interval in seconds")
}

Expand Down

0 comments on commit b943a49

Please sign in to comment.