all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Thierry Volpiatto <thierry.volpiatto@gmail.com>
To: emacs-devel@gnu.org
Subject: dired touch command initial input
Date: Tue, 17 Aug 2010 15:04:42 +0200	[thread overview]
Message-ID: <87wrrptmol.fsf@tux.homenetwork> (raw)

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 




             reply	other threads:[~2010-08-17 13:04 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-08-17 13:04 Thierry Volpiatto [this message]
2010-08-17 16:37 ` dired touch command initial input Andreas Schwab
2010-08-18  7:11   ` Thierry Volpiatto

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=87wrrptmol.fsf@tux.homenetwork \
    --to=thierry.volpiatto@gmail.com \
    --cc=emacs-devel@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.