all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* ffap: Directory does not exist, create it? Yeah sure, without permission
@ 2003-02-27 18:30 Dan Jacobson
  0 siblings, 0 replies; 2+ messages in thread
From: Dan Jacobson @ 2003-02-27 18:30 UTC (permalink / raw)


Using ffap, many a mistype causes the often seen
  Directory does not exist, create it? (y or n)
Well, as 99% of the time, the answer is n, at least it could check
if the user could indeed create a dir there before asking, as the
answer would be
  Creating directory: permission denied, /etc/nurdly/
anyway.

Better would be just to assist the user in typing the names of
existing files, i.e. don't wipe out what he has typed so far...
-- 
http://jidanni.org/ Taiwan(04)25854780

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: ffap: Directory does not exist, create it? Yeah sure, without permission
       [not found] <mailman.2552.1046386654.21513.bug-gnu-emacs@gnu.org>
@ 2003-03-04 18:59 ` Kevin Rodgers
  0 siblings, 0 replies; 2+ messages in thread
From: Kevin Rodgers @ 2003-03-04 18:59 UTC (permalink / raw)


Dan Jacobson wrote:

> Using ffap, many a mistype causes the often seen
>   Directory does not exist, create it? (y or n)
> Well, as 99% of the time, the answer is n, at least it could check
> if the user could indeed create a dir there before asking, as the
> answer would be
>   Creating directory: permission denied, /etc/nurdly/
> anyway.


*** emacs-20.7/lisp/ffap.el.orig	Sat Feb 13 07:42:35 1999
--- emacs-20.7/lisp/ffap.el	Tue Mar  4 11:54:20 2003
***************
*** 1658,1664 ****
         (if (file-directory-p filename)
   	  (dired (expand-file-name filename))
   	(dired (concat (expand-file-name filename) "*"))))
!      ((y-or-n-p "Directory does not exist, create it? ")
         (make-directory filename)
         (dired filename))
        ((error "No such file or directory `%s'" filename)))))
--- 1658,1665 ----
         (if (file-directory-p filename)
   	  (dired (expand-file-name filename))
   	(dired (concat (expand-file-name filename) "*"))))
!      ((and (file-writable-p (file-name-directory filename))
! 	   (y-or-n-p "Directory does not exist, create it? "))
         (make-directory filename)
         (dired filename))
        ((error "No such file or directory `%s'" filename)))))

> Better would be just to assist the user in typing the names of
> existing files, i.e. don't wipe out what he has typed so far...

???

-- 
<a href="mailto:&lt;kevin.rodgers&#64;ihs.com&gt;">Kevin Rodgers</a>

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2003-03-04 18:59 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-02-27 18:30 ffap: Directory does not exist, create it? Yeah sure, without permission Dan Jacobson
     [not found] <mailman.2552.1046386654.21513.bug-gnu-emacs@gnu.org>
2003-03-04 18:59 ` Kevin Rodgers

Code repositories for project(s) associated with this external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.