mirror of
https://github.com/hashicorp/terraform.git
synced 2026-03-03 22:10:40 -05:00
19 lines
396 B
Go
19 lines
396 B
Go
// Copyright (c) HashiCorp, Inc.
|
|
// SPDX-License-Identifier: BUSL-1.1
|
|
|
|
package arguments
|
|
|
|
import (
|
|
"flag"
|
|
"io/ioutil"
|
|
)
|
|
|
|
// defaultFlagSet creates a FlagSet with the common settings to override
|
|
// the flag package's noisy defaults.
|
|
func defaultFlagSet(name string) *flag.FlagSet {
|
|
f := flag.NewFlagSet(name, flag.ContinueOnError)
|
|
f.SetOutput(ioutil.Discard)
|
|
f.Usage = func() {}
|
|
|
|
return f
|
|
}
|