Improve company productivity with a Business Account.Sign Up

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1601
  • Last Modified:

How can I get a Compare operation in TFS to ignore whitespace?

I'd like to set an option in TFS so that when I compare files, differences in whitespace are ignored.
0
jobrems
Asked:
jobrems
  • 5
  • 2
1 Solution
 
AndyAinscowFreelance programmer / ConsultantCommented:
http://msdn.microsoft.com/en-us/library/6fd7dc73%28v=vs.80%29.aspx

Use the /ignorespace option:
/ignorespace     Does not highlight white-space differences between the compared files.
0
 
jobremsAuthor Commented:
where do I use that?
0
 
AndyAinscowFreelance programmer / ConsultantCommented:
Here is how you use it
http://msdn.microsoft.com/en-us/library/6fd7dc73%28v=vs.80%29.aspx

ps.  The link is the same one as my earlier comment.
0
Get expert help—faster!

Need expert help—fast? Use the Help Bell for personalized assistance getting answers to your important questions.

 
jobremsAuthor Commented:
what I am looking for is a way to configure the Compare facility in TFS so that all compares are done ignoreWhitespace. In Visual SourceSafe, if you recall, there was a checkbox that could be selected which configured VSS to compare in this way. Is there no such option in TFS? It is not very convenient to have to run a command line everytime I want to diff files.
0
 
jobremsAuthor Commented:
I resolved my own question: install a file comparison program on your machine (such as Beyond Compare or ExamDiff). Integrate the program into Visual Studio by following these steps:
Tools > Options > Source Control > Visual Studio Team Foundation Server;
press the Configure User Tools... button.
For Extension, enter .*; for Operation, choose Compare;
for Command, enter path of executable (e.g., C:\Program Files\Beyond Compare 3\BComp.exe);
for Arguments, enter %1 %2 /lefttitle=%6 /righttitle=%7  /nobackups.

With these programs, it is easily possible to specify ignore whitespace (and many other options).
0
 
jobremsAuthor Commented:
please close this question and leave info in KnowledgeBase
0
 
jobremsAuthor Commented:
I never got the answer I was looking for. So , I found a way to do it myself.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Upgrade your Question Security!

Your question, your audience. Choose who sees your identity—and your question—with question security.

  • 5
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now