From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: =?UTF-8?Q?Jo=C3=A3o_?= =?UTF-8?Q?T=C3=A1vora?= Newsgroups: gmane.emacs.bugs Subject: bug#38992: 27.0.60; when enabled, fido-mode seems to break vc-git-grep Date: Sun, 19 Jan 2020 13:00:35 +0000 Message-ID: References: <288610218.111246.1578330546916@office.mailbox.org> <7293f6ca-b11d-3d2a-ad71-831135434e75@yandex.ru> <780526337.114357.1578556168662@office.mailbox.org> <944631362.128066.1578605073103@office.mailbox.org> <98df50d8-44fb-448e-e893-f20601f1ca54@yandex.ru> <51d12435-274b-be14-95b8-f790804f1a61@yandex.ru> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="33450"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 38992@debbugs.gnu.org, waah@yellowfrog.io, Stefan Monnier To: Dmitry Gutov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Jan 19 14:02:16 2020 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 1itADY-0008dF-5K for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 19 Jan 2020 14:02:16 +0100 Original-Received: from localhost ([::1]:50112 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1itADX-000633-8S for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 19 Jan 2020 08:02:15 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:59793) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1itADM-00062e-7g for bug-gnu-emacs@gnu.org; Sun, 19 Jan 2020 08:02:05 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1itADK-0006Sk-VZ for bug-gnu-emacs@gnu.org; Sun, 19 Jan 2020 08:02:04 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:36764) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1itADK-0006SR-BA for bug-gnu-emacs@gnu.org; Sun, 19 Jan 2020 08:02:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1itADK-00016K-9L for bug-gnu-emacs@gnu.org; Sun, 19 Jan 2020 08:02:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: =?UTF-8?Q?Jo=C3=A3o_?= =?UTF-8?Q?T=C3=A1vora?= Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 19 Jan 2020 13:02:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 38992 X-GNU-PR-Package: emacs Original-Received: via spool by 38992-submit@debbugs.gnu.org id=B38992.15794388624162 (code B ref 38992); Sun, 19 Jan 2020 13:02:02 +0000 Original-Received: (at 38992) by debbugs.gnu.org; 19 Jan 2020 13:01:02 +0000 Original-Received: from localhost ([127.0.0.1]:42737 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1itACI-00014Z-KS for submit@debbugs.gnu.org; Sun, 19 Jan 2020 08:01:02 -0500 Original-Received: from mail-il1-f193.google.com ([209.85.166.193]:37326) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1itACD-00014J-0e for 38992@debbugs.gnu.org; Sun, 19 Jan 2020 08:00:56 -0500 Original-Received: by mail-il1-f193.google.com with SMTP id t8so25120168iln.4 for <38992@debbugs.gnu.org>; Sun, 19 Jan 2020 05:00:52 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=lSzfdcf5LYceGCOHu5kSZ6iaJObb3QZkznJpBQHR7Es=; b=um2hKUtIjBSEZZcuHH0nTWEVe771ftbzk6fLjnyKoFAHoHqL7XEiRkVMXLNeAB1T0C 2dkk7tL7Hi+ayRzeWWx2+zId06lSgHldnSuurbAsB2lqmbqar2cmxZDdhx1mjkm/B9Sq n2UsakCjxTr3lOKIcCAzH++IamiGcvbRox3syES3iOU8Rnz8lDJd+kkTmpFTNI62wcPS pP77Q0YVBiCq0jhhji8RN+/YkCthU0POpWNqBJR9Mc1XlaG7VpSm8zJu94s3/lU9NiKi /xLybVx3kyLzHk13gDa4cyJkUnFxMSd4CblNDU2iCyhIVul7SrVQviTmdRbGld3xnEM7 Lv8Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=lSzfdcf5LYceGCOHu5kSZ6iaJObb3QZkznJpBQHR7Es=; b=tN/EhdSUqUaG492hI05TC+97fTm+SsYBcxFc9tcLwYPPUZ5QjahUzUD0MwGtg5iCby GZQNtsD4tbB7/C45x893vOKn5TuhS6yerObbHRDXJCyIDg0ihw448WK57KMW5Ehj4HGd XLXp6sh9MAU0shfXny4jsdUwwE9oSWISg6rXwwRQoN1OLRHzBLat7Bha/zX/S2b8QEbR g0bkDcD+2Jq2AmtPAuQL0XL1rOMaeZYzL6Dr0R5KgwBDeOseJmsl8LUf2ZTK3bGlbbJX YXBNYlA6WZiZQC5i1FuuuM2FGyxpRhu0cazJsN/6Vw2Mw8ed39uPaAavRrzVc8vQ+qgB urZA== X-Gm-Message-State: APjAAAXZcXtrWMhntS8F7JqltbCQw6zLL3mzYfGAoOD6YPWicU69X0sm pYRwfGj22ZPBzl4K09tTRmGjCc7LeTu4WCTQbc4= X-Google-Smtp-Source: APXvYqxiKpjSb6afElXX7zEmCgq/BEoOWVzD8dM7gvjy46y58tvwLyoGzh6gry2ff+LRpGuw54dfUNiPUug67W7TP44= X-Received: by 2002:a92:88d0:: with SMTP id m77mr7038387ilh.9.1579438847380; Sun, 19 Jan 2020 05:00:47 -0800 (PST) In-Reply-To: <51d12435-274b-be14-95b8-f790804f1a61@yandex.ru> 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-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:174864 Archived-At: Hi Dmitry, The second option looks pretty good, so you can just push that at will, if no other objections. Incidentally, I would also think it reasonable to provide the same help text if there is a single partial match. The first option I don't understand very well, but that's probably because I haven't looked very closely at it, so if you can post an implementation o= f your idea it would be ideal, because it doesn't sound absurd at all :-) Jo=C3=A3o On Sat, Jan 18, 2020 at 1:38 AM Dmitry Gutov wrote: > > On 11.01.2020 21:59, Jo=C3=A3o T=C3=A1vora wrote: > > rs due to fundamental changes in the problem others due > > to opinion. It "feels" nice for me now, but if you can come up with a = better > > binding for RET, shoot it over, I'll tell you what I think about it. I= think > > you'll find it will have advantages and disadvantages. But who knows:-= ) > > Without going far into changing its behavior, I think we have two > options for this now. Since the only occurrence of "Incomplete" of > minibuffer.el is in minibuffer-force-complete-and-exit, apparently one > issue is that the glob input doesn't succeed the test-completion test in > the read-file-name-internal completion table used by grep-read-files. > > So the options are: > > 1. Make sure that the table says globs are valid input (by adding a > wrapper, probably). This should make RET silently accept the input in > this case. This is a good way to proceed if we're reasonably confident > we can deal with similar issues in the same way, and there won't be too > many of them. > > 2. Make icomplete-force-complete-and-exit show a different message, so > that the user knows what to do. Instead of just "Incomplete", add > something like ", press \\[exit-minibuffer\\] to accept". > > Maybe do both. > > The second option can look like this: > > diff --git a/lisp/icomplete.el b/lisp/icomplete.el > index a1a67e2330..d88ebca15d 100644 > --- a/lisp/icomplete.el > +++ b/lisp/icomplete.el > @@ -185,7 +185,15 @@ icomplete-force-complete-and-exit > ;; calculated, This causes the first cached completion to > ;; be taken (i.e. the one that the user sees highlighted) > completion-all-sorted-completions) > - (minibuffer-force-complete-and-exit) > + (progn > + (unless completion-cycling > + (minibuffer-force-complete nil nil 'dont-cycle)) > + (completion--complete-and-exit > + (minibuffer-prompt-end) (point-max) #'exit-minibuffer > + ;; If the previous completion completed to an element which fai= ls > + ;; test-completion, then we shouldn't exit, but that should be > rare. > + (lambda () (minibuffer-message "Incomplete, press %s to accept" > + (substitute-command-keys > "\\[exit-minibuffer]"))))) > ;; Otherwise take the faster route... > (minibuffer-complete-and-exit))) > > > (Or we can put the message into a global var which > icomplete-force-complete-and-exit would bind to this message string). -- Jo=C3=A3o T=C3=A1vora