So you're saying to just exclude development.rb from being included
in SVN, then?
But it's not just stuff in that one file. For example, there's a reference
to "@host" in user_mailer.rb (restful_authentication) that needs to be
configured for each developer.
There's development.rb, production.rb etc... which allow you to have
per environment settings for stuff like that.
So you're saying to just exclude development.rb from being included
in SVN, then?
I wouldn't go that far - I got the impression from the example you
gave that you were more interested in production vs development
settings.
But it's not just stuff in that one file. For example, there's a
reference
to "@host" in user_mailer.rb (restful_authentication) that needs to be
configured for each developer.
Are you saying then that @host and any other desktop-local variables
anywhere should be set in environments/development.rb?
Something like the current host does sound like something that is part
of the environment, and hence fodder for development.rb. Obviously
this isn't so great if your going to have different ones for each
developer (which isn't something I've needed)
> So you're saying to just exclude development.rb from being included
> in SVN, then?
I wouldn't go that far - I got the impression from the example you
gave that you were more interested in production vs development
settings.
Well, not really -- there's settings for the production server, yes,
but there's also development-mode settings for the integration
server which will be different from those on each developer's
desktop.
Something like the current host does sound like something that is part
of the environment, and hence fodder for development.rb. Obviously
this isn't so great if your going to have different ones for each
developer (which isn't something I've needed)
I can't imagine any distributed team would *not* face this issue.
Modify config/environment.rb to load user specific configuration files..
since environment.rb is ruby, you can also add smarts to conditionally
load files on environment conditions, user defined properties, etc..
Everyone will still have the same version of config/environment.rb but
can have drastically different environments based on their own user
settings.
Our teams leverage an approach wherein we load data from config.yml.
In config,yml, we store all of our settings and ignore that in SVN. This config file is structured just like the database.yml file, but it contains every setting that could change, from authorize.net keys for cc processing to what type of email system to use (sendmail, smtp, etc). We then just load those into a hash stored in a constant in environment.rb
We can then use capistrano to build that file on the servers when we deploy it