From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.devel Subject: Re: [Emacs-diffs] master 55ec674: * lisp/multifile.el: New file, extracted from etags.el Date: Sun, 30 Dec 2018 00:02:17 +0200 Organization: LINKOV.NET Message-ID: <87efa00y92.fsf@mail.linkov.net> References: <20180922154639.23195.66360@vcs0.savannah.gnu.org> <20180922154640.9D58220310@vcs0.savannah.gnu.org> <54108dbc-9d12-06ff-3f1d-151118e9b234@yandex.ru> <87sgyi69iw.fsf@mail.linkov.net> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1546123688 6598 195.159.176.226 (29 Dec 2018 22:48:08 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sat, 29 Dec 2018 22:48:08 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (x86_64-pc-linux-gnu) Cc: emacs-devel@gnu.org To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Dec 29 23:48:04 2018 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 1gdNOi-0001Y5-V1 for ged-emacs-devel@m.gmane.org; Sat, 29 Dec 2018 23:48:01 +0100 Original-Received: from localhost ([127.0.0.1]:41955 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gdNQm-0003ZG-QJ for ged-emacs-devel@m.gmane.org; Sat, 29 Dec 2018 17:50:08 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:60369) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gdNQU-000349-1x for emacs-devel@gnu.org; Sat, 29 Dec 2018 17:49:54 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gdN7k-0001Ae-E2 for emacs-devel@gnu.org; Sat, 29 Dec 2018 17:31:07 -0500 Original-Received: from lavender.maple.relay.mailchannels.net ([23.83.214.99]:8973) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1gdN7i-00011g-EP for emacs-devel@gnu.org; Sat, 29 Dec 2018 17:30:28 -0500 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 504412833FB; Sat, 29 Dec 2018 22:30:21 +0000 (UTC) Original-Received: from pdx1-sub0-mail-a25.g.dreamhost.com (unknown [100.96.26.166]) (Authenticated sender: dreamhost) by relay.mailchannels.net (Postfix) with ESMTPA id 6C172283642; Sat, 29 Dec 2018 22:30:20 +0000 (UTC) X-Sender-Id: dreamhost|x-authsender|jurta@jurta.org Original-Received: from pdx1-sub0-mail-a25.g.dreamhost.com (pop.dreamhost.com [64.90.62.162]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384) by 0.0.0.0:2500 (trex/5.16.2); Sat, 29 Dec 2018 22:30:21 +0000 X-MC-Relay: Neutral X-MailChannels-SenderId: dreamhost|x-authsender|jurta@jurta.org X-MailChannels-Auth-Id: dreamhost X-Glossy-Print: 790036ba13c92493_1546122620591_3335080263 X-MC-Loop-Signature: 1546122620591:2463784232 X-MC-Ingress-Time: 1546122620591 Original-Received: from pdx1-sub0-mail-a25.g.dreamhost.com (localhost [127.0.0.1]) by pdx1-sub0-mail-a25.g.dreamhost.com (Postfix) with ESMTP id B39788060B; Sat, 29 Dec 2018 14:30:18 -0800 (PST) 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=yl3feVqvZCblJsmF3z1Q4gNwBso=; b= AMqHY1BS5qCR5bNM8fT2WhF7vgJ/67oPkgtmLhfC46CL4b9NEYMXER7Xnk73fZIk b0AeJjllMRpweoWJKAUoSDUiPMRs7q5dAvBP/vc7xaEij0FRJ0HeqYQIknBjawoj MLhXRG+A5O7sPZDj9bZmmKCEiVFD5BKs1Fe90U0Tz58= Original-Received: from mail.jurta.org (m91-129-108-193.cust.tele2.ee [91.129.108.193]) (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-a25.g.dreamhost.com (Postfix) with ESMTPSA id 239C6819BD; Sat, 29 Dec 2018 14:30:16 -0800 (PST) X-DH-BACKEND: pdx1-sub0-mail-a25 In-Reply-To: (Stefan Monnier's message of "Fri, 28 Dec 2018 13:07:06 -0500") X-VR-OUT-STATUS: OK X-VR-OUT-SCORE: -100 X-VR-OUT-SPAMCAUSE: gggruggvucftvghtrhhoucdtuddrgedtledrtdekgdduieefucetufdoteggodetrfdotffvucfrrhhofhhilhgvmecuggftfghnshhusghstghrihgsvgdpffftgfetoffjqffuvfenuceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmnecujfgurhephffvufhofhffjgfkfgggtgesthdtredttdertdenucfhrhhomheplfhurhhiucfnihhnkhhovhcuoehjuhhriheslhhinhhkohhvrdhnvghtqeenucfkphepledurdduvdelrddutdekrdduleefnecurfgrrhgrmhepmhhouggvpehsmhhtphdphhgvlhhopehmrghilhdrjhhurhhtrgdrohhrghdpihhnvghtpeeluddruddvledruddtkedrudelfedprhgvthhurhhnqdhprghthheplfhurhhiucfnihhnkhhovhcuoehjuhhriheslhhinhhkohhvrdhnvghtqedpmhgrihhlfhhrohhmpehjuhhriheslhhinhhkohhvrdhnvghtpdhnrhgtphhtthhopehmohhnnhhivghrsehirhhordhumhhonhhtrhgvrghlrdgtrgenucevlhhushhtvghrufhiiigvpedt X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 23.83.214.99 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:232039 Archived-At: >> 'git ls-files' seems very fast, and moreover it outputs only relative >> paths, not absolute. > > [ Nitpick: the GNU convention says these are "file names" rather than > "paths". ] Sorry, I remembered the convention regarding file names and paths, but I forgot how to name the base file name part as opposed to its directory part. Now I consulted in the Glossary it's called File-Name Component. >> On TAB completion with too long absolute paths >> the list of completions is quite unreadable. > > That's why I was suggesting to start by stripping the common prefix. > >> Also is it possible to complete only on file names, not paths? > > With the `substring` completion style, yes. I meant something more like switch-to-buffer, but that completes on project file names (project-switch-to-buffer makes sense as well to complete on already visited project buffers). So a new command project-switch-to-file could complete on non-directory file name components from the project. And on duplicate file names it could add a unique suffix '' like is used to make buffer names unique. Then completions will show project file names in alphabetical order. >> I think they should mirror everything that makes sense to use in the >> multifile project: project-occur, project-grep, ... > > occur operates on buffers, not files, so I don't think mirroring it into > multifile- or project- makes much sense. The corresponding command for > files is `grep`, so `project-grep` might make sense. project-occur could operate only on visited project files (but I doubt if this is useful). project-rgrep is much more needed to operate like rgrep, but without asking for file names and root directory. >> Either prefix multifile- or project- is fine, but not both at the same time. >> Or better just shorten to multi-. We already have multi-isearch (not >> supporting project yet). > > I chose "project-" so it actually says to which files it is supposed to > apply, compared to "multi-" or "multifile-" which just says that it > applies to several files but without clarifying which are those. > > Dmitry wrote: >> OK, let me put it another way: "multifile" is just a package that implements >> a particular UI. It is in no way synonymous with "project". Maybe a better >> name for it would be something like bufferloop (suggestions welcome). > > multifile loops over several *files* rather than buffers, so I'm fine with > "fileloop" or "iteratefiles", but "bufferloop" doesn't seem right. "hulahoop" :) Actually I think the existing names are already good enough: "multifile" for the package that supports multifile operations, and "project" for UI that operates on project files.