Project repository best practices

43 views
Skip to first unread message

Sergio

unread,
Aug 12, 2013, 11:32:45 AM8/12/13
to calatrav...@googlegroups.com
Hi all


When working on a team project that is shared using a repository such as svn or git. What are the recommendations in terms of:

1) Does each developer has to do "calatrava create project"? Or just one developer has to do it and then commit the initial project?.

2) Which folder/files should be include into the repository? 

3) After checking out a calatrava projec, Which configuration files each developer should be aware of modify?

Thanks

Priyank Gupta

unread,
Aug 13, 2013, 12:07:06 PM8/13/13
to calatrav...@googlegroups.com
Hi Sergio,

Based on my development experience with Calatrava, here are the answers to your questions.

1. Only the first developer would need to create a Calatrava app. As part of setting up Calatrava the two commands that are run are bundle install and bundle exec rake bootstrap. I think all developers should run both. The first command will ensure all ruby gems are downloaded and configured locally. Second command will ensure that node modules (required for jasmine and feature automation) are set up correctly. In addition to that it would set up the basic config files. Some steps would have been completed in first run and in that scenario the resultant behavior for other developers would be idempotent so it wouldn't matter. 

2. I would say folllowing folders should be included in repository:
assets
config
features
ios
droid
kernel
shell
tasks
web

Also, the builds in individual platforms will create lots of folder that can be .gitignored or ignored from svn repository. Most of the time, following are popular choices
node_modules
droid/out
web/apache/conf/
ios/public/
artifacts/
.sass-cache/
web/apache/logs/
web/apache/public
config/result/
droid/libs/
droid/ivy/
droid/**/gen
droid/**/bin
droid/**/target

And other residual folders for each project. There are files in iOS project that would be user specific, those should be ignored as well. The thumb rule is that, actually libraries should be excluded, the generated files for each build should be excluded which would re-generate on next build locally, any user specific files and settings should be excluded and any temperory files should be excluded. And of course any sensitive information, that shouldn't be present in source control.

3. Usually Calatrava picks up configurations from environments.yml. This is where all the end point configurations live. In additions to that often to configure apache correctly you may need to make a change in httpd.conf.erb. This is present in <project-dir>/config/templates. Also for each new feature you need to add it in respective manifest.yml file.

./droid/manifest.yml
./ios/manifest.yml
./web/manifest.yml

Beyond this there can be custom project config files. 

I hope that helps.
Reply all
Reply to author
Forward
0 new messages