unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Luc Teirlinck <teirllm@dms.auburn.edu>
Subject: insert-default-directory
Date: Sun, 25 Jan 2004 22:13:04 -0600 (CST)	[thread overview]
Message-ID: <200401260413.i0Q4D4W13015@raven.dms.auburn.edu> (raw)

I might be missing some obvious things, but I have the impression that
a nil value for the user option `insert-default-directory' is not very
well supported.  The user can make `read-file-name' return an empty
string by erasing all inserted minibuffer contents.  But if
`insert-default-directory' is nil and the INITIAL argument to
`read-file-name' is nil (as recommended) then there is no string to
erase and just typing RETURN with an empty minibuffer selects some
default value instead of "".  This matters for certain commands.  For
instance, I might be missing something, but I know of no convenient
and intuitive way to make the current buffer visit no file using M-x
set-visited-file-name if `insert-default-directory' is nil.

Other problem:

Start emacs -q

I then do:

(setq `insert-default-directory' nil)
(read-directory-name "Name: " "~/emacscvsdir/" nil t)

"emacscvsdir" is where I keep the Emacs CVS.  That directory contains
a directory named "manual".  I want to select that directory.  I type
"manual" in the minibuffer.  RETURN. It gets completed to "manual/".
Fine, I do not mind about the "/".  RETURN.  Instead of accepting
"manual/", `read-directory-name' now insists on trying to complete to
a subdirectory of the "manual" directory.  The same problem occurs
when using `read-file-name' for directories.

With `insert-default-directory' set to t, `read-directory-name'
happily accepts "manual/" without trying completion.  It even accepts
"manual" too.

Sincerely,

Luc.

             reply	other threads:[~2004-01-26  4:13 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-01-26  4:13 Luc Teirlinck [this message]
2004-01-26 19:23 ` insert-default-directory Richard Stallman
2004-01-27  3:04   ` insert-default-directory Luc Teirlinck

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200401260413.i0Q4D4W13015@raven.dms.auburn.edu \
    --to=teirllm@dms.auburn.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).