From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Andrii Kolomoiets Newsgroups: gmane.emacs.bugs Subject: bug#19031: 24.4; find-file in icomplete-mode shows completions with no input Date: Tue, 08 Dec 2020 23:33:45 +0200 Message-ID: References: <864mu464pa.fsf@beta.iola.dk> <87r1o5luz9.fsf@gnus.org> <878sabf6fu.fsf@gnus.org> <87zh2o7krj.fsf@mail.linkov.net> <83o8j471m9.fsf@gnu.org> <87v9dc6sia.fsf@mail.linkov.net> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="30612"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (darwin) Cc: olau@iola.dk, larsi@gnus.org, 19031@debbugs.gnu.org To: Juri Linkov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Dec 08 23:02:04 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 1kml3c-0007r7-Mz for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 08 Dec 2020 23:02:04 +0100 Original-Received: from localhost ([::1]:44874 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kml3b-00055c-P7 for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 08 Dec 2020 17:02:03 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:47306) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kmkcU-0001Kc-8A for bug-gnu-emacs@gnu.org; Tue, 08 Dec 2020 16:34:02 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:48450) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kmkcT-0001I2-Vs for bug-gnu-emacs@gnu.org; Tue, 08 Dec 2020 16:34:01 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kmkcT-0001qC-PF for bug-gnu-emacs@gnu.org; Tue, 08 Dec 2020 16:34:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Andrii Kolomoiets Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 08 Dec 2020 21:34:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 19031 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: fixed Original-Received: via spool by 19031-submit@debbugs.gnu.org id=B19031.16074632377063 (code B ref 19031); Tue, 08 Dec 2020 21:34:01 +0000 Original-Received: (at 19031) by debbugs.gnu.org; 8 Dec 2020 21:33:57 +0000 Original-Received: from localhost ([127.0.0.1]:59996 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kmkcP-0001pr-2C for submit@debbugs.gnu.org; Tue, 08 Dec 2020 16:33:57 -0500 Original-Received: from mail-lf1-f52.google.com ([209.85.167.52]:44053) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kmkcM-0001pZ-Hb for 19031@debbugs.gnu.org; Tue, 08 Dec 2020 16:33:55 -0500 Original-Received: by mail-lf1-f52.google.com with SMTP id d20so272110lfe.11 for <19031@debbugs.gnu.org>; Tue, 08 Dec 2020 13:33:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=R/DM/ylt3ia85vyjzqWDVyFMUUOGYncrqxqptM3UjiY=; b=c6owUXU0fPWKSotQ0CIYjfCxMuZSrpnMIUhyEwlpScAPEJaKvtOur0EA4U4qpb5AxE KQkwkrKn4ojzCLxWWFKX6Yfc8ghPKoAO1EhbOiSYQSUGz90hnFqnv3tMjEYBQbmTh/8Q IF7uERmEK5V7p3y4TM6GdSO7X8V/z4HW+L97oI/kKKcBWAUHAyyp/CiOsnoiXbOBFTJq 3DTQaBFBFQXTunHwCE/JI1GRLjjBXzPkSEuqPU+Er+QwIaPBWoa/fG7OzOJ39nx1NnMI cbtcPL8ZB8ySUA3cPGFoVXv/xRtx6XI7263gyVP8dlbYLVvdvdpp5Nb0sgWYGZ4HO5I4 DmUw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=R/DM/ylt3ia85vyjzqWDVyFMUUOGYncrqxqptM3UjiY=; b=o7TPzGThIqKE349JFQWnHBUqE0d66ql2+nOzSsd3+17+BJJMqLrPnawcGlWXQLIw9D ZPvtVpBl8JeTVCl7tLzlM4VOldwW+e07Qz1SlqGIsmKpnsfmNIEqBABfZYItYkJUMC9B WRJBfIvdRMWJ9IbTDuB8L2YFjYc7s6eZ9I7jFdlfNFErdFKCzBS37vi1gbhQwi7iOLoT yIABVqt5YWAWd3dqpF90+k48mDyg1DHdEomfR46aHrjIg+tZCgho5EbLiSUX5EO0lNRw 0S4JFS9k35TD0bB+nPpzdE2zKBR29Cq8RKNziItBR5Ih2r59DclwGtsvoDA+nAOuEQf0 i4dw== X-Gm-Message-State: AOAM533nBJtpZJPzw0uZOr1LLSSMaFXzeUbg0L6SfJdK+5Mv7RLec5L+ RZbh5E9B9ayx/mZrvl3RzfpnX/ZMPISARQ== X-Google-Smtp-Source: ABdhPJysiuRYPmITcI87/khEK3q9yFjSNuB6A56qky18w07Pht8plLYPgXqFo0Fu3wqo+dtjzAtXxg== X-Received: by 2002:a19:801:: with SMTP id 1mr3551094lfi.113.1607463228101; Tue, 08 Dec 2020 13:33:48 -0800 (PST) Original-Received: from muffinmac ([91.206.110.206]) by smtp.gmail.com with ESMTPSA id j3sm5803lfb.29.2020.12.08.13.33.46 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Dec 2020 13:33:47 -0800 (PST) In-Reply-To: <87v9dc6sia.fsf@mail.linkov.net> (Juri Linkov's message of "Tue, 08 Dec 2020 21:11:25 +0200") 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" Xref: news.gmane.io gmane.emacs.bugs:195442 Archived-At: Juri Linkov writes: >> Yes. It's not about filtering out dotfiles but about to make icomplete >> to not show completions until user starts typing filename. > > To make icomplete to not show completions until user starts typing filename, > icomplete could remember the initial minibuffer content immediately after its > activation, then after the user edits the minibuffer, compare the new content > with the stored initial one. So this doesn't require any changes > outside of icomplete. This may lead to unexpected behavior: (read-file-name "? " "~/" nil nil ".em") Completions will be shown for minibuffer content like "~/.e" and "~/.ema" but not for "~/.em". Please read "until user starts typing filename" in my previous message as "until input doesn't contains part of filename" ;) > I'm not sure if such special casing for directory separators is needed. > The option icomplete-show-matches-on-no-input is quite simple and it > should check if the user changed the initial content. Anyway the 'minibuffer-default' variable is not the right place to do such thing. It is used to provide default values which can be inserted into the minibuffer with 'M-n': 1. emacs -Q 2. M-: (setq enable-recursive-minibuffers t) 3. C-x C-f 4. M-: (setq minibuffer-default "foo") 5. M-n