# Shared rails app, svn, and local config? design question

**URL:** <https://www.ruby-forum.com/t/shared-rails-app-svn-and-local-config-design-question/115223>\
**Category:** Rails\
**Created:** [September 21, 2007, 11:01pm UTC](https://www.ruby-forum.com/t/shared-rails-app-svn-and-local-config-design-question/115223 "2007-09-21T23:01:30Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![jrochkind](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/779978/32.png) [@jrochkind](https://www.ruby-forum.com/u/jrochkind)\
**Post date:** [September 21, 2007, 11:01pm UTC](https://www.ruby-forum.com/t/shared-rails-app-svn-and-local-config-design-question/115223/1 "2007-09-21T23:01:30Z")

</div>

None of my questions seem to get any bits here, but let’s try another.  
🙂

I am working on a Rails app which we plan to distribute to lots of  
people. There will be a community of users. Many of these users will  
also be co-developers of this open source project. Others will not be,  
they’ll just take the app and install it.

Let’s consider the developer first. He checks my app, which we’ll call  
U, out of our shared svn.

But now he has lots of local config to do. Not only actual local config  
in the config/ directory, but he’s going to possibly add a few of his  
own models and his own controllers and own views too. (Pointed to by  
reference in some config, of course). This app we all share acts sort of  
like a ‘framework’, to the extent that local implementors can customize  
it by adding their own classes without actually changing the shared  
source code. They add local classes by writing their own local class,  
and then naming their local classes to be used in the config files. This  
is particularly clear in the case of ‘views’, maybe he adds a view to  
app/views/local/my\_layout.rhtml, and in environment.rb maybe it says  
"app\_config.use\_layout = ‘local/my\_layout’. (I’m using the AppConfig  
package for app-specific config).

So far so good. I have this all set up. But he checked the overall app  
out of SVN, and he’d like to leave it as an SVN working copy so he can  
continue getting updates and such. Meanwhile, he has all his own local  
implementatation stuff that he’d like to keep in his _own_ svn. And he’d  
like to be able to check all of his own local stuff out too in one (or  
few) svn commands. But his local stuff might be scattered all about, in  
models/, views/, controllers/, config/, etc.

I can think of a number of ways to do this, none satisfying me (and some  
only working on edge rails, which is undesirable to me). I’m curious if  
any other developers have similar projects, and how they’ve dealt with  
this issue.

Thanks for any ideas and especially for reports of how you are dealing  
with this.

---

<div class="post-metadata">

**Author:** ![jrochkind](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/779978/32.png) [@jrochkind](https://www.ruby-forum.com/u/jrochkind)\
**Post date:** [September 23, 2007, 1:03am UTC](https://www.ruby-forum.com/t/shared-rails-app-svn-and-local-config-design-question/115223/2 "2007-09-23T01:03:30Z")

</div>

Random thought

master\_app:/  
app:/  
models  
controllers  
views  
…

local\_app 😕  
app:/  
models  
controllers  
views

In the configuration for master\_app you add local\_app/app/models to  
config.load\_paths and you set template\_root in the controllers from  
local\_app to point at local\_app/app/views. I think there’s an equivalent  
setting so that rails will look for controllers in extra locations as  
well. You still have to edit environment.rb on master\_app but at least  
you can leave the other stuff alone.

Can’t say I’ve tried this but it might work.

Fred
