From mboxrd@z Thu Jan 1 00:00:00 1970 From: Zachary Young Subject: Re: Make a time-stamp non-interactively Date: Wed, 14 Apr 2010 19:19:32 -0700 Message-ID: References: Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1710698424==" Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1O2EgE-0007e4-1k for emacs-orgmode@gnu.org; Wed, 14 Apr 2010 22:19:46 -0400 Received: from [140.186.70.92] (port=54830 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1O2EgC-0007cl-OF for emacs-orgmode@gnu.org; Wed, 14 Apr 2010 22:19:45 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1O2EgB-0003o0-F1 for emacs-orgmode@gnu.org; Wed, 14 Apr 2010 22:19:44 -0400 Received: from mail-qy0-f185.google.com ([209.85.221.185]:37167) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1O2EgB-0003nw-9j for emacs-orgmode@gnu.org; Wed, 14 Apr 2010 22:19:43 -0400 Received: by qyk15 with SMTP id 15so1023024qyk.10 for ; Wed, 14 Apr 2010 19:19:42 -0700 (PDT) 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: emacs-orgmode@gnu.org --===============1710698424== Content-Type: multipart/alternative; boundary=00163630f5ab1a9c1f04843d20e6 --00163630f5ab1a9c1f04843d20e6 Content-Type: text/plain; charset=UTF-8 Hi all, Sorry, I did some more digging right after I sent this, and found the following in org-remember.el: (ct (or org-overriding-default-time (org-current-time))) (format-time-string (car org-time-stamp-formats) ct) So, there it is. Thank you, Zachary On Wed, Apr 14, 2010 at 6:56 PM, Zachary Young wrote: > Hi all, > > I'm still new to elisp, so forgive me if I am missing something obvious... > > I would like to make an orgmode active time-stamp from within a custom > function I am writing. I have looked at `org-time-stamp' but do not see a > way to call this in a *non-interactive* fashion from my code. Inside > `org-time-stamp' I was looking for a "core time-stamp function" that the > interactive functions would call... but could not make one out. Is there a > function already defined that when called will make a time-stamp with > default values? > > If not, can someone point out the lines of code inside `org-time-stamp' > that I can duplicate in my own code? > > I would prefer not to have to make a macro. > > Thank you, > Zachary > --00163630f5ab1a9c1f04843d20e6 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Hi all,

Sorry, I did some more digging right after I sen= t this, and found the following in org-remember.el:

(ct (or org-overriding-default-time (org-current-time)))
(format-time-= string (car org-time-stamp-formats) ct)

So, there it is.

Thank you,
Zachary

On Wed, Apr 14, 20= 10 at 6:56 PM, Zachary Young <zacharysyoung@gmail.com> wrote:
Hi all,

I'm still ne= w to elisp, so forgive me if I am missing something obvious...
I would like to make an orgmode active time-stamp from within a = custom function I am writing. I have looked at `org-time-stamp' but do = not see a way to call this in a *non-interactive* fashion from my code. Ins= ide `org-time-stamp' I was looking for a "core time-stamp function= " that the interactive functions would call... but could not make one = out. Is there a function already defined that when called will make a time-= stamp with default values?

If not, can someone point out the lines of code inside = `org-time-stamp' that I can duplicate in my own code?

I would prefer not to have to make a macro.

Thank you,
Zachary

--00163630f5ab1a9c1f04843d20e6-- --===============1710698424== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode --===============1710698424==--