Random notes while learning web stuffs.. and others.

Thursday, August 28, 2008

Prepping Rails With Subversion - Part III

This is the third and last part of the guideline in preparing Rails with Subversion.

14. Do not "version control" the file database.yml. Navigate to config folder and rename database.yml to database.example.


15. Right-click the config folder and commit.



16. Ignore database.yml when it's re-created (renaming back database.example to database.yml)



17. Right-click config folder and commit


18. Ignore .project and .loadpath files. Navigate to the root, temporarily move these two files to location outside my_rail_app folder.


19. Right-click my_rail_app folder and commit.


20. Re-create and ignore .project file. Do the same with .loadpath file.




21. Navigate to the root, right-click my_rail_app and select SVN Commit.


22. Voila! we're done. Good luck with your Rails project with Subversion.


Wednesday, August 27, 2008

Prepping Rails With Subversion - Part II

This is the second part of the guideline in preparing Rails with Subversion. If you still remember, in part one we removed log files from our local working copy as well as from the repository. Now, we will re-create 'em.. yeah you heard me right!

6. This time we re-create log files to the log folder by simply moving back those relocated log files (done in step 4 of part I). Then, we ignore these log files by selecting them all, right-click and select TortoiseSVN -> Add to ignore list -> Ignore 4 items.



7. Update the log folder. Right-click the folder and select SVN Update.


8. Commit the changes done on the log folder. Right-click the folder and select SVN Commit.


9. We're done with log files, let's navigate now to tmp folder. We will ignore tmp folder with all its content (cache, pids, sessions, and sockets).


10. First, move the tmp folder to a location outside my_rail_app root folder.



11. Right-click my_rails_app folder and select SVN Commit



12. Re-create the tmp folder that was specified in step 10. Right-click the tmp folder and select TortoiseSVN -> Add to Ignore List -> tmp.


13. Right-click folder tmp and commit.


* The author wish to publish the part III of this guideline on the next post. See you then..

Prepping Rails With Subversion - Part I

This assumes Subversion repository and Rails project were already created. In this guideline, the Rails files were contained in my_rail_app folder on a Windows platform.

1. Import your rails application by going to the root. Right-click the folder e.g. my_rail_app, select TortoiseSVN then click Import.


You might be required to enter Username and Password for authentication.


2. For safe keeping, rename the folder containing your Rails application e.g. my_rail_app to my_rail_app_back. Then, create new empty folder named my_rail_app.


3. Check out your rails application. Right-click the empty my_rail_app folder, select SVN Checkout.


4. Navigate to the root of this freshly checked out working copy. Go to log folder and remove all log files (temporarily moved them outside my_rail_app folder).



5. Remove log files from Subversion by selecting the log folder, right-click and select SVN Commit.


*The author wish to publish part II of this guideline on the next post.