jdevera/dotfiles

Allow installing only parts of the config

jdevera opened this issue · 2 comments

Split up the configuration in modules and allow disabling or enabling only some of them:

  • Bash
  • Vim
  • Git
  • Screen

Flags proposal:
--[no|with]-bash [Does not] install * configuration files
--[no|with]-vim [Does not] install * configuration files
--[no|with]-git [Does not] install * configuration files
--[no|with]-screen [Does not] install * configuration files

By default everything is installed. If any of the positive options is specified, then all modules are disabled except those specified:

  • bash install --with-vim should only install Vim configuration files.
  • bash install --no-vim should install everything except Vim configuration files.

This means that it makes no sense to have both positive and negative flags, even for different modules, e.g., bash install --with-screen --no-vim is equivalent to bash install --with-screen

What happens if --with-module and --no-module are both specified?

Not worth the effort, easiest way to do this is to remove all unwanted files after cloning the repository and before installation. then they can be checked out again if needed.