From mboxrd@z Thu Jan 1 00:00:00 1970 From: Eric Schulte Subject: Re: Programmatically insert source-blocks Date: Sat, 23 Mar 2013 16:35:04 -0600 Message-ID: <87k3oxpwvu.fsf@gmail.com> References: <87k3p1q2xj.fsf@gmail.com> <8738vppw44.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([208.118.235.92]:52654) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UJX2c-0002Tv-BJ for emacs-orgmode@gnu.org; Sat, 23 Mar 2013 18:35:59 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UJX2a-0003l8-Lc for emacs-orgmode@gnu.org; Sat, 23 Mar 2013 18:35:58 -0400 Received: from mail-ia0-x235.google.com ([2607:f8b0:4001:c02::235]:56653) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UJX2a-0003kQ-HI for emacs-orgmode@gnu.org; Sat, 23 Mar 2013 18:35:56 -0400 Received: by mail-ia0-f181.google.com with SMTP id o25so4507776iad.26 for ; Sat, 23 Mar 2013 15:35:56 -0700 (PDT) List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Thorsten Jolitz Cc: emacs-orgmode@gnu.org > So here is my FEATURE REQUEST: > > either modify `org-babel-demarcate-block' so that it can be used to > insert a language-specific code-block (with args?) non-interactively, or > add something like `org-insert-block' to Org-mode's core. I would prefer > signature > > ,---------------------------------------------- > | (defun org-insert-block (lang &rest args)...) > `---------------------------------------------- > > to be able to specify the src-block headline exactly in a program that > uses this function. This function may be easily written outside of Org-mode by anyone who needs it. I don't see that Org-mode itself will ever want to programatically and non-interactively insert a code block in an Org-mode file (if fact that sounds rather dangerous to me), so I would vote against adding such a function to the core. -- Eric Schulte http://cs.unm.edu/~eschulte