foundryvtt-cli icon indicating copy to clipboard operation
foundryvtt-cli copied to clipboard

Feature Request: support multiple configuration files

Open rsek opened this issue 1 year ago • 0 comments

Hi there. I use the CLI to work on multiple packages. Editing this file every time I switch packages is error-prone. I'd like it if there was a way to load a specific configuration file instead.

The most basic version of that might be an option that's appended to any command, e.g.: fvtt launch --config ./my/config/path/my-package.fvttrc.yml. It'd be convenient if there was a way to create a new config file in a specific location, too.

The ideal version

I'd love some kind of local config autodetection, paralleling other common Node developer dependencies. That way, I can just add ./fvttrc.yml to each package's .gitignore, rather than having to remember (always a gamble for me, TBH) to switch configurations each time.

Example

Say the CLI is installed to my_project/node_modules.

  1. if the CLI is invoked with a specific --config, it uses the specified path
  2. if no config was specified, it then checks for a local configuration at my_project/.fvttrc.yml
  3. if no local config is available, it falls back to its current behavior and uses the global configuration (if available).

rsek avatar Oct 10 '23 17:10 rsek