Subversion for Mac OSX
1. Open the Terminal: Applications -> Terminal
2. Set the correct path in the Terminal window:
export PATH=$PATH:/usr/local/bin
3. Test by entering svn in Terminal window.
Output should be something like: Type 'svn help' for usage. If (path) is correct.
Otherwise it will be: -bash: svn: command not found
4. Create a repository
svnadmin create /Volumes/MainBackUp/svn/monopoly
Creates files necessary for Subversion
5. Initial import
svn import -m "Initial import." /Users/russell/Documents/workspace/MONOPOLY
file:///Volumes/MainBackUp/svn/monopoly
This populates repository with contents of chosen folder.
6. Checking Out A Working Copy
Navigate to correct folder
cd /Users/russell/Desktop/test
svn checkout file:///Volumes/MainBackUp/svn/monopoly
Populates chosen folder with contents of repository.
GENERAL COMMANDS
Navigate in the Treminal to the correct folder for the following commands:
svn status (Gives overview of changes, use to check folder is working copy)
svn commit NewClass.as –m “New Class committed” (Commits new file with log message)
svn add AnotherClass.as (Adds, new file to Subversion)
Terminal Outputs: A AnotherClass.as
svn status --verbose (gives detailed information of each file and its revision number, will show ‘mixed revisions’)
svn log (Shows log messages)
svn move oldfilename newfilename (Replaces old with new filename)
svn mkdir (Makes a new directory)
svn delete StateVieo.as (Deletes file)
Terminal Outputs: D StateVieo.as
svn delete –force StateVieo.as (If above method fails this will force the deletion)
svn rm State.as (Removes file from Subversion)
svn update –-revision 14 (Updates to specific revision number)
svn list file:///Volumes/MainBackUp/svn/GOF_VIDEO_2 (Lists top level files/ folders in chosen path)
Outputs:
.as2_classpath
.classpath
.project
.settings/
assets/
src/
svn list file:///Volumes/MainBackUp/svn/GOF_VIDEO_2/assets -R (-R Stands for Recursive – will lists all level files/ folders within chosen path)
Outputs:
test/
test/newTest.txt
video/
video/ClearExternalAll.swf
video/video_state.swf
video/video_working.swf
Labels: svn mac osx terminal

0 Comments:
Post a Comment
<< Home