Skip to content

Per-collection and per-profile configuration #732

@LucasPickering

Description

@LucasPickering

Discussed in #723

Some configuration fields should be overridable by collection and profile. Here's an example:

config:
  persist: false # Maybe this is a sensitive collection and you want nothing persist

profiles:
  dev:
    name: Dev
  staging:
    name: Staging
    config:
      theme:
        background_color: yellow
  prod:
    name: Prod
    config:
      theme:
        background_color: red

This would create a configuration hierarchy (lowest -> highest precedence):

  • Default values
  • Global config.yml
  • Collection config
  • Profile config

This would be useful for:

However, there are some config fields that absolute should NOT be overridden by collections, for security reasons:

  • ignore_certificate_hosts
  • commands.*
  • pager
  • editor

There are some fields that probably will not be useful to override by collection (e.g. input_bindings), but as long as it's not dangerous I'm inclined to allow it.

Metadata

Metadata

Assignees

No one assigned

    Labels

    qolImprovements that make usage smoother, without introducing new functionality

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions