I've been looking at the ScmWagon source, and think it does a really good job of illustrating where the SCM API can be improved.
First, in lines 154-173, you're basically attempting to "import" a project or create a "sandbox", or if it already exists to "update" or "resync". There's a special check for .svn and CVS folders. The following block (lines 176-190) show the complexity of adding a file. In this case, you need to call both "add" and "checkin". For many version control systems, "add" would be sufficient. What do you think about refactoring around use-cases, instead of commands? - Import Project - Drop Project - Resync Project - Add FileSet - Drop FileSeet - Update FileSet - Get FileSet Status - Get FileSet Changelog These would be the new ScmManager methods. We would eliminate the DefaultScmManager, and then require every provider to implement an ScmManager. This seems like a relatively low impact refactor since the provider implementations of the commands remain unchanged. Cheers, Mike Esler