emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: "Charles C. Berry" <ccberry@ucsd.edu>
To: John Kitchin <jkitchin@andrew.cmu.edu>
Cc: org-mode mailing list <emacs-orgmode@gnu.org>,
	Vikas Rawal <vikaslists@agrarianresearch.org>
Subject: Re: adding attributes to tables in results
Date: Sat, 21 Nov 2015 12:04:56 -0800	[thread overview]
Message-ID: <alpine.OSX.2.20.1511211152550.561@charles-berrys-macbook.local> (raw)
In-Reply-To: <m2lh9rdw2c.fsf@andrew.cmu.edu>

On Sat, 21 Nov 2015, John Kitchin wrote:

> I am running a search committee of 5 people. As applications come in, an
> org heading is created for each application, and I run a command to send
> one of the committee an email with a review rubric in it, and this
> command creates a subheading to put their review. We have 275
> applications so far, so I am using code to aggregate results into tables.

Ouch! That is serious work!

[snip]
>
> The tip Charles gave works for export, but the tables do not look too
> good for me in the org-document unless I run C-c ' on them to get them
> in org, and I also want them functional in the org-buffer too.
>
>

Use a different wrapper for executing src block outside of exports.

Something like this (with suitable tuning) should work:

#+BEGIN_SRC emacs-lisp
   (defun ex-aware-wrap ()
       (if org-export-current-backend
 	  (concat "src org :exports results "
 		  ":results  replace "
 		  "\n#+ATTR_LATEX: "
 		  ":environment longtable")
 	"example"))
#+END_SRC

#+BEGIN_SRC emacs-lisp :exports results :wrap (ex-aware-wrap)
(list (+ 1 2) 3 4)
#+END_SRC

HTH,

Chuck

  reply	other threads:[~2015-11-21 20:05 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-11-21 13:55 adding attributes to tables in results John Kitchin
2015-11-21 17:40 ` Charles C. Berry
2015-11-21 18:04   ` John Kitchin
2015-11-21 18:09     ` Vikas Rawal
2015-11-21 18:52       ` John Kitchin
2015-11-21 20:04         ` Charles C. Berry [this message]
2015-11-21 21:45           ` John Kitchin

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=alpine.OSX.2.20.1511211152550.561@charles-berrys-macbook.local \
    --to=ccberry@ucsd.edu \
    --cc=emacs-orgmode@gnu.org \
    --cc=jkitchin@andrew.cmu.edu \
    --cc=vikaslists@agrarianresearch.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 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).