From: Matt Price <moptop99@gmail.com>
Cc: Org Mode <emacs-orgmode@gnu.org>
Subject: Re: generating org headings from a source block
Date: Tue, 10 Nov 2015 11:31:03 -0500 [thread overview]
Message-ID: <CAN_Dec_ikQTm1yxzJdseAtyTuwjgw3hvSyTuD8a_ThvX3sKDfA@mail.gmail.com> (raw)
In-Reply-To: <87si4dg79b.fsf@alphaville.usersys.redhat.com>
[-- Attachment #1: Type: text/plain, Size: 759 bytes --]
On Tue, Nov 10, 2015 at 11:16 AM, Nick Dokos <ndokos@gmail.com> wrote:
>
> > Pass the level as a parameter?
> >
> > Can I pass the level of the current heading as a parameter, e.g.:
> >
> > where obviously CURRENT-ORG-LEVEL is some function I don't know how to
> access?
> >
>
> You can at the very least set the level manually:
>
> #+BEGIN_SRC elisp :results output raw :var level=3
> ...
>
> by just eyeballing where the source block is in your file.
> I think that's easy and does not require any programming.
> You just have to remember to change the level when you cut
> and paste the code block to other places.
>
> There is org-current-level though if you want to go that way.
>
> :var level=(1+ (org-current-level))
works great. Thank you Nick!
[-- Attachment #2: Type: text/html, Size: 1209 bytes --]
prev parent reply other threads:[~2015-11-10 16:31 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-11-09 20:29 generating org headings from a source block Matt Price
2015-11-09 21:57 ` Nick Dokos
2015-11-10 14:28 ` Matt Price
2015-11-10 16:16 ` Nick Dokos
2015-11-10 16:31 ` Matt Price [this message]
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAN_Dec_ikQTm1yxzJdseAtyTuwjgw3hvSyTuD8a_ThvX3sKDfA@mail.gmail.com \
--to=moptop99@gmail.com \
--cc=emacs-orgmode@gnu.org \
/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 external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.