One thing I can think of is similar to method 2 and method 1 above. Where you have a directory that stores complex things unique to the site, such as directories for configuration files, user-uploaded files, etc.
You save only the configuration file itself outside of version control, but then you have a dummy copy that is slightly different from what the site actually uses, and this file contains detailed instructions on the configuration parameters and make a renamed copy.
For example, let's say you have a site_profile directory. In this directory, you create a file called "README.settings.php" along with the "files" directory, which contains the files uploaded by the user (both for administrators and front-end users). All of this is under version control.
However, the site will launch its settings with "settings.php", which will not be here. But if you rename "README.settings.php" to "settings.php", then you will have the necessary configuration file (after you, of course, make your user settings).
This will allow you to tell other developers what they need from their configuration file, while maintaining their own configuration file. Just set your configuration file to ignore or never commit the protective layer for this directory and below.
This is what we do with the Drupal sites where I work, and it works very well.
pthurmond Jul 21 '11 at 20:18 2011-07-21 20:18
source share