From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#60338: [PATCH] Add option to present server changes as diffs Date: Mon, 12 Jun 2023 15:52:03 +0300 Message-ID: <83fs6wyhak.fsf@gnu.org> References: <87ilhy1dub.fsf@posteo.net> <877cs97kgb.fsf@posteo.net> <83jzw8yjv5.fsf@gnu.org> <877cs8g8oy.fsf@posteo.net> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="40869"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 60338@debbugs.gnu.org, joaotavora@gmail.com To: Philip Kaludercic Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Mon Jun 12 14:52:34 2023 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1q8h2A-000AQV-7t for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 12 Jun 2023 14:52:34 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1q8h1h-0008Ud-Un; Mon, 12 Jun 2023 08:52:06 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q8h1f-0008UR-Jm for bug-gnu-emacs@gnu.org; Mon, 12 Jun 2023 08:52:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1q8h1f-0005E7-Ac for bug-gnu-emacs@gnu.org; Mon, 12 Jun 2023 08:52:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1q8h1e-0002Af-DG for bug-gnu-emacs@gnu.org; Mon, 12 Jun 2023 08:52:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 12 Jun 2023 12:52:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 60338 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 60338-submit@debbugs.gnu.org id=B60338.16865743208336 (code B ref 60338); Mon, 12 Jun 2023 12:52:02 +0000 Original-Received: (at 60338) by debbugs.gnu.org; 12 Jun 2023 12:52:00 +0000 Original-Received: from localhost ([127.0.0.1]:39162 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q8h1c-0002AM-DD for submit@debbugs.gnu.org; Mon, 12 Jun 2023 08:52:00 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:59544) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q8h1X-0002A2-ID for 60338@debbugs.gnu.org; Mon, 12 Jun 2023 08:51:59 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q8h1Q-0005DR-W5; Mon, 12 Jun 2023 08:51:49 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=gXI0G4kXCBE5eZwzdEUbWzvYmRcWmISCDFaEX+NkvWc=; b=RNeZF+vnp+Tk sONAu648UtsPRM7Os3XPEvoFHkNGTYLz4C0lIzyx1bzCjbUIaF6sU0JOX1DeBrKjHEiwmdvnG7yN/ gFpAcNKJJjlBafWPVa6fen5LMwO6C4DEpUs74GZLjR/dimWu2iqWkT/Iy28czmv/gEWSCJ6DVLT+q rsInaSG5SXWaicd1QlUbGmrTubJY0htYFK9TMrcO39mEc1WD2xFuw8ev0V1DCts56xHgF8UThLsLn YUS644WPwS33d0jaTneT/Ub4vGRiS9nzUrKebP2V0e0WxtuZP4mVgvdFsLjvXGgcbuUXu371XHma4 MKIa5p7EOLgn/zlrNYhqsg==; Original-Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q8h1Q-0004QK-G0; Mon, 12 Jun 2023 08:51:48 -0400 In-Reply-To: <877cs8g8oy.fsf@posteo.net> (message from Philip Kaludercic on Mon, 12 Jun 2023 12:35:09 +0000) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:263269 Archived-At: > From: Philip Kaludercic > Cc: 60338@debbugs.gnu.org, joaotavora@gmail.com > Date: Mon, 12 Jun 2023 12:35:09 +0000 > > Eli Zaretskii writes: > > > Isn't there a better way of presenting the edits in human-readable > > form than apply them and then run Diff? What format is used by the > > server itself to send the edits? > > The server sends a JSON message. Here is an example from a little toy > project of mine in C, where I intentionally uncommented a #include > directive: And we cannot generate the Diff format from this? > > Besides, this assumes the 'diff' command is available, which is not > > portable -- one more reason not to go that way, or at leas provide an > > alternative. > > I am personally fond of this approach, because I get a regular text > buffer that I can store or send someone. The fact that diff is not > available everywhere (even though I would guess any system with a > language server /should/ have diff installed), is an argument against > enabling this behaviour by default, not against providing this interface. What do we suggest to people who don't have Diff, though? Nothing?