CHAPTER 17 ■ VERSION CONTROL WITH SUBVERSION
In a real-world situation, I would probably start out by adding some content to Question.php. Here, I
confine myself to creating an empty file using the standard touch command. Once I have added a
document, I must still invoke the commit subcommand to complete the addition.
$ svn commit -m'initial checkin'
Adding quizobjects/Question.php
Transmitting file data.
Committed revision 5.
Question.php is now in the repository.
Removing a File
Should I discover that I have been too hasty and need to remove the document, it should come as no
surprise to learn that you can use a subcommand called remove.
$ svn remove quizobjects/Question.php
D quizobjects/Question.php
Once again, a commit is required to finish the job.
$ svn commit -m'removed Question'
Deleting quizobjects/Question.php
Committed revision 6.
Adding a Directory
You can also add and remove directories with add and remove. Let’s say Bob wants to make a new
directory available:
$ mkdir resources
$ touch resources/blah.gif
$ svn add resources/
A resources
A resources/blah.gif
Notice how the contents of resources are added automatically to the repository.
findme