all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: "andreas.amann" <andreas.amann@tyndall.ie>
To: emacs-pretest-bug@gnu.org
Subject: bug#1238: 23.0.60; ido-write-file makes it easy to overwrite files unintentionally
Date: Fri, 24 Oct 2008 11:53:00 +0100	[thread overview]
Message-ID: <200810241053.m9OAr0P8026782@localhost.localdomain> (raw)


I am often using the C-x C-w shortcut to save a buffer into a
different directory, usually without changing it's name. 

The standard write-file works well for this, since after selecting the
appropriate directory, I simply hit return, and the file gets saved
where I want it, without a change in the name by default. 

However, since I switched to ido-mode and ido-write-file I found that
after navigating to a directory, which does not contain any
subdirectories, the first filename in that directory gets selected as
the filename, into which to write the contents of the active
buffer. This has several times already caused me to overwrite a file
with the current buffer by accident, since after selecting the
appropriate directory, I was not noticing the selection and wrongly
assumed that emacs would simply write the file into this directory
with the old filename. After hitting return however the active buffer
would be written into this first file of the directory.

I know I can simply work around this by binding C-x C-w to write-file,
but in my opinion, ido-write-file should be changed in a way which
makes it more difficult to overwrite a file. I would expect that C-x
C-w is used for more often to create a new file, than to overwrite an
existing one. Therefore in my opinion the current behaviour of
ido-write-file to select the first file in the directory only serves
a minority of use-cases.


In GNU Emacs 23.0.60.1 (x86_64-unknown-linux-gnu, X toolkit, Xaw3d scroll bars)
 of 2008-10-20 on lnx0015f2465ec6
Windowing system distributor `The X.Org Foundation', version 11.0.10300000
configured using `configure  '--prefix=/home/aamann/local/emacs-cvs' 'LDFLAGS=-L/home/aamann/local/lib64' 'CPPFLAGS=-I/home/aamann/local/include''

Important settings:
  value of $LC_ALL: nil
  value of $LC_COLLATE: nil
  value of $LC_CTYPE: nil
  value of $LC_MESSAGES: nil
  value of $LC_MONETARY: nil
  value of $LC_NUMERIC: nil
  value of $LC_TIME: nil
  value of $LANG: en_IE.utf8
  value of $XMODIFIERS: @im=none
  locale-coding-system: utf-8-unix
  default-enable-multibyte-characters: t

Major mode: Lisp Interaction

Minor modes in effect:
  shell-dirtrack-mode: t
  tooltip-mode: t
  tool-bar-mode: t
  mouse-wheel-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  blink-cursor-mode: t
  global-auto-composition-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  line-number-mode: t
  transient-mark-mode: t

Recent input:
M-x i d o - m o d <tab> <return> C-x C-w C-g M-x w 
r i t e - f <tab> <return> C-g M-x i d o - w r i <tab> 
<return> C-g C-x C-w C-g C-h C-b C-h b C-x o C-s w 
r i t e <up> <up> <down> <down> <left> <left> <left> 
C-x o M-x w e m <backspace> <backspace> <backspace> 
e m a c s <tab> b <tab> <backspace> <backspace> <backspace> 
<backspace> <backspace> <backspace> <backspace> <backspace> 
<backspace> <backspace> <backspace> <backspace> <backspace> 
<backspace> <backspace> <backspace> <backspace> <backspace> 
<backspace> <backspace> <backspace> <backspace> <backspace> 
b u g <tab> <tab> <backspace> <backspace> <backspace> 
<backspace> <backspace> <backspace> <backspace> <backspace> 
<backspace> <backspace> <backspace> <backspace> <backspace> 
<backspace> r e p <tab> o r <tab> <return>

Recent messages:
For information about GNU Emacs and the GNU system, type C-h C-a.
Ido mode enabled
Quit [4 times]
Type C-x 1 to delete the help window, C-M-v to scroll help.
Mark saved where search started
Making completion list... [2 times]






             reply	other threads:[~2008-10-24 10:53 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-10-24 10:53 andreas.amann [this message]
2010-11-13 14:57 ` bug#1238: ido-write-file makes it easy to overwrite files unintentionally Ryan Twitchell
2010-12-17 10:56   ` Chong Yidong

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

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

  git send-email \
    --in-reply-to=200810241053.m9OAr0P8026782@localhost.localdomain \
    --to=andreas.amann@tyndall.ie \
    --cc=1238@emacsbugs.donarmstrong.com \
    --cc=emacs-pretest-bug@gnu.org \
    /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 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.