From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Yuri Khan Newsgroups: gmane.emacs.help Subject: Re: Tweaking magit/diff mode to be more helpful in text editing Date: Tue, 31 May 2016 13:48:11 +0600 Message-ID: References: <87shwyvi0w.fsf@ericabrahamsen.net> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1464680959 1182 80.91.229.3 (31 May 2016 07:49:19 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 31 May 2016 07:49:19 +0000 (UTC) Cc: "help-gnu-emacs@gnu.org" To: Eric Abrahamsen Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue May 31 09:49:19 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 1b7eQQ-0006zw-Is for geh-help-gnu-emacs@m.gmane.org; Tue, 31 May 2016 09:49:18 +0200 Original-Received: from localhost ([::1]:34936 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b7eQP-0007yl-RI for geh-help-gnu-emacs@m.gmane.org; Tue, 31 May 2016 03:49:17 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:46701) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b7ePi-0007x6-Fo for help-gnu-emacs@gnu.org; Tue, 31 May 2016 03:48:35 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1b7ePg-00052W-I4 for help-gnu-emacs@gnu.org; Tue, 31 May 2016 03:48:33 -0400 Original-Received: from mail-lf0-x22a.google.com ([2a00:1450:4010:c07::22a]:32771) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b7ePg-00052S-9G for help-gnu-emacs@gnu.org; Tue, 31 May 2016 03:48:32 -0400 Original-Received: by mail-lf0-x22a.google.com with SMTP id s64so60550568lfe.0 for ; Tue, 31 May 2016 00:48:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc:content-transfer-encoding; bh=EIV18waTqCexwozR8sSTKR3405laz2J72ZhmrXILrJY=; b=j2/B53BdJGgOzZM/Q52ScW3/KQytgUeybcZPsqz4afgQTgVFQWfXXOVVa4OAvlBgoV ugWW6glNIWolbEE3kcjDxat8LV50tsJdDWa9YNMFYO2xNC8zrVbRAxQKvVY9Tr/hdXor Us9+67uaRqw7vBlZnPVOyiSpPAwK1hZfsf7ksvWVj41cuCe1LWz+4A/bX99QmP3UyTzN rZWsw1uqHgnbaMNhTaz7jiwoNxqC6G8mInYVxNdFRHCDcyC9Sa0Xl66OmlP+TxMpUcoK dTGR8PplHxROOxR4hLBm0itNoTXScDvmVyg0EOXrPiT/IwdYfSaWHrI10G/ezXF3uLZX e9OA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to:cc:content-transfer-encoding; bh=EIV18waTqCexwozR8sSTKR3405laz2J72ZhmrXILrJY=; b=Pw+AOxBTSIxEXvL/QddqGufdnJU+gqVFX9K0cJHhFgmP2meY7kMS23z0+fT2YV2k8A 5frlJsihe9WmH1UgY7BU60xn6+f6LYhmIBp6YnO3YSg6nqTCDpB/6TS8RaZwDqNo/vZb S5WiKtAnMZqTcXHEvUnvefTTRWwN7/rDFbk4I/MTGABJ0oeLG2VCyRhCJ3NgsS6xMRfy DzI+3OFhoUH10cF/P1QzdLSXyAuvhnTdjyr3MpTctGv1PdcAtHA0T7SsCTnxqjRZ1aZM JWxYEg8zfxfokej7MMKG8O+eqYyLNth8U7Hy1AU3ieEyEDAUBgtukVYh5KwTU/vB1roo Fifg== X-Gm-Message-State: ALyK8tI/66+TsBSKKL3SHp2ezSlKKqOrHbMcUnohhCGe6rjmDtzL/LONml0TA0nNBAcoc7gbdvx7kWi8c1AbWQ== X-Received: by 10.25.150.129 with SMTP id y123mr10514976lfd.168.1464680910822; Tue, 31 May 2016 00:48:30 -0700 (PDT) Original-Received: by 10.114.182.167 with HTTP; Tue, 31 May 2016 00:48:11 -0700 (PDT) In-Reply-To: <87shwyvi0w.fsf@ericabrahamsen.net> X-Google-Sender-Auth: TCtZBUwQciaHqamgkrc_Rc-O04I X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2a00:1450:4010:c07::22a X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.21 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" Xref: news.gmane.org gmane.emacs.help:110143 Archived-At: On Tue, May 31, 2016 at 12:49 PM, Eric Abrahamsen wrote: > What I'd really like is to find a way (either a diff algorithm or a > Magit tweak) of only showing the actual edits, not the filling. And then > to still be able to export that in a way that will allow me to give the > author a file only showing those edits. > > Does anyone have any clever ideas in that direction? I have an idea. Whether it=E2=80=99s clever or stupid, is up to you. Do not fill paragraphs based on line width. Wrap lines at stable positions based on sentence structure such as sentence and clause boundaries like I=E2=80=99m doing here. This way, diffs will be compact (the worst case is when a single line grows too long and you split it at a logical point near the middle) and line breaks will be eliminated anyway when the document is rendered to HTML or whatever other form. (One disadvantage is that it looks like a poem.)