WFC Technical Note 4 - Integrating SourceSafe with Visual C++ 5.0
$Revision: 2 $ Last Modified $Date: 3/26/00 11:01a $
Introduction
Microsoft is always trying to integrate things together.
To that end, the integrated SourceSafe into Developer's
Studio. Like most things Microsoft, it is a wonderful
idea but a sucky implementation. This tech note discusses
the experience I had debugging Visual C++ 5.0's integration
issues with SourceSafe on a team project.
Children At Work
When Microsoft integrated SourceSafe into Developer's Studio,
they put too much intimate information into your workspaces
(.DSW files). The child that did the integration work put
the SourceSafe project name, data directory and local working
folder names into the Visual C++ project workspace. This was
very stupid. Well, it could have been simple ignorance but since
it made it all the way through Microsoft's QA, it is probably
stupidity.
Why is putting all of this information into the
workspace bad? The problem is when you use SourceSafe to modify
project settings. For example, you create a project in Visual C++
and check it into SourceSafe. Another developer on another machine
(OK, this is an advanced concept in programming, multiple programmers
on one project!!!!) sets his SourceSafe working folder. The two (or more)
developers have different local directory names. For example, one
developer is building WFC in his C:\WFC directory.
The other developer is building WFC in D:\Projects\Public\WFC
directory. As you can see, these are different.
Even though each developer's SourceSafe settings (srcsafe.ini) have
their project's pointing to different local working folders, the
setting in Developer Studio's DSW (or OPT) file will
override them. This is the heart of the problem. Microsoft should
have let SourceSafe put the files in the local directory associated
with the SourceSafe project (i.e. let SourceSafe do its job).
Magical Reappearing Settings
OPT file. This little gem is an OLE compound document.
It contains more settings but in a non-human viewable format.
DELETE THIS FILE! If you don't, it will overwrite
your SourceSafe settings in the DSW file. No, the GUI will
not warn you.
Conclusion
Don't integrate SourceSafe into Developer's Studio unless you
can dictate exactly where every developer will put every file
in your project.
Samuel R. Blackburn