-
Notifications
You must be signed in to change notification settings - Fork 1
Configuration
Pouya Eghbali edited this page Jul 7, 2021
·
8 revisions
You can create a .please.config.json or a .please/config.json file in your home directory to configure the functionality of Please. This configuration file can also set default values for the CLI interface flags.
Default configuration file is taken from the Please repo, based on the OS and the environment where the Please command is running. You can find default configs for each environment on the please repo. If there are no user defined configuration files, and a config file is not available for the current environment, the following configuration is then used:
{
"preferred": ["install", "prebuilt", "script", "build"],
"installWith": ["default"],
"useCNF": true,
"allowUnsafe": false,
"log": 1,
"silentInstall": true,
"update": true
}Here are the available configuration fields and a short description for each one of them:
| Config | Description |
|---|---|
| preferred | Which way of installation should Please use first? List them all in order, you can also exclude the ones you don't want to use at all. |
| installWith | What package manager should be used for installation? This is useful for platforms that support multiple package managers, for example ports or brew on macOS. The functionality for this option is not implemented, yet. |
| useCNF | Should we use CNF as a fallback? Or should we just use the Please repository? This option is enabled by default, but will be disabled as soon as we have a decent amount of commands in our official repository. |
| allowUnsafe | Allows unsafe installations from CNF. Turn this on only if you trust CNF |
| log | This sets the default log level for Please. You can override it using the --log CLI flag. |
| silent | Mutes all messages except errors, sets the log level to 1. You can override it using the --silent CLI flag. |
| verbose | Display all messages, sets the log level to 4. You can override it using the --verbose CLI flag. |
| silentInstall | Installation messages are ignored. You can override it using the --silent-install CLI flag. |
| silentRun | Command output is suppressed. You can override it using the --silent-run CLI flag. |
| update | Enables or disables updating the please repo. If enabled, Please pulls the latest changes from GitHub before each install. If git isn't enabled, the repo tarball will be used instead. You can override it using the --update CLI flag. |