开发者

Whitespace in version control (darcs)

开发者 https://www.devze.com 2023-01-05 17:38 出处:网络
A junior programmer in our office has an unfortunate (but understandable) habit of using Eclipse\'s \"Correct all the indentation in this file\" feature. As a result, his checked out copy includes tho

A junior programmer in our office has an unfortunate (but understandable) habit of using Eclipse's "Correct all the indentation in this file" feature. As a result, his checked out copy includes thousands of lines that register as changes, simply because the whitespace is different. Accepting all these changes - while other people are also working on the same code, some of them in different offices - will lead to conflicts. At the same time we don't want to throw away all t开发者_如何学Che work he's done.

Are there any options for Darcs to ignore or normalise whitespace changes; or tools that can revert the differences?


i have never used darcs, but this is how i'd deal with it:

(cd newbies-copy && darcs diff --diff-opts -w) | (cd fresh-copy && darcs apply)

hopefully i got the darcs commands right, just skimmed the manual.

0

精彩评论

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