From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.bugs Subject: bug#35737: xref--original-command Date: Mon, 27 May 2019 22:59:37 +0300 Organization: LINKOV.NET Message-ID: <8736kzekie.fsf@mail.linkov.net> References: <87ftpgu59l.fsf@mail.linkov.net> <56943df5-f366-a8af-cb95-a40c244da837@yandex.ru> <87tvdvpgzj.fsf@mail.linkov.net> <87woiqkwok.fsf@mail.linkov.net> <87r28nenzk.fsf@mail.linkov.net> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="20099"; mail-complaints-to="usenet@blaine.gmane.org" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (x86_64-pc-linux-gnu) Cc: 35737@debbugs.gnu.org To: Dmitry Gutov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon May 27 22:10:15 2019 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hVLwj-00057Q-Rn for geb-bug-gnu-emacs@m.gmane.org; Mon, 27 May 2019 22:10:14 +0200 Original-Received: from localhost ([127.0.0.1]:50179 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hVLwi-0004cQ-Qs for geb-bug-gnu-emacs@m.gmane.org; Mon, 27 May 2019 16:10:12 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:51730) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hVLwZ-0004bX-QS for bug-gnu-emacs@gnu.org; Mon, 27 May 2019 16:10:04 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hVLwY-0000Qf-TR for bug-gnu-emacs@gnu.org; Mon, 27 May 2019 16:10:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:40687) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hVLwY-0000QX-RN for bug-gnu-emacs@gnu.org; Mon, 27 May 2019 16:10:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1hVLwY-00009R-Lc for bug-gnu-emacs@gnu.org; Mon, 27 May 2019 16:10:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Juri Linkov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 27 May 2019 20:10:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 35737 X-GNU-PR-Package: emacs Original-Received: via spool by 35737-submit@debbugs.gnu.org id=B35737.1558987798560 (code B ref 35737); Mon, 27 May 2019 20:10:02 +0000 Original-Received: (at 35737) by debbugs.gnu.org; 27 May 2019 20:09:58 +0000 Original-Received: from localhost ([127.0.0.1]:54230 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hVLwT-00008x-W1 for submit@debbugs.gnu.org; Mon, 27 May 2019 16:09:58 -0400 Original-Received: from ostrich.birch.relay.mailchannels.net ([23.83.209.138]:42480) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hVLwQ-00008k-NX for 35737@debbugs.gnu.org; Mon, 27 May 2019 16:09:56 -0400 X-Sender-Id: dreamhost|x-authsender|jurta@jurta.org Original-Received: from relay.mailchannels.net (localhost [127.0.0.1]) by relay.mailchannels.net (Postfix) with ESMTP id C0D231423BE; Mon, 27 May 2019 20:09:53 +0000 (UTC) Original-Received: from pdx1-sub0-mail-a50.g.dreamhost.com (100-96-87-96.trex.outbound.svc.cluster.local [100.96.87.96]) (Authenticated sender: dreamhost) by relay.mailchannels.net (Postfix) with ESMTPA id 421271422C4; Mon, 27 May 2019 20:09:53 +0000 (UTC) X-Sender-Id: dreamhost|x-authsender|jurta@jurta.org Original-Received: from pdx1-sub0-mail-a50.g.dreamhost.com ([TEMPUNAVAIL]. [64.90.62.162]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384) by 0.0.0.0:2500 (trex/5.17.2); Mon, 27 May 2019 20:09:53 +0000 X-MC-Relay: Neutral X-MailChannels-SenderId: dreamhost|x-authsender|jurta@jurta.org X-MailChannels-Auth-Id: dreamhost X-Supply-Inform: 3a67042144e6c70d_1558987793633_898812891 X-MC-Loop-Signature: 1558987793633:1958551154 X-MC-Ingress-Time: 1558987793633 Original-Received: from pdx1-sub0-mail-a50.g.dreamhost.com (localhost [127.0.0.1]) by pdx1-sub0-mail-a50.g.dreamhost.com (Postfix) with ESMTP id 7303E832A5; Mon, 27 May 2019 13:09:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=linkov.net; h=from:to:cc :subject:references:date:in-reply-to:message-id:mime-version :content-type; s=linkov.net; bh=lqF/eSlKNea9E+Zd46vxfmIf2tA=; b= YkLLVdkTZgdPOmZ954lO/tnTKP2VnoORQknBk4Exm88ECmVY+dktSRPopFPF65pi SKEoZ+cPNLvBJExfJ3o6vxhrnCbr0YX4Q81XrycvCJUUivmBuueCtnSD8jh7eIr3 Hdgblv14valOinXS76xqgM2DTua5ROS/GbywmzIxKgA= Original-Received: from mail.jurta.org (m91-129-96-73.cust.tele2.ee [91.129.96.73]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: jurta@jurta.org) by pdx1-sub0-mail-a50.g.dreamhost.com (Postfix) with ESMTPSA id 504EC832A3; Mon, 27 May 2019 13:09:48 -0700 (PDT) X-DH-BACKEND: pdx1-sub0-mail-a50 In-Reply-To: (Dmitry Gutov's message of "Sat, 25 May 2019 01:48:28 +0300") X-VR-OUT-STATUS: OK X-VR-OUT-SCORE: -100 X-VR-OUT-SPAMCAUSE: gggruggvucftvghtrhhoucdtuddrgeduuddruddvfedguddvucetufdoteggodetrfdotffvucfrrhhofhhilhgvmecuggftfghnshhusghstghrihgsvgdpffftgfetoffjqffuvfenuceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmnecujfgurhephffvufhofhffjgfkfgggtgesthdtredttdertdenucfhrhhomheplfhurhhiucfnihhnkhhovhcuoehjuhhriheslhhinhhkohhvrdhnvghtqeenucfkphepledurdduvdelrdeliedrjeefnecurfgrrhgrmhepmhhouggvpehsmhhtphdphhgvlhhopehmrghilhdrjhhurhhtrgdrohhrghdpihhnvghtpeeluddruddvledrleeirdejfedprhgvthhurhhnqdhprghthheplfhurhhiucfnihhnkhhovhcuoehjuhhriheslhhinhhkohhvrdhnvghtqedpmhgrihhlfhhrohhmpehjuhhriheslhhinhhkohhvrdhnvghtpdhnrhgtphhtthhopegughhuthhovheshigrnhguvgigrdhruhenucevlhhushhtvghrufhiiigvpedv X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 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.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:159824 Archived-At: >> Thanks, I tried xref revert and it works fine. >> Also I agree with Eli regarding the command name, >> documentation and NEWS. > > Should be good now. Thanks. I wonder why you renamed xref--revert-xref-buffer to a such strange name xref-refresh-results? Why not simply xref-revert-buffer? >> But I don't want to write a new function. I just need to check >> if the xref buffer was created by a particular command. > > I think you need to make a choice here. > > Do you want to customize your personal Emacs, or do you want to improve the > default behavior? > > If it's the former, I think the advice you posted will work as well as any > other solution. > > I was kind of expecting the latter. The goal was to improve the default behavior to make customization easier. >> If despite a chain of indirections, xref still can't distinguish >> different commands that created the xref buffer, I'd rather close >> this feature request and use 'advice-add' in customization. > > Do we really need to be able to distinguish between xref-find-references > and project-find-regexp as well? > > TBH, xref--original-command is easy to add, but then we'll have an internal > variable that isn't used anywhere. Somebody will just delete it someday. The idea was to make xref more customizable differently for different commands: xref-find-definitions, xref-find-references, project-find-regexp.