Configuration
Everything you can configure for doctor lives in two places: the arguments you pass to a command, and the doctor.json file in the root of your project. Both use the same names, so an option you know from the command line can be moved to the configuration file, and the other way around.
Where do settings live?
Section titled “Where do settings live?”| Command arguments | doctor.json |
|
|---|---|---|
| Example | doctor publish --url <url> |
{ "url": "<url>" } |
| Best for | Secrets and one-off runs | Everything which stays the same on every run |
| Scope | The command you are running | All commands in the project |
doctor init creates the doctor.json file for you, so you usually only need to pass the certificate (and its password) on each run.
Sections
Section titled “Sections”- CLI options: every argument you can pass to a
doctorcommand, grouped per authentication, all commands, and the publish command. - doctor.json: the settings which are configured as objects in the configuration file, like multilingual, site design, markdown rendering, partials, and the static navigation.
Minimal configuration
Section titled “Minimal configuration”{ "$schema": "https://raw.githubusercontent.com/estruyf/doctor/dev/schema/2.1.0.json", "url": "https://<tenant>.sharepoint.com/sites/<documentation>", "appId": "<appId>", "tenant": "<tenant>", "folder": "./src"}