Tag: sourceedit |
|||
(10 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
+ | ==ref & doc== |
||
+ | *http://svnbook.red-bean.com/en/1.6/svn-book.html -- svn 1.6 document |
||
+ | |||
+ | ==svn help== |
||
+ | svn help |
||
+ | usage: svn <subcommand> [options] [args] |
||
+ | 'svn help <subcommand>' for help on a specific subcommand |
||
+ | 'svn --version' to see the program version and RA modules |
||
+ | |||
+ | Available subcommands: |
||
+ | add |
||
+ | blame (praise, annotate, ann) |
||
+ | cat |
||
+ | ... |
||
+ | |||
+ | * help for subcommand |
||
+ | svn help <subcommand> |
||
+ | #eg. |
||
+ | svn help swtich |
||
+ | |||
+ | ==svn switch == |
||
+ | * switch working copy to different url within same repository. |
||
+ | svn switch http://10.90.0.160/svn/mobileapps-spotlight/branches/i24 spotlight/ |
||
+ | |||
+ | == svn merge == |
||
+ | * manual merge html5 1.4 to 2.0 |
||
+ | svn co http://10.90.0.160/svn/mobileapps-news-pro-html/branches/2.0 mobileapps-news-pro-html-2.0 |
||
+ | svn merge --accept postpone -r 358773:364929 http://10.90.0.160/svn/mobileapps-news-pro-html/branches/1.4 mobileapps-news-pro-html-2.0 |
||
+ | ## manual resolved conflcts |
||
+ | svn status mobileapps-news-pro-html-2.0 |
||
+ | svn resolved ... |
||
+ | svn commit -m "manual merge html1.4 to 2.0" mobileapps-news-pro-html-2.0 |
||
+ | |||
==svn diff for 2 branches == |
==svn diff for 2 branches == |
||
svn diff http://REPOS/trunk http://REPOS/branches/B |
svn diff http://REPOS/trunk http://REPOS/branches/B |
||
+ | |||
+ | ==svn resolve tree conflict == |
||
+ | svn resolve --accept working -R <path> |
||
+ | |||
+ | *resolve asks svn to resolve the conflict |
||
+ | *accept working specifies to keep your working files |
||
+ | *-R stands for recursive |
||
+ | |||
+ | ==resolve local edit, incoming delete upon update == |
||
+ | $ svn st |
||
+ | ! C foo |
||
+ | > local delete, incoming delete upon update |
||
+ | ! C bar |
||
+ | > local delete, incoming delete upon update |
||
+ | |||
+ | $ touch foo bar |
||
+ | |||
+ | $ svn st |
||
+ | A + C foo |
||
+ | > local edit, incoming delete upon update |
||
+ | A + C bar |
||
+ | > local edit, incoming delete upon update |
||
+ | |||
+ | $ svn st |
||
+ | ? foo |
||
+ | ? bar |
||
+ | |||
+ | $ rm foo bar |
||
+ | $ svn st |
||
+ | |||
+ | ==svn empmty checkout == |
||
+ | *you can limit the amount of files that do get checked out with the --depth |
||
+ | svn co --depth=empty http://myserver/myrepos/mydirectory |
||
+ | |||
+ | ==svn blame == |
||
+ | svn blame someurl |
||
+ | |||
+ | ==svn log -v -r == |
||
+ | * get revision detail info |
||
+ | svn log -v -r rev. http://repo-url |
||
+ | |||
+ | ==svn status code == |
||
+ | * http://gotofritz.net/blog/howto/svn-status-codes/ |
||
+ | |||
+ | ==svn checkout specify revision file == |
||
+ | svn checkout <url_of_big_dir>@revision <target> --depth empty |
||
+ | cd <target> |
||
+ | svn up <file_you_want> |
Latest revision as of 08:24, 22 July 2015
ref & doc[]
- http://svnbook.red-bean.com/en/1.6/svn-book.html -- svn 1.6 document
svn help[]
svn help usage: svn <subcommand> [options] [args] 'svn help <subcommand>' for help on a specific subcommand 'svn --version' to see the program version and RA modules Available subcommands: add blame (praise, annotate, ann) cat ...
- help for subcommand
svn help <subcommand> #eg. svn help swtich
svn switch[]
- switch working copy to different url within same repository.
svn switch http://10.90.0.160/svn/mobileapps-spotlight/branches/i24 spotlight/
svn merge[]
- manual merge html5 1.4 to 2.0
svn co http://10.90.0.160/svn/mobileapps-news-pro-html/branches/2.0 mobileapps-news-pro-html-2.0 svn merge --accept postpone -r 358773:364929 http://10.90.0.160/svn/mobileapps-news-pro-html/branches/1.4 mobileapps-news-pro-html-2.0 ## manual resolved conflcts svn status mobileapps-news-pro-html-2.0 svn resolved ... svn commit -m "manual merge html1.4 to 2.0" mobileapps-news-pro-html-2.0
svn diff for 2 branches[]
svn diff http://REPOS/trunk http://REPOS/branches/B
svn resolve tree conflict[]
svn resolve --accept working -R <path>
- resolve asks svn to resolve the conflict
- accept working specifies to keep your working files
- -R stands for recursive
resolve local edit, incoming delete upon update[]
$ svn st ! C foo > local delete, incoming delete upon update ! C bar > local delete, incoming delete upon update
$ touch foo bar
$ svn st A + C foo > local edit, incoming delete upon update A + C bar > local edit, incoming delete upon update
$ svn st ? foo ? bar
$ rm foo bar $ svn st
svn empmty checkout[]
- you can limit the amount of files that do get checked out with the --depth
svn co --depth=empty http://myserver/myrepos/mydirectory
svn blame[]
svn blame someurl
svn log -v -r[]
- get revision detail info
svn log -v -r rev. http://repo-url
svn status code[]
svn checkout specify revision file[]
svn checkout <url_of_big_dir>@revision <target> --depth empty cd <target> svn up <file_you_want>