From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Robert Thorpe Newsgroups: gmane.emacs.help Subject: Re: removing white space highlight Date: Sat, 27 Feb 2016 20:54:10 +0000 Message-ID: <87ziul98nh.fsf@robertthorpeconsulting.com> References: <87ziuokv2g.fsf@debian.uxu> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1456606481 1851 80.91.229.3 (27 Feb 2016 20:54:41 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 27 Feb 2016 20:54:41 +0000 (UTC) Cc: help-gnu-emacs@gnu.org To: Emanuel Berg Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sat Feb 27 21:54:30 2016 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1aZlsj-00031y-Jb for geh-help-gnu-emacs@m.gmane.org; Sat, 27 Feb 2016 21:54:29 +0100 Original-Received: from localhost ([::1]:56290 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aZlsi-0001ki-TW for geh-help-gnu-emacs@m.gmane.org; Sat, 27 Feb 2016 15:54:28 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:56160) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aZlsY-0001kO-TQ for help-gnu-emacs@gnu.org; Sat, 27 Feb 2016 15:54:19 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aZlsV-0004hl-Mi for help-gnu-emacs@gnu.org; Sat, 27 Feb 2016 15:54:18 -0500 Original-Received: from outbound-smtp10.blacknight.com ([46.22.139.15]:36190) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aZlsV-0004hW-GN for help-gnu-emacs@gnu.org; Sat, 27 Feb 2016 15:54:15 -0500 Original-Received: from mail.blacknight.com (pemlinmail05.blacknight.ie [81.17.254.26]) by outbound-smtp10.blacknight.com (Postfix) with ESMTPS id 5B3291C13B5 for ; Sat, 27 Feb 2016 20:54:12 +0000 (GMT) Original-Received: (qmail 13479 invoked from network); 27 Feb 2016 20:54:12 -0000 Original-Received: from unknown (HELO RTLaptop) (rt@robertthorpeconsulting.com@[109.76.127.107]) by 81.17.254.9 with ESMTPSA (DHE-RSA-AES128-SHA encrypted, authenticated); 27 Feb 2016 20:54:12 -0000 In-Reply-To: <87ziuokv2g.fsf@debian.uxu> (message from Emanuel Berg on Fri, 26 Feb 2016 04:29:59 +0100) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 46.22.139.15 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:109343 Archived-At: Emanuel Berg writes: > This discussion for example is perhaps closing in on > that :) Yes. I'll have one last go at it though. > Robert Thorpe writes: > >>> I'll be like that once for every file. >> >> Yes, for decades. > > Are there so really so many files that are left > untouched for so long? Not files, no, I'm talking about *lines*. Perhaps an example will clarify things.... Here is the (fictional) output of "svn annotate" on a fictional file: $ svn blame nasty.c 103 sally /* important_parameter should be */ 103 sally /* set for modern memory sizes. */ 115 harry int important_parameter = 42; 103 sally For each line the revision is given when the file was changed, and the person who changed it. You can get this with C-x v g from Emacs. Let's say that version 115 was a reasonably recent. In that case it's likely that Harry set tuned important_parameter for current memory sizes at that time. But, what if Harry just deleted some extraneous whitespace from the end of the line? In that case we can't be sure when important_parameter was last set. It may be very old. Removing the whitespace change we may have the situation: $ svn blame -x -b nasty.c 103 sally /* important_parameter should be */ 103 sally /* set for modern memory sizes. */ 24 terry int important_parameter = 42; 103 sally This shows that the last actual change was in revision 24, which was years ago. In the Subversion manual it explicitly mentions this situation. Subversion has a command to deal with it, "-x -b", which ignores whitespace changes. Not all version controls systems have that. It's also not very well known and tools that use the VC system (GUIs and Editors) may not use it. Stefan mentions that Git has a way of doing this too. When all the tools deal with this situation well then I'll be happy with indiscriminate whitespace changes, but we're not at that point yet. BR, Robert Thorpe