Toolsync

Configuration

How to configure Toolsync in your project.


Everything is a plugin

First of all, Toolsync is heavily based on plugins. Even internally:

  • @toolsync/core contains a plugin that defines how to load modules.
  • @toolsync/cli contains a plugin that injects command line options into the runtime configuration and one to load toolsync.json files.
  • @toolsync/builtin contains plugins for each of the built-in tools.

Enable plugins

As soon as you add a plugin's name to your toolsync.json file, it will be enabled. When running the command line interface, you can also enable plugins with the --plugin flag.

toolsync.json
{
  "name of the plugin": {}
}
toolsync --plugin name-of-the-plugin [options] [command]

Configure plugins

The easiest way to configure Toolsync is to use the toolsync.json file in the root of your project. This file is a JSON object where each key is a plugin name and the value is the configuration for that plugin:

toolsync.json
{
  "name of the plugin": {
    "option": "value"
  }
}

Check out the plugin's documentation for the available configuration options.

Examples

toolsync.json
{
  "@toolsync/builtin/prettier": {
    "settings": {
      "printWidth": 100,
      "singleQuote": true
    }
  }
}

Debugging config

If you want to see which plugins are loaded and how they are configured, you can use the @evtools/cli config command:

toolsync config

For general debugging, see the Debugging page.


Found an issue? Have a suggestion? Open an issue on GitHub ✨.