cookbook: importing a symfony project into subversion
Translation of the original in Catalan. Read it in: CatalàCastellano
A small cookbook on how we have to import a project we're programming with the symfony framework. First we create the repository directory where we want to upload the project, we go to the project directory. We delete the log and cache directories, which we're not interested in keeping under version control. And then we import the project.
svn mkdir -m "NOTA: Creem directori on hi posarem projecte" http://exemple.com/svn/repos/projecte/dev
cd directori_projecte_symfony
rm -rf log
rm -rf cache
svn import -m "NOTA: importem primera versio del projecte" . http://exemple.com/svn/repos/projecte/dev
Now we move the project's current directory and create a new one, which will now be under version control. We do a checkout (co) of the version we imported before and define that the log and cache directories will never be imported when we do a commit (ci). Then we create the directories in question and assign them an owner equal to that of the apache process so that it can write to them while it is running our symfony project.
mv directori_projecte_symfony directori_projecte_symfony.bak
mkdir directori_projecte_symfony_amb_svn
cd directori_projecte_symfony_amb_svn
svn co http://exemple.com/svn/repos/projecte/dev .
svn propedit svn:ignore .
log
cache
mkdir log
mkdir cache
chown apache:apache log
chown apache:apache cache