开发者

Few questions about SVN

I work on a large scale project, now I did many changes + add new files in various directories, how can I find what I added (I know what I added, but lets assume I forgot...) so I can 'add' to the repository? also, how can I commit all the changes at once开发者_如何学JAVA?

thanks,


if you use the command line version of svn, go to the topmost directory and run svn st. That command will tell you which files have been updated, deleted or are not tracked.

To commit run svn commit -m "commit message" and it will commit all the files.

If you have deleted or created files, but haven't deleted or added them with subversion you will need to run svn rm path/to/file for the files you've removed and svn add path/to/file for the files you've added. svn st lists these files.


To commit all changes at once you have to invoke commit at the level of the the root folder of your project.

All the changes (updated/modified/deleted files) will be listed on the Tortoise's commit window.


I'm assuming that you are using Tortoise, You should be able to go to the root directory and do a checkin. It will pull up all the files that you have either - made changes to or added. Please make sure you go through your list and uncheck any of them you changed but did not mean to change otherwise you will break you


In response to George, I think the original poster is asking about which new files he's created but has not yet performed an svn-add on them. That is to say these would be files that svn does not yet know about. Is that what you're asking?

I don't know of a straightforward way to do this, but you could initiate a commit at a root level and (assuming you're using tortoise) click the "show unversioned files." This would then let you see all files in the directory structure that svn doesn't yet know about. Obviously there are likely to be other unversioned files in this list, so depending on how many there are, this method may or may not be useful for you.


I use TortoiseSVN as the interface to svn. The right click menu gives you an option to check for modifications. This will identify all new files (non-versioned) and all modified files in your working directory.

You can then highlight all the new files and add them, or highlight all the modified files and commit them.

Dave

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜