Difference between revisions of "Subversion"

From Embedded Xinu
Jump to navigation Jump to search
m (Repo moved to Subversion Primer: More descriptive name.)
(Marked page as historical (due to switch to git))
 
(12 intermediate revisions by 2 users not shown)
Line 1: Line 1:
Within the repo directory
+
{{Historical}}
/usr/local/project/EmbeddedOS/repo
 
  
If you even forget a subversion command there are some posted in the 310 lab, or you can come here.
+
A [http://acm.mscs.mu.edu/wiki/Subversion general use guide] is now available on the [http://acm.mscs.mu.edu/ Student ACM Wiki].  Also there is a posting of commands in the Cudahy 310 Computer Lab.
  
To check out your branch into the directory of your choice, type
+
Xinu specific information about the repository is available in the [[trac:Subversion|trac wiki]].
svn checkout file:///usr/local/project/EmbeddedOS/repo/xinu-mips/trunk ~/xinu-mips
 
of course ~/xinu-mips can be whatever directory you wish to store your code.
 
 
 
Now you have a private working copy of your branch in <tt>~/xinu-mips</tt>.
 
 
 
Most svn commands should be executed from your working copy, so lets
 
cd ~/xinu-mips
 
 
 
The first thing you will want to do before you start working is run:
 
svn update
 
or
 
svn up
 
this will update all the files any one may have changed.
 
 
 
Along with update, when you finish making changes you must commit
 
them, this is done with
 
svn commit
 
or
 
svn ci
 
This should open up the editor of your choice (well whatever the system variable $EDITOR is set to), and you can type a log message which catalogs the changes you made.
 
 
 
Before you commit you should usually run
 
svn status
 
or
 
svn st
 
to see what changes are going to be made.  Each change is pre-pended with a character, usually M but sometimes it can be ?, !, A, or D (there are more, but they are less common).  ? means svn is unsure what to do, odds are you have added that file since the last update, you must tell svn to add it by running
 
svn add <file-path>
 
! similarly means that the file is missing and you probably deleted it, so
 
svn rm <file-path>
 
should do the trick, these commands will change the ? or ! into A or
 
D, respectively.
 
 
 
Another important letter is C, which means conflict and that you have
 
to figure out what went wrong with the file, if you didn't make any
 
huge changes or don't mind losing your changes you can
 
svn revert <file-path>
 
to revert to the latest revision you have, otherwise I suggest reading
 
up on it through svn help or the Internet.
 
 
 
You can type svn help for a list of commands and
 
svn help <command>
 
for help on a specific command.
 
 
 
I think that covers the majority of command to be used, if you want to
 
know more you can go to
 
<http://svnbook.red-bean.com/en/1.2/svn-book.html> which has
 
everything you want.
 

Latest revision as of 22:00, 11 September 2013

✘ This page is currently inactive and is retained primarily for historical interest.
A historical page is usually one that is no longer maintained or no longer relevant.

A general use guide is now available on the Student ACM Wiki. Also there is a posting of commands in the Cudahy 310 Computer Lab.

Xinu specific information about the repository is available in the trac wiki.