Sunday, September 9, 2012

Common SVN Commands

Quick Sample: 

Checkout
Get the IP Address using ipconfig


Create a empty directory
Inside the directory, execute the checkout.

svn checkout http://192.168.30.131/repos/kernel/branches/SPI_Kernel .
Note the difference a "." makes.

The svn check out will ask for username and password.

This creates:
checkout with the latest revision.
...


Commit
svn commit -m "some comments"

Update
svn update

Add 
svn add "some file here..."


Saturday, September 8, 2012

Migrating SVN respository (Linux to Linux)

Below is the steps to migrate SVN repository:-
  • Start your terminal
  • $ svnadmin dump /path/to/your/repo > yourreporname.dump
  • $tar -zcf yourreponame.tgz yourreponame.dump 

    Tar command for compress:

    This steps is to transfer your dump file to your new machine. You will prompt to enter password for the new machine.
  • * For large dump file , you can compress it using tar before sending over thru network.
    Tar command for uncompress:
    tar -zxf yourreporname.tgz

    Tar command for uncompress:
    
    
    $ scp yourreponame.dump username@new.machine.ip:/path/to/your/new/repo 
  • 
    
  • Now your SVN dump file should be in new machine
  • Login to your new machine
  • cd /path/to/your/new/repo
  • svnadmin create reponame
  • svnadmin load reponame < yourreponame.dump
  • Done, you just just migrated your svn repository