all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* dired touch command initial input
@ 2010-08-17 13:04 Thierry Volpiatto
  2010-08-17 16:37 ` Andreas Schwab
  0 siblings, 1 reply; 3+ messages in thread
From: Thierry Volpiatto @ 2010-08-17 13:04 UTC (permalink / raw)
  To: emacs-devel

Hi all,
actually the dired touch command "T" use the more recent timestamp of
the marked files for initial value.

I wonder why it does not take the current-time as initial input like the
touch command does and like it is described in manual:

,----
| `T TIMESTAMP <RET>'
|      Touch the specified files (`dired-do-touch').  This means updating
|      their modification times to the present time.  This is like the
|      shell command `touch'.
`----

So why not using this simple version of `dired-touch-initial' instead:

,----
| (defun dired-touch-initial (files)
|   "Create initial input value for `touch' command."
|   (format-time-string "%Y%m%d%H%M.%S" (current-time)))
`----

It is annoying to modify the prompt manually to insert current time.

But maybe there is a special reason to use the more recent timestamp or
the current timestamp if only one file?

In this case that should be specified in the manual (different behavior
than usual shell command).

Otherwise, i will submit a bug.

-- 
Thierry Volpiatto
Get my Gnupg key:
gpg --keyserver pgp.mit.edu --recv-keys 59F29997 




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

end of thread, other threads:[~2010-08-18  7:11 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-08-17 13:04 dired touch command initial input Thierry Volpiatto
2010-08-17 16:37 ` Andreas Schwab
2010-08-18  7:11   ` Thierry Volpiatto

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.