Newer Version Available

This content describes an older version of this product. View Latest

config:set

Sets the configuration variables that the Salesforce CLI uses for various commands and tasks.

Help for config:set

Local variables apply only to your current project. Global variables apply in any directory.

Examples for config:set

sfdx config:set defaultusername=me@my.org defaultdevhubusername=me@myhub.org

sfdx config:set defaultdevhubusername=me@myhub.org -g

Command Syntax

sfdx config:set
[--json]
[--loglevel LOGLEVEL]
[-g]

Parameters

--json
Optional

Format output as JSON.

Type: boolean
--loglevel LOGLEVEL
Optional

The logging level for this command invocation. Logs are stored in $HOME/.sfdx/sfdx.log.

Type: enum
Permissible values are: trace, debug, info, warn, error, fatal, TRACE, DEBUG, INFO, WARN, ERROR, FATAL
Default value: warn
-g | --global
Optional

Sets the configuration variables globally, so they can be used from any directory.

Type: boolean

Aliases for config:set

1force:config:set