configuration
packageThis package is not in the latest version of its module.
Details
Validgo.mod file
The Go module system was introduced in Go 1.11 and is the official dependency management solution for Go.
Redistributable license
Redistributable licenses place minimal restrictions on how software can be used, modified, and redistributed.
Tagged version
Modules with tagged versions give importers more predictable builds.
Stable version
When a project reaches major version v1 it is considered stable.
- Learn more about best practices
Repository
Links
Documentation¶
Index¶
- Variables
- func BindFlags(cmd *cobra.Command, settings *viper.Viper)
- func BuiltinToolsDirectories(settings *viper.Viper) paths.PathList
- func DataDir(settings *viper.Viper) *paths.Path
- func DownloadsDir(settings *viper.Viper) *paths.Path
- func FindConfigFileInArgs(args []string) string
- func GetDefaultBuiltinLibrariesDir() string
- func HardwareDirectories(settings *viper.Viper) paths.PathList
- func IDEBuiltinLibrariesDir(settings *viper.Viper) *paths.Path
- func Init(configFile string) *viper.Viper
- func LibrariesDir(settings *viper.Viper) *paths.Path
- func NetworkProxy(settings *viper.Viper) (*url.URL, error)
- func PackagesDir(settings *viper.Viper) *paths.Path
- func ProfilesCacheDir(settings *viper.Viper) *paths.Path
- func SetDefaults(settings *viper.Viper)
- func UserAgent(settings *viper.Viper) string
Constants¶
This section is empty.
Variables¶
var HasConsole = isatty.IsTerminal(os.Stdout.Fd()) || isatty.IsCygwinTerminal(os.Stdout.Fd())HasConsole is set to true if the CLI outputs to a terminal/console
var IsInteractive = isatty.IsTerminal(os.Stdin.Fd()) || isatty.IsCygwinTerminal(os.Stdin.Fd())IsInteractive is set to true if the CLI is interactive (it can receive inputs from terminal/console)
var Settings *viper.ViperSettings is a global instance of viper holding configurations for the CLI and the gRPC consumers
Functions¶
funcBindFlags¶
BindFlags creates all the flags binding between the cobra Command and the instance of viper
funcBuiltinToolsDirectories¶
BuiltinToolsDirectories returns all paths that may contains bundled-tools.
funcDownloadsDir¶
DownloadsDir returns the full path to the download cache directory
funcFindConfigFileInArgs¶
FindConfigFileInArgs returns the config file path using theargument '--config-file' (if specified) or looking in the current working dir
funcGetDefaultBuiltinLibrariesDir¶
func GetDefaultBuiltinLibrariesDir()string
GetDefaultBuiltinLibrariesDir returns the full path to the default builtin libraries dir
funcHardwareDirectories¶
HardwareDirectories returns all paths that may contains hardware packages.
funcIDEBuiltinLibrariesDir¶
IDEBuiltinLibrariesDir returns the IDE-bundled libraries path. Usuallythis directory is present in the Arduino IDE.
funcInit¶
Init initialize defaults and read the configuration file.Please note the logging system hasn't been configured yet,so logging shouldn't be used here.
funcLibrariesDir¶
LibrariesDir returns the full path to the user directory containingcustom libraries
funcNetworkProxy¶
NetworkProxy returns the proxy configuration (mainly used by HTTP clients)
funcPackagesDir¶
PackagesDir returns the full path to the packages folder
funcProfilesCacheDir¶
ProfilesCacheDir returns the full path to the profiles cache directory(it contains all the platforms and libraries used to compile a sketchusing profiles)
funcSetDefaults¶
SetDefaults sets the default values for certain keys
Types¶
This section is empty.