Skip to content

Commit

Permalink
add option to disable reading from stdin in code
Browse files Browse the repository at this point in the history
  • Loading branch information
reubenmiller committed May 17, 2024
1 parent 0f17a6c commit 72bb282
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions pkg/config/cliConfiguration.go
Original file line number Diff line number Diff line change
Expand Up @@ -1469,6 +1469,11 @@ func (c *Config) DisableStdin() bool {
return c.viper.GetBool(SettingsDisableInput)
}

// Change the disable stdin value
func (c *Config) SetDisableStdin(v bool) {
c.viper.Set(SettingsDisableInput, v)
}

// AllowEmptyPipe check if empty piped data is allowed
func (c *Config) AllowEmptyPipe() bool {
return c.viper.GetBool(SettingsAllowEmptyPipe)
Expand Down

0 comments on commit 72bb282

Please sign in to comment.