From mboxrd@z Thu Jan 1 00:00:00 1970 From: Brian van den Broek Subject: Re: Emacs/Org-mode question Date: Fri, 31 Jul 2009 17:45:43 -0400 Message-ID: <4A736607.6060704@gmail.com> References: Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MWzuu-0006ot-TG for emacs-orgmode@gnu.org; Fri, 31 Jul 2009 17:45:32 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MWzuq-0006jI-Eh for emacs-orgmode@gnu.org; Fri, 31 Jul 2009 17:45:32 -0400 Received: from [199.232.76.173] (port=33219 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MWzuq-0006j9-7s for emacs-orgmode@gnu.org; Fri, 31 Jul 2009 17:45:28 -0400 Received: from ironport2-out.pppoe.ca ([206.248.154.182]:50685 helo=ironport2-out.teksavvy.com) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MWzup-000413-US for emacs-orgmode@gnu.org; Fri, 31 Jul 2009 17:45:28 -0400 In-Reply-To: List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Markus Heller Cc: emacs-orgmode@gnu.org Markus Heller said unto the world at 31/07/09 05:39 PM: > Hello all, > > this might be a typical beginner question ... > > I often use the sequence > > C-. C-- : > > to create this: > > - <2009-07-31 Fri>: > > where the date is today's date. > > I'm sure there's a way to create a command for this, but I have no idea > how. I'd like to bind this sequence to something like C-c t or similar. > > How do I do this? > > Thanks and Cheers > Markus Hi Markus, I have the following in my .emacs: (defun date () (interactive "*") (insert (format-time-string "%Y-%m-%d %T" (current-time)))) (global-set-key [f11] 'date) This will at least get you started. See the documentation for format-time-string to season as suits. Best, Brian vdB