Subversion command reference.

This post is more to keep in a single place reference to useful subversion commands, for future development.
Anyone who has a command can comment this post, so I can add it here.

List all your local files that hasn’t been added to the repository yet.

vn st | grep ?

Add all your local files that hasn’t been added to the repository yet.

svn st | grep ? | cut -b7- | xargs svn add

or

svn add . –force

Send HTML formatted email messages for Subversion activity (see SVN-Notify website)

svnnotify -d -H HTML::ColorDiff --smtp myhost.com  --repos-path "$1" --revision "$2" -t dev1@myhost.com -t dev2@myhost.com

8 Comments »

  1. Tapajós said,

    April 2, 2008 @ 1:29 am

    You can create one script like that:

    #!/usr/bin/env ruby
    list = `svn status | grep -e '[?]'`
    list.gsub!("?" , '')
    list = list.split("n")
    files_to_add = []
    list.each { |file| files_to_add }
    
  2. Tapajós said,

    April 2, 2008 @ 1:58 am

    My comment is incomplete. The correct is:

    #!/usr/bin/env ruby
    list = `svn status | grep -e '[?]'`
    list.gsub!("?" , '')
    list = list.split("n")
    files_to_add = []
    list.each { |file| files_to_add }
    
  3. Tapajós said,

    April 2, 2008 @ 2:00 am

    Your blog has any problem to comment with code ?

  4. alexandre said,

    April 2, 2008 @ 2:40 am

    Surrounding you code with “pre” tag works fine. Thanks for your comments!

  5. Tapajós said,

    April 2, 2008 @ 12:42 pm

    #!/usr/bin/env ruby
    list = `svn status | grep -e ‘[?]’`
    list.gsub!(”\?” , ‘’)
    list = list.split(”\n”)
    files_to_add = []
    list.each { |file| files_to_add

  6. Tapajós said,

    April 2, 2008 @ 12:46 pm

    Problem again !

  7. Jose Peleteiro said,

    April 2, 2008 @ 2:23 pm

    Why not “svn add . –force” ?

  8. Guilherme Chapiewski said,

    April 2, 2008 @ 5:44 pm

    There’s a typo in the first comment :)

RSS feed for comments on this post · TrackBack URI

Leave a Comment