How to dump our default config file to a 'sample configs' directory when project builds?

22 Views Asked by At

Our project can load up to 4 different type of config files from a directory. To make it easier for users to understand the formats of these various files I wanted to copy all our default files into some sort of example config directory they could look at. This directory wouldn't be read, it would just give examples of the various configurations they could tweak and dump to the user or global config directories.

We already have a config directory inside our code, so it's as simple as making that be dumped out by out by our setup.py at build time, preferable renaming it to example_configs or something. I assume this would be done via either package_data or package_dir variables, however the official documentation doesn't do a good job of defining these fields and what they accept as arguments.

Any hints on how to ensure these config files get put somewhere that they can easily be found after we do a build?

0

There are 0 best solutions below