emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Julian Burgos <julian@hafro.is>
To: Ken <kensubuntu@gmail.com>
Cc: emacs-orgmode@gnu.org
Subject: Re: Newbie question
Date: Fri, 08 Feb 2013 13:15:19 +0000	[thread overview]
Message-ID: <5114FA67.40007@hafro.is> (raw)
In-Reply-To: <20130208125016.GA24558@ken-HP-Mini-110-1000>

Hi Ken,

If you do  <C-u C-c .> you will get an active timestamp with date and 
time. <C-u C-c !> will give you an inactive timestamp with date and time.
I also have this code in my .emacs file, so whenever I create a headline 
I get an inactive timestamp automatically.  It should be easy to change 
to get an active timestamp if you want.

;------------------------------------------------------------------------------
;Creating new headlines insert inactive timestamps automatically

(defun bh/insert-inactive-timestamp ()
(interactive)
(org-insert-time-stamp nil t t nil nil nil))

(defun bh/insert-heading-inactive-timestamp ()
(save-excursion
(org-return)
(org-cycle)
(bh/insert-inactive-timestamp)))

(add-hook 'org-insert-heading-hook 'bh/insert-heading-inactive-timestamp)
;-------------------------------------------------------------------------

Enjoy!

-- 
Julian Mariano Burgos, PhD
Hafrannsóknastofnunin/Marine Research Institute
Skúlagata 4, 121 Reykjavík, Iceland
Sími/Telephone : +354-5752037
Bréfsími/Telefax:  +354-5752001
Netfang/Email: julian@hafro.is



On 02/08/2013 12:50 PM, Ken wrote:
> Hello all,
>
> I am a relative newbie to org-mode. Right now I use it for todo lists, I
> use it in conjunction with the diary, and I use it for
> journaling/note-taking. I am sure I am only using it fo a quarter or
> less of what it can be used for. Anyway, my question is rather simple.
> <CTRL-.> will allow you to insert a date. However, in my journal I use a
> full timestamp. Is there any way using a defined set of keys to insert a
> current TIMESTAMP on an entry (say as in a journal entry)?
>
> Thank you
> Ken
>
>

  reply	other threads:[~2013-02-08 13:15 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-02-08 12:50 Newbie question Ken
2013-02-08 13:15 ` Julian Burgos [this message]
2013-02-08 15:50   ` Ken
2013-02-08 15:12 ` Nick Dokos
  -- strict thread matches above, loose matches on Subject: below --
2018-08-01 14:07 Henrik Frisk
2009-05-11 17:01 Newbie Question Tennis Smith

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

  List information: https://www.orgmode.org/

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

  git send-email \
    --in-reply-to=5114FA67.40007@hafro.is \
    --to=julian@hafro.is \
    --cc=emacs-orgmode@gnu.org \
    --cc=kensubuntu@gmail.com \
    /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 public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).