From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.bugs Subject: bug#12490: 24.2; Search inside Minibuffer don't work with M-x (M-x C-s) Date: Sun, 23 Sep 2012 02:21:39 +0300 Organization: JURTA Message-ID: <87obkxod8c.fsf@mail.jurta.org> References: <20120922224229.7baf7964@jcubic> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1348356262 25167 80.91.229.3 (22 Sep 2012 23:24:22 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 22 Sep 2012 23:24:22 +0000 (UTC) Cc: 12490@debbugs.gnu.org To: Jakub Jankiewicz Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Sep 23 01:24:27 2012 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1TFZ3i-0003dj-QC for geb-bug-gnu-emacs@m.gmane.org; Sun, 23 Sep 2012 01:24:26 +0200 Original-Received: from localhost ([::1]:46816 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TFZ3e-00023S-3V for geb-bug-gnu-emacs@m.gmane.org; Sat, 22 Sep 2012 19:24:22 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:53343) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TFZ3b-00023N-2Y for bug-gnu-emacs@gnu.org; Sat, 22 Sep 2012 19:24:20 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TFZ3Z-0004kK-Se for bug-gnu-emacs@gnu.org; Sat, 22 Sep 2012 19:24:19 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:40270) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TFZ3Z-0004kE-P5 for bug-gnu-emacs@gnu.org; Sat, 22 Sep 2012 19:24:17 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.72) (envelope-from ) id 1TFZ5G-0002SE-4W for bug-gnu-emacs@gnu.org; Sat, 22 Sep 2012 19:26:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Juri Linkov Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 22 Sep 2012 23:26:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 12490 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 12490-submit@debbugs.gnu.org id=B12490.13483563109378 (code B ref 12490); Sat, 22 Sep 2012 23:26:02 +0000 Original-Received: (at 12490) by debbugs.gnu.org; 22 Sep 2012 23:25:10 +0000 Original-Received: from localhost ([127.0.0.1]:49816 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TFZ4P-0002RC-Ve for submit@debbugs.gnu.org; Sat, 22 Sep 2012 19:25:10 -0400 Original-Received: from ps18281.dreamhost.com ([69.163.218.105]:51908 helo=ps18281.dreamhostps.com) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TFZ4O-0002R5-1q for 12490@debbugs.gnu.org; Sat, 22 Sep 2012 19:25:08 -0400 Original-Received: from localhost (ps18281.dreamhostps.com [69.163.218.105]) by ps18281.dreamhostps.com (Postfix) with ESMTP id 9C781451CCEA; Sat, 22 Sep 2012 16:23:21 -0700 (PDT) In-Reply-To: <20120922224229.7baf7964@jcubic> (Jakub Jankiewicz's message of "Sat, 22 Sep 2012 22:42:29 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2.50 (x86_64-pc-linux-gnu) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 140.186.70.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-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:64790 Archived-At: > I want to report, that most used function stop working in Emacs 24 > (tested 2 versions 24.1.1 and latest 24.2.1). I use Search in > Mini buffer a lot (don't know if people use it or not). If you call > search C-s when inside minibuffer like C-h f C-s you can search the > content of Minibuffer like search for functions or for buffer name to > switch like C-x b C-s (better then ido mode). And in Emacs 24 M-x C-s > stop working so I you can't search for interactive function to execute > anymore. It was working in 23.3 provided by Ubuntu (package > 23.3+1-1ubuntu4). Sorry, this feature has been removed by http://debbugs.gnu.org/5214 and http://debbugs.gnu.org/5364 But it's easy to restore it with a simple patch that prepends the current default value (a command at point) to the sorted list of all available command names: === modified file 'lisp/simple.el' --- lisp/simple.el 2012-09-22 20:53:16 +0000 +++ lisp/simple.el 2012-09-22 23:20:41 +0000 @@ -1352,9 +1352,15 @@ (defun read-extended-command () (lambda () ;; Get a command name at point in the original buffer ;; to propose it after M-n. - (with-current-buffer (window-buffer (minibuffer-selected-window)) - (and (commandp (function-called-at-point)) - (format "%S" (function-called-at-point))))))) + (let ((def (with-current-buffer + (window-buffer (minibuffer-selected-window)) + (and (commandp (function-called-at-point)) + (format "%S" (function-called-at-point))))) + (all (sort (minibuffer-default-add-completions) + (lambda (a b) (string< a b))))) + (if def + (cons def (delete def all)) + all))))) ;; Read a string, completing from and restricting to the set of ;; all defined commands. Don't provide any initial input. ;; Save the command read on the extended-command history list.