From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Michael Albinus Newsgroups: gmane.emacs.devel Subject: Re: git-handler.el Date: Sun, 13 Aug 2017 11:26:19 +0200 Message-ID: <87shgvsts4.fsf@detlef> References: <87eftk9uxe.fsf@bernoul.li> <87zic7ze06.fsf_-_@detlef> <87d192aold.fsf@bernoul.li> <87o9rmiems.fsf@detlef> <877ey9cb9l.fsf@bernoul.li> <878tiod0n0.fsf@bernoul.li> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1502616444 28862 195.159.176.226 (13 Aug 2017 09:27:24 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sun, 13 Aug 2017 09:27:24 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.50 (gnu/linux) Cc: John Wiegley , Dmitry Gutov , Emacs developers To: Jonas Bernoulli Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun Aug 13 11:27:19 2017 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dgpAy-000730-3U for ged-emacs-devel@m.gmane.org; Sun, 13 Aug 2017 11:27:16 +0200 Original-Received: from localhost ([::1]:56018 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dgpB4-0002Jy-Go for ged-emacs-devel@m.gmane.org; Sun, 13 Aug 2017 05:27:22 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:34401) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dgpAD-0001nq-0F for emacs-devel@gnu.org; Sun, 13 Aug 2017 05:26:30 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dgpA8-0007ux-1n for emacs-devel@gnu.org; Sun, 13 Aug 2017 05:26:29 -0400 Original-Received: from mout.gmx.net ([212.227.15.19]:51551) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dgpA7-0007qb-Nn for emacs-devel@gnu.org; Sun, 13 Aug 2017 05:26:23 -0400 Original-Received: from detlef.gmx.de ([178.20.95.72]) by mail.gmx.com (mrgmx001 [212.227.17.190]) with ESMTPSA (Nemesis) id 0M936L-1dtE9J27fp-00CQW6; Sun, 13 Aug 2017 11:26:20 +0200 In-Reply-To: <878tiod0n0.fsf@bernoul.li> (Jonas Bernoulli's message of "Sat, 12 Aug 2017 21:52:35 +0200") X-Provags-ID: V03:K0:6WKNfrnzVtc+8a9FiytBmwJCpY/3c8S2MiMrNqHpDBqimh4Qi5H CP+3p75kXxECqFC72I83jEMwAKJ3QJO8c6NH4Uy45dLFYwmSK9sFT1kNSb3s7Wgsg+s0Zue FuZJTbpoovsIYU8AmlgtNtzz4L7r0sq6lCbQFb6Fs+RGw6fel54WXQ8hqaKlTAAoVIh0eOH yTUZ2KCPaBeOLlcqLJIkA== X-UI-Out-Filterresults: notjunk:1;V01:K0:xR3zEYn8J4Q=:frQLSetnhlR3nfhL/nD1zh 14ail9b8n3FDP2JD2CQ2ZTw7sTAXRPvRDHFFCV6uG3jysDgRgzH7kM+SdHJ6BHGEyyKCji6ap 9DQiah72M0R3E9An5v2BioehppLsAYWWhHTeUlo0vQlUKA2iYeEOnc4HxPhg2uIkXyKJ88STW 2fqJ+t6VmLN6d7RwQ+CEWtwML9LfH+ZmY92p91AIRcaRbseXV9pyRZRlyzmCw+IUWXZHiLgmP CjZhEloSuYV+czRNhYP5povPvCBsYrOiJUr80PN1/20FkfvVuayPWL4wSsaxF/3vF+7JkA96n 0o0PV/vdZUdnOfQZnBefOY/WKymoCiRA6i1FI/NmlygMPJvhv2syZG0aAcH8ByawxWsYl5BRE W68p3g2a4FwciH/JJ9kfPCm16FjGUULGt03d7gZFhZJPEFq/QCN0tJrpg9IKgaGR8nzbwqr/G Nb72rZCn3nRs9R9y0Xq8Io+EcJql4ooi7l4FijyIZHMiz+CiJfdV8OcrBr3fCi+EHbk30tKpn pCekfqdW4GfWX91DxKZGuY22IBusfoPgolryZzVPOqt+aVzWvEPO4VCzZ6GJoC1EIfMGhYhfa o2K5DQt7tEKr8fgCgw7LlJT0PPtxkidpGvODuvqUkbPtAFMC+0EduGFC2Q3tVUJSebVON+698 8qHvUq7Fwnh6JHwd2DwiwLAXnnD5p2rYz7Sv3YKSNSNjeKrQKscP2/3dQHTibOrcOj1EYo3YT XBWu5K8dqx8fj2yhZ88YHpTYwnP9MqS2/9jLUEwJS17fojTUTOHI3NG021zs/GKx63m/Xa+l X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 212.227.15.19 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:217505 Archived-At: Jonas Bernoulli writes: Hi Jonas, > So if you are visiting "/path/to/@@file/some-feature", it would be nice > if `find-file' gave you "Find file: /path/to/@@file/" and you could type > "ma TAB RET" to visit "/path/to/@@file/master". But that's only one > variant of "same file, another revision" and probably not even the most > common one. That shall work out-of-the-box, file-name-all-completions knows of branches. > Another variant would be "same file, next/previous revision" where > next/previous could have different meanings. A common one is "the > next/previous revision which touched this line". Currently there's even > exists a package just for that use case: `git-timemachine'. > > (Magit also provides that same feature but the implementations are not > compatible. `git-timemachine' reuses the same buffer to visit different > version of the file (which has the benefit that no buffers have to be > cleaned up later), while Magit uses a new buffer (which allows you to > look at different versions of the same file at once).) That's not possible with magic file name handler operations as they are defined now. They don't give you the ability to say something about the file contents. > Anyway, I don't think it makes sense to teach `find-file' about going to > the next/previous revision. Instead that use-case should be handled by > separate commands, which would likely be bound to " n" and > " p" (that's what `git-timemachine' and Magit currently do). I agree. New commands in dired would serve, indeed. But that would be backend specific. > The point I am trying to make here is that `find-file' cannot possibly > the right command to handle all cases of "same file, another revision" > with ease, while it is completely suitable for "same revision, another > revision", with no extra effort. But only if we go with the REV:PATH > scheme. Isn't my proposal what you have in mind? Both /home/albinus/src/emacs/lisp@@/ef7a18a071/display-line-numbers.el and /home/albinus/src/emacs@@/ef7a18a071/lisp/display-line-numbers.el would point to the same revision ef7a18a071 of lisp/display-line-numbers.el. Best regards, Michael.