From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Christian Seberino Newsgroups: gmane.emacs.help Subject: Re: Easy/Possible to globally change prompt strings of messages? e.g. changing find-file's prompt string from "Find file:" to "open file:" ? Date: Fri, 30 Jan 2015 18:38:56 -0600 Message-ID: <54CC2420.9050306@gmail.com> References: <90b92a22-d34c-4f7e-953e-74444f42e767@googlegroups.com> <54CB109E.1030802@gmail.com> <54CC1410.1050408@gmail.com> <54CC2360.20102@gmail.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1422664758 21586 80.91.229.3 (31 Jan 2015 00:39:18 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 31 Jan 2015 00:39:18 +0000 (UTC) To: Drew Adams , help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sat Jan 31 01:39:17 2015 Return-path: Envelope-to: geh-help-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 1YHM5j-0006wV-GW for geh-help-gnu-emacs@m.gmane.org; Sat, 31 Jan 2015 01:39:15 +0100 Original-Received: from localhost ([::1]:39296 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YHM5i-0006oz-KU for geh-help-gnu-emacs@m.gmane.org; Fri, 30 Jan 2015 19:39:14 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:39940) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YHM5X-0006mU-TY for help-gnu-emacs@gnu.org; Fri, 30 Jan 2015 19:39:04 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YHM5S-0000qj-Tn for help-gnu-emacs@gnu.org; Fri, 30 Jan 2015 19:39:03 -0500 Original-Received: from mail-oi0-x232.google.com ([2607:f8b0:4003:c06::232]:62351) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YHM5S-0000qf-PH for help-gnu-emacs@gnu.org; Fri, 30 Jan 2015 19:38:58 -0500 Original-Received: by mail-oi0-f50.google.com with SMTP id h136so37332556oig.9 for ; Fri, 30 Jan 2015 16:38:58 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:subject:references :in-reply-to:content-type:content-transfer-encoding; bh=Gbo25L/BPU2NyjgphHiyMZxbjrjwRQRWX6aBadcJNDc=; b=WYZq7VAxnarDfus7f+fX6vYTvvIQYCvEIJn2J0/PFH5sx4UgT6yrLHv3i9pS5aer8X aDTf9Gjkwe4Q7nV7srQFlnSTgNl4E2GB5EgjxDI3xNk9zDeAQVl11iysbtmrIM23IOlw mI1xAbEoWSMx3cmXpqo9HCP/pwPWumkG8LckmQ/+76Cygi/A+hSDRfObU/Yq/AgayyPy puRz2Rme0JQfmkazyIYtsLkTOxcaOdI4Js5jJ/SqMxce+6Z+b8lGHXnrq/QVBiWMkWr4 afTB+cG77Bu9YMk88k88AXY8lAELkHj04WlaIMZCgl6hNGP5/clbZgAMXAGLeR/XqaRa LNbw== X-Received: by 10.182.73.131 with SMTP id l3mr5341129obv.45.1422664738350; Fri, 30 Jan 2015 16:38:58 -0800 (PST) Original-Received: from [192.168.1.104] (r74-193-13-167.cnrocmta01.conrtx.tl.dh.suddenlink.net. [74.193.13.167]) by mx.google.com with ESMTPSA id m65sm6022431oif.5.2015.01.30.16.38.57 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 30 Jan 2015 16:38:57 -0800 (PST) User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.4.0 In-Reply-To: <54CC2360.20102@gmail.com> X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2607:f8b0:4003:c06::232 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:102391 Archived-At: Here is how I configured my Tramp abbreviations in case the problem is there... (define-abbrev-table 'tramp-abbrev-table '(("d" "/ssh:cs@philfour.com:/home/cs/Ws") ("dr" "/ssh:cs@philfour.com|su:philfour.com:/home") ("w" "/ssh:cs@services.philfour.com:/home/webwork_custom") ("wr" "/ssh:cs@services.philfour.com|su:services.philfour.com:/home"))) (add-hook 'minibuffer-setup-hook (lambda () (abbrev-mode t) (setq local-abbrev-table tramp-abbrev-table))) (defadvice minibuffer-complete (before my-minibuffer-complete activate) (expand-abbrev)) On 01/30/2015 06:35 PM, Christian Seberino wrote: > You may have seen my post regarding this... > > (defun my-find-file-around-ad (origfun &rest args) > (interactive > (find-file-read-args "Open file: " > (confirm-nonexistent-file-or-buffer))) > (apply origfun args)) > > I don't know why that has the same issue of NOT removing the TAB properly > like find-file does. > > Dunno why. > > cs > On 01/30/2015 06:31 PM, Drew Adams wrote: >>>> But yes, you certainly can call `find-file-read-args' (or >>>> `read-file-name') yourself, passing it any prompt you like. You will >>>> get all of the usual TAB completion etc. - no problem. >>> Can I ask if the 2 functions you mentioned above would fix a minor >>> problem with this simple wrapper below?... >>> (defun my-find-file (name) (interactive "sopen file: ") (find-file >>> name)) >> Yes. `find-file-read-args' is made to order for `find-file' and >> similar commands. `read-file-name' is more general - it is called >> by `find-file-read-args'. These provide file-name completion. >> >> You want to read a file name, not a string. > -- ___________________________ Christian Seberino, Ph.D cseberino@gmail.com (936) 828-8747 ___________________________