help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: timestamp in emacs


From: Martin Stemplinger
Subject: Re: timestamp in emacs
Date: Wed, 05 May 2004 22:01:08 +0200
User-agent: Gnus/5.1006 (Gnus v5.10.6) Emacs/21.3.50 (gnu/linux)

On Mit Mai 05 2004 at 18:21, Antonio Garcia <agm@socrates.berkeley.edu> wrote:

> I would like to easily interject a timestamp, a la date command, in a
> buffer in emacs. 

You can use (the time format adapted of course)

(defun insert-timestamp ()
  "German timestamp insertion function."
  (interactive)
  (insert (format-time-string "%H:%M %d.%m.%Y")))

(defun insert-date()
  "German date insertion function."
  (interactive)
  (insert (format-time-string "%d.%m.%Y")))

There was also a niftier version, probably in gnu.emacs.sources, that
uses different formats depending on arguments.

Is this what you are looking for? 

HTH
MArtin
-- 
Remove NOSPAM to reply by mail


reply via email to

[Prev in Thread] Current Thread [Next in Thread]