Re: [O] Moving from Jekyll to Orgmode

2018-04-29 Thread Ista Zahn
On Sun, Apr 29, 2018 at 4:50 AM, ST  wrote:
> Hi Scott,
>
> thank you, and all other responders, for the shared information. The
> reason I want to leave Jekyll is because I don't want to depend on a
> tool that relies on language (Ruby)/environment that I don't know/use
> (in this respect Hugo is the same for me). I prefer something more
> simplistic, even though if I'll have to invest some time for it to work
> initially. Those 3 features I've mentioned are almost all I need, more
> or less.
>
> Could you, please, share your website publishing workflow (considering
> the 3 issues I've mentioned)?

I use Nikola (https://getnikola.com/). It has a plugin for org source files
(https://plugins.getnikola.com/v8/orgmode/). It claims to support
multilingual sites, though I have not used that feature.

--Ista

>
> Thank you!
>
> On Sat, 2018-04-28 at 18:13 -0400, Scott Randby wrote:
>> On 04/28/2018 05:40 PM, Diego Zamboni wrote:
>> >
>> > Org-mode is not really a website-publishing tool like Jekyll, although it 
>> > can be part of the chain. Org-mode at its core is a markup language, 
>> > although with considerable tooling support from org-mode and related tools 
>> > in Emacs.
>> >
>>
>> I think Org is a good website publishing tool in many ways. I've been using 
>> it for making and publishing my website since 2010. Sure, it has some 
>> limitations, but I think it can be made to work nicely for a lot of types of 
>> sites. But I do agree that the Org/Hugo combination is really good.
>>
>> Scott Randby
>>
>
>



Re: [O] ob-python newline & indentation behavior

2017-11-25 Thread Ista Zahn
ob-ipython[1] provides a working alternative:

#+BEGIN_SRC jupyter-python :session :results output
  foo = 0
  for _ in range(10):
  foo += 1

  foo += 1

  print(foo)
#+END_SRC

#+RESULTS:
: 20

I've long wished that more org people would show ob-ipython some love.
Letting jupyter handle things on the backend seems like it should
simplifly things considerably.

[1] https://github.com/gregsexton/ob-ipython

Best,
Ista

On Tue, Nov 21, 2017 at 3:28 AM, Jack Kamm  wrote:
> Yes, I'm starting to see now how difficult it is to properly support
> ":session :results value". I would vote to remove it from ob-python...
>
> I think the patch still improves ":session :results output" so I will
> simplify it and restrict to that case, leaving ":session :results value"
> unchanged for now.
>
> Sorry for sending this twice Kyle, forgot to reply all.
>
> On 21 Nov 2017 4:04 am, "Kyle Meyer"  wrote:
>>
>> Jack Kamm  writes:
>>
>> > In response to this:
>> >
>> >> I can't think of a good solution, though.  Stepping back a bit, I think
>> >> it's unfortunate that python blocks handle ":results value" differently
>> >> depending on whether the block is hooked up to a session or not.  For
>> >> non-sessions, you have to use return.  Using the same approach
>> >> (org-babel-python-wrapper-method) for ":session :results value", we
>> >> could then get the return value reliably, but the problem with this
>> >> approach is that any variables defined in a ":results value" block
>> >> wouldn't be defined in the session after executing the block because
>> >> the
>> >> code is wrapped in a function.
>> >
>> > How about if we used the "globals()" and "locals()" functions in Python?
>> >
>> > Something like this at the end of the wrapper block, before return:
>> >
>> > for k, v in locals().items():
>> > globals()[k] = v
>>
>> Hmm, placing that code "before return" is a problem.  Like with
>> non-session ":results value" blocks, the user would be responsible for
>> inserting the return (or even multiple return's), so we can't know where
>> to insert the above code without parsing the block :/
>>
>> > Another bug with the current approach is that it breaks if common idioms
>> > like "for _ in range(10)" are used. ("_" is used to inspect the last
>> > output
>> > of the shell, an obscure feature I hadn't known about until now).
>>
>> Right.  Also, IIRC the built-in interactive python and ipython treat
>> multiline blocks differently.  With
>>
>> if True:
>> "ipython ignores my existence"
>>
>> the built-in shell binds "_" to the string's value, but ipython doesn't.
>>
>> --
>> Kyle



Re: [O] v9.0 running babel blocks

2016-11-28 Thread Ista Zahn
On Nov 28, 2016 5:54 AM, "Alan Schmitt" 
wrote:
>
> Hello again,
>
> On 2016-11-28 09:01, Alan Schmitt  writes:
>
> > I'm sorry to write again about this, but the problem has come back, and
> > reinstalling org-plus-contrib did not make it go away this time.

Do you perhaps have both org and org-plus-contrib installed? If so, remove
org, then remove and reinstall org-plus-contrib.

--Ista
> >
> > I'm pretty sure this is not a problem with org itself, but some
> > interaction with other packages (I'm using Spacemacs so there are many
> > things happening under the hood). I don't know what to do to start
> > investigating. Would you have suggestions?
>
> I'm also seeing some other very strange behavior. For instance, while
> editing an org-beamer file, the function org-beamer-select-environment
> (bound to C-c C-b) is just the tagging function (bound to C-c C-q). To
> get the beamer behavior, I need to evaluate the defun of
> org-beamer-select-environment, and then all works well until the next
> time I restart emacs.
>
> I have no idea how such a thing would happen. Any suggestions?
>
> Thanks,
>
> Alan
>
> --
> OpenPGP Key ID : 040D0A3B4ED2E5C7
> Monthly Athmospheric CO₂, Mauna Loa Obs. 2016-10: 401.57, 2015-10: 398.29


Re: [O] interesting dilemma with ob-ipython

2016-06-28 Thread Ista Zahn
On Fri, Jun 10, 2016 at 10:19 AM, John Kitchin  wrote:
> Thanks for this tip. It was a great start! I turned it into this:
>
> #+BEGIN_SRC emacs-lisp
> ;; make src blocks open in the right mode
> (add-to-list 'org-src-lang-modes '("jupyter-hy" . hy))
> (add-to-list 'org-latex-minted-langs '(jupyter-hy  "hylang"))
>
> ;; set default headers for convenience
> (setq org-babel-default-header-args:jupyter-hy
>   '((:results . "output replace")
> (:session . "hy")
> (:kernel . "hy")
> (:exports . "code")
> (:cache .   "no")
> (:noweb . "no")
> (:hlines . "no")
> (:tangle . "no")))
>
> (defalias 'org-babel-execute:jupyter-hy 'org-babel-execute:ipython)
>
> (add-to-list 'org-structure-template-alist
>  '("hy" "#+BEGIN_SRC jupyter-hy\n?\n#+END_SRC"
>"\n?\n"))
> #+END_SRC
>
> Which solves all the problems!
> 1. src-blocks open in hy-mode and export as hylang in minted.
> 2.  3. C-c C-c runs the block using the hy jupyter kernel.

I worked up some code to do this for all installed jupyter kernels.
It's kind of rough (my elisp is not so good) by I submitted it as a
pull request at https://github.com/gregsexton/ob-ipython/pull/74. I
would appreciate any feedback or suggestions for improvement.

--Ista

>
> Fantastic. Thanks!
>
>
> Anthony Cowley writes:
>
>> John Kitchin writes:
>>
>>> I was looking into ob-ipython as a replacement for regular
>>> org-babel-python because it seems to be better at sessions. Also, you
>>> can use other kernels with it!
>>>
>>> For example:
>>>
>>> #+BEGIN_SRC ipython :session hy :results output :kernel hy
>>> (print "hello world")
>>> (import time)
>>> (print (time.asctime))
>>> #+END_SRC
>>>
>>> #+RESULTS:
>>> : hello world
>>> : Thu Jun  9 17:26:56 2016
>>>
>>> Here is the dilemma:
>>> If I special edit this, it is in python-mode, not hy-mode. And similarly
>>> on export, it is highlighted as ipython, not hy-lang.
>>>
>>> Any thoughts on how to address these?
>>
>> I've had success using something like this,
>>
>> (add-to-list 'org-src-lang-modes '("ipython" . haskell))
>>
>> in a :noexport: setup section.
>>
>> Anthony
>
>
> --
> Professor John Kitchin
> Doherty Hall A207F
> Department of Chemical Engineering
> Carnegie Mellon University
> Pittsburgh, PA 15213
> 412-268-7803
> @johnkitchin
> http://kitchingroup.cheme.cmu.edu
>



Re: [O] exporting documents w/ babel results w/o evaluating babel blocks

2016-05-24 Thread Ista Zahn
On Tue, May 24, 2016 at 6:17 AM, Andreas Kiermeier
 wrote:
> I second that.
> I like exporting everything to LaTeX without having to re-run all the code,
> which in many cases can add considerable time.

Which you can still do, I guess by

(setq org-babel-default-header-args
  (cons '(:eval . "never-export")
   (assq-delete-all :noweb org-babel-default-header-args)))

instead of the old way

(setq org-export-babel-evaluate nil)

I'm not saying this is good or right. IMO the old behavior of
org-export-babel-evaluate made sense and was useful; the new behavior
is surprising and I have a hard time seeing how it is useful. One can
argue (as Chuck has) that the new behavior is fine sense we have
another way of achieving the desired results; that may be, but I have
yet to see an explanation of why the new behavior is desirable.

It this change is not going to be reversed than the doc string for
org-export-babel-evaluate needs to be updated, and something should go
in the NEWS file warning people (like me) who have been relying on the
old behavior.

Best,
Ista

> Cheers,
> Andreas
>
> On 24 May 2016 at 11:04, Grant Rettke  wrote:
>>
>> On Sun, May 22, 2016 at 4:52 PM, Charles C. Berry 
>> wrote:
>> > TL;DR: Org babel headers give excellent control over what gets run,
>> > when it gets run, and how. Users should use them.
>>
>> Definitely!
>>
>> > Don't reset `org-export-babel-evaluate'.
>>
>> Why not?
>>
>> It can be nice to disable org-export-babel-evaluate by setting it to
>> `nil'.
>>
>> That way you separate your workflow into two distinct steps: one for
>> execution and one for weaving.
>>
>> It would be fun to "see" everyone's Org-Mode workflows; I bet there
>> are a lot of nice approaches.
>>
>



Re: [O] Super indent when editing R blocks and using a # comment

2016-01-28 Thread Ista Zahn
I'm pretty sure that's standard ess indentation. I don't think it has
anything to do with org mode.

Best,
Ista
On Jan 28, 2016 4:59 PM, "John Hendy"  wrote:

> Find attached a screenshot of the behavior I'm experiencing with this
> minimal config and =emacs -Q=.
>
> #+begin_src min-config
>
> ;; set load paths
> ;; set load dirs and global config options
> (add-to-list 'load-path "~/.elisp/org.git/lisp/")
> (add-to-list 'load-path "~/.elisp/org.git/contrib/lisp")
> (add-to-list 'load-path "~/.elisp/ess/lisp/")
>
> (require 'ess-site)
>
> ;; setup babel languages
> (org-babel-do-load-languages
>  'org-babel-load-languages
>  '((R . t)))
>
> #+end_src
>
> As shown in the shot:
> - create a .org file, insert a #+begin/end_src R block
> - edit with =C-c '=
> - start a line with a comment char (#)
> - press RET
> - it gets indented halfway across the page
>
> Inside a function, it seems to use a default of four spaces (the
> position of =return(i^2)=), so I'm not sure why a comment triggers
> such a massive indent. I end up having to delete the preceding spaces
> or be super careful about having a newline already inserted so that I
> can arrow down instead of pressing RET at the end of a comment line.
>
>
> Thanks for any insights!
> John
>


Re: [O] [PATCH] org-babel-execute-src-block-region

2015-11-11 Thread Ista Zahn
I recommend using polymode[1] as a more general solution to the need to
interact with code blocks without pulling up a separate edit buffer. It
seamlessly switches major modes when point is inside a code block.

Best,
Ista

[1] https://github.com/vspinu/polymode
On Nov 11, 2015 12:11 AM, "Xebar Saram"  wrote:

> Hi
>
> I actually find it annoying in ESS to keep pressing C-c ' each time i want
> to eval a single line of code in a code block. if this could work for R
> code this would be fantastic for me
>
> thx
>
> Z
>
> On Tue, Nov 10, 2015 at 8:19 PM, Carlos Henrique Machado S Esteves <
> ch.machado.este...@gmail.com> wrote:
>
>> Hello Chuck,
>>
>> Thank you for the feedback.
>>
>> > You might want to check that point and mark are both inside the src
>> block. Otherwise, the results are unpredictable.
>> You are right, I've updated the patch.
>>
>> > ess-mode, python-mode, sh-mode and octave-mode already provide this
>> capability (and a lot more) for R, python, shell scripts, octave/matlab and
>> some other languages from the edit buffer.
>> I understand that. My idea is to avoid the need to C-c ' back and forth.
>> Actually that's a problem I have with org-babel; I usually find myself
>> coding inside the src block and losing many of the major mode
>> functionalities; switching to the edit buffer often seem too much of a
>> hassle. Any tips about how to get more major-mode functionalities inside
>> the src-block? Or should I develop the muscle memory to switch back and
>> forth to the edit buffer all the time?
>>
>> > `org-babel-demarcate-block' gives the user the ability to break up src
>> blocks into smaller pieces so they can be run independently.
>> Thanks for pointing that; I didn't know about `org-babel-demarcate-block'.
>>
>> Best,
>>
>> Carlos
>>
>> 2015-11-02 13:19 GMT-05:00 Charles C. Berry :
>>
>>> On Sun, 1 Nov 2015, Carlos Henrique Machado S Esteves wrote:
>>>
>>> Hello, I find it useful to be able to execute only a region of a source
 code block, so I've implemented a new function for that. I've tested it
 with MATLAB and Python, but it should work for any mode, since it calls
 org-babel-execute-src-block.


>>> You might want to check that point and mark are both inside the src
>>> block. Otherwise, the results are unpredictable.
>>>
>>> Also note that:
>>>
>>> ess-mode, python-mode, sh-mode and octave-mode already provide this
>>> capability (and a lot more) for R, python, shell scripts, octave/matlab and
>>> some other languages from the edit buffer.
>>>
>>> `org-babel-demarcate-block' gives the user the ability to break up src
>>> blocks into smaller pieces so they can be run independently.
>>>
>>> Best,
>>>
>>> Chuck
>>>
>>>
>>
>


Re: [O] Some projects

2015-10-27 Thread Ista Zahn
On Tue, Oct 27, 2015 at 9:42 AM, Rasmus  wrote:
> Hi,
>
> Rainer M Krug  writes:
>
>> I don't know which OS you are using, but just checking on
>> [[https://github.com/jgm/pandoc/releases/1.15.1]] and
>> [[https://github.com/jgm/pandoc/releases/tag/1.15.1.1]]:
>>
>> Windows: 19.7 MB
>> Mac: 27.9 MB
>> Deb: 20.2 MB
>>
>> The 1600MB must be including LaTeX?
>
> Nope, but something like 100 haskell libraries and ghc.  I guess it’s not
> build in a static way?
>
> It’s much smaller on Debian, approx. 25Mb.  (I should switch to Fedora
> full-time).
>
>> In General, I like the idea of using the Pandoc approach, as Pandoc
>> provides a very useful framework for all kinds of conversions (and I
>> don't like java...)
>
> Your first argument refers to a side effect (to us), and it is irrelevant
> IMO.

I disagree. pandoc supports conversion to and from org-mode. Making
pandoc a requirement will enable other useful features (e.g., "Import
documents from...", alternative pandoc-based exporters etc. IMO pandoc
is easy on Windows and OSX. It is easy on some Linux distros but not
all. I use Arch LInux, where getting pandoc requires some work, but I
think that is an issue that the Linux distros need to work out. In
short, pandoc is extremely useful for org-mode users, and not only for
citations. I think pandoc is the way to go.

  Java run easily everywhere, easily, and if you use mathml for some
> of your documents, you’re likely already using a jar file with Org.
>
> That being said, it suggest that Pandoc /can/ be packed in a sensible way,
> which is good.
>
> Rasmus
>
> --
> A page of history is worth a volume of logic
>



Re: [O] Some projects

2015-10-27 Thread Ista Zahn
On Oct 27, 2015 11:09 AM, "Rasmus Pank Roulund" <ras...@pank.eu> wrote:
>
> Hi,
>
> Ista Zahn <istaz...@gmail.com> writes:
>
> > I disagree. pandoc supports conversion to and from org-mode.
>
> I fail to see how this is relevant for the discussion at hand.
>
> > Making pandoc a requirement will enable other useful features (e.g.,
> > "Import documents from...", alternative pandoc-based exporters etc.
>
> AFAIK, nobody is working on this.

Not yet :-)
>
> > IMO pandoc is easy on Windows and OSX. It is easy on some Linux distros
> > but not all.
>
> > I use Arch LInux, where getting pandoc requires some work, but I think
> > that is an issue that the Linux distros need to work out.
>
> No it doesn't: pacman -S pandoc.

Good to know, thanks! That must be fairly recent.
>
> The relevant question here is whether we can accept to rely on pandoc for
> CSL support.  Any other feature is irrelevant.

That seems like a narrow way to look at it. Of course I agree that the
topic of discussion is citations, but I don't see why the bigger picture of
what the various options provide should be ignored.

I'll be happy to see improved citation support in org regardless of the
implementation details. But I do think pandoc deserves a serious look, and
I don't think the non-citation related possibilities it opens up are
irrelevant.

>
> At 25MB, a static, precompiled pandoc is probably fine, but for users of
> some OSs, such as Archlinux or even worse some OS where pandoc is not
> generally available as a precompiled package, it’s a really, really big
> dependency.  I may still be the best option, though.
>
> Rasmus
>
> --
> And when I’m finished thinking, I have to die a lot


Re: [O] preparing a R course in org for slides..can i link back to org document?

2015-10-21 Thread Ista Zahn
On Mon, Oct 19, 2015 at 7:29 AM, Eric S Fraga  wrote:
> On Monday, 19 Oct 2015 at 11:05, Xebar Saram wrote:
>> Also if people are using other alternative to org-reveal that can do that i
>> also wouldnt mind to try it out (a long as its as simple as org-revel :-))
>
> You might want to try org-treeslide [1].

I believe the canonical repository is https://github.com/takaxp/org-tree-slide

 List of alternatives can be
> found on Worg [2].
>
> I'm suggesting org-treeslide because it runs within Emacs so you have
> the full power of Emacs at hand.  It should be easy to use babel in the
> presentation although I've never tried.  I'm a beamer person (with
> org-reveal as a useful quick'n'dirty backup).
>
> HTH,
> eric
>
> Footnotes:
> [1]  https://github.com/avdi/org-tree-slide
>
> [2]  http://orgmode.org/worg/org-tutorials/non-beamer-presentations.html
>
> --
> : Eric S Fraga (0xFFFCF67D), Emacs 24.5.1, Org release_8.3beta-1229-ge900eb
>



Re: [O] How to make ~evil-leader~ work for for ~org-src-mode~?

2015-10-20 Thread Ista Zahn
Hi Ben,

It doesn't work because evil-leader/set-key-for-mode sets keys for
major modes and org-src-mode is a minor mode. Unfortunately I don't
know the answer to your implied question "how do I make it work?", but
that is why it doesn't work.

Best,
Ista

On Tue, Oct 20, 2015 at 10:22 AM, Ben  wrote:
> Dear all,
>
> I want to set some evil-leader keys for org-src-mode with the following
> code:
>
> (evil-leader/set-key-for-mode 'org-src-mode
> "k" 'org-edit-src-abort
> "s" 'org-edit-src-save
> "'" 'org-edit-src-exit)
>
> But it doesn't work. Why is that?
>
> Thanks,
> Ben



Re: [O] Modification dates in Worg

2015-09-30 Thread Ista Zahn
Hi Machael,

Well, you're welcome to add modification dates to the worg files. IMO
this won't help much, since some sections of the same file may be up
to date while other sections may be out of date. Something like
git-blame is needed I think in order to get a sense of how up-to-date
a particular section might be.

Best,
Ista

On Tue, Sep 29, 2015 at 4:06 AM, Michael Strey <mst...@strey.biz> wrote:
> On Mo, 2015-09-28 at 17:04, Ista Zahn wrote:
>> I've created a worg mirror on github at
>> https://github.com/izahn/worg-mirror/, so you can see the modification
>> dates via git-blame.
>
> Thank you.  That will help me and maybe some other people who follow this
> thread.  Unfortunately it does not solve the general problem.  Most
> people access Worg via HTML.
>
> --
> Michael Strey
> http://www.strey.biz * https://twitter.com/michaelstrey
>
>



Re: [O] Modification dates in Worg (was: babel header arguments tutorial?)

2015-09-28 Thread Ista Zahn
I've created a worg mirror on github at
https://github.com/izahn/worg-mirror/, so you can see the modification
dates via git-blame. For example,
https://github.com/izahn/worg-mirror/blame/master/org-contrib/babel/languages.org
shows modification of the babel languages page.

Best,
Ista

On Sun, Sep 27, 2015 at 4:22 AM, Michael Strey  wrote:
> On Sa, 2015-09-26 at 23:39, Charles C. Berry wrote:
>
> [...]
>
>> The source is several years old and filed under the FIXME worg
>> directory.
>
> Both things are not visible on the page.  In general there seems to be a
> lot of outdated stuff on Worg.  It would be helpful to have at least the
> date of last modification on the pages.
>
> --
> Michael Strey
> http://www.strey.biz * https://twitter.com/michaelstrey
>
>



Re: [O] babel for sml?

2015-09-23 Thread Ista Zahn
I don't understand. You see ob-sml, but you ask if there is no
support? From the looks of it, ob-sml provides babel language support
for Standard ML, no?

Best,
Ista

On Wed, Sep 23, 2015 at 9:21 AM, Lawrence Bottorff  wrote:
> Is there no babel language support for Standard ML? I see a ob-sml at elpa.
> . .
>
> LB



Re: [O] babel for sml?

2015-09-23 Thread Ista Zahn
I've added a link from
http://orgmode.org/worg/org-contrib/babel/languages.html to the ob-sml
github project.

Best,
Ista

On Wed, Sep 23, 2015 at 11:49 AM, Lawrence Bottorff <borg...@gmail.com> wrote:
> The babel language page does in fact list SML, but no specific ob- package
> is mentioned -- as if support is "built-in." And ob-sml -- at least in my
> elpa listing -- says only
>
>  Requires: sml-mode-6.4
>  Summary: org-babel functions for template evaluation
>
> I was confused by the summary. I did install it and it works, BTW.
>
> On Wed, Sep 23, 2015 at 2:10 PM, Ista Zahn <istaz...@gmail.com> wrote:
>>
>> I don't understand. You see ob-sml, but you ask if there is no
>> support? From the looks of it, ob-sml provides babel language support
>> for Standard ML, no?
>>
>> Best,
>> Ista
>>
>> On Wed, Sep 23, 2015 at 9:21 AM, Lawrence Bottorff <borg...@gmail.com>
>> wrote:
>> > Is there no babel language support for Standard ML? I see a ob-sml at
>> > elpa.
>> > . .
>> >
>> > LB
>
>



Re: [O] [PATCH] ox-latex: Add scrartcl LaTeX class

2015-09-23 Thread Ista Zahn
On Wed, Sep 23, 2015 at 2:16 PM, Eric S Fraga  wrote:
> On Wednesday, 23 Sep 2015 at 18:59, Sebastian Boehm wrote:
>> Hi Nicolas,
>>
>> On 21 September 2015 at 21:46, Nicolas Goaziou  
>> wrote:
>>> But can't users needing a non-default class customize their
>>> own `org-latex-classes? Or is there an entitling reason to offer it out
>>> of the box?
>>
>> you are of course right; users can always customise their own setup.
>> However, when sharing Org files with other people this kind of tight
>> coupling between the Org file and the user's Emacs configuration can
>> become quite problematic.
>
> Yes, this is a real problem.
>
> One solution, but not an ideal one, is to use file local variables to
> define org-latex-classes (and any other variables) as appropriate for
> the document.  It's not ideal because unfortunately most of org's
> variables (as well as many of emacs's own) are "global" and hence affect
> the functionality of org visiting other buffers.  I find myself having
> separate emacs instances for some org files for this reason.

Doesn't "setq-local" solve this problem?

>
> I had thought that maybe using #+bind: would solve this problem but the
> export engine looks for the LaTeX class before binding takes effect.
>
> --
> : Eric S Fraga (0xFFFCF67D), Emacs 25.0.50.2, Org release_8.3.1-270-g256fef
>



Re: [O] user-error: No language for src block: (unnamed) when running `org-icalendar-combine-agenda-files`

2015-08-21 Thread Ista Zahn
On Fri, Aug 21, 2015 at 7:50 AM, Nicolas Goaziou m...@nicolasgoaziou.fr wrote:
 Hello,

 JI, Xiang h...@xiangji.me writes:

 Well actually I think the error shows because of another block below
 the emacs-lisp blocks. In this header I just wrote #+BEGIN_SRC without
 any language name. Is it actually wrong and maybe I should have
 written #+BEGIN_EXAMPLE instead?

 Correct.

 Though I’d still say it probably shouldn’t have failed the export?…

 Babel blocks are executed prior to any export process, no matter what
 you want to include in the output.

Unless you've restored sanity by setting org-export-babel-evaluate to
nil. Personally I think this is not a good default. Source block
evaluation and export are distinct actions, and I don't see why they
should be linked by default.

Best,
Ista



Re: [O] user-error: No language for src block: (unnamed) when running `org-icalendar-combine-agenda-files`

2015-08-21 Thread Ista Zahn
On Fri, Aug 21, 2015 at 10:43 AM, Andreas Leha
andreas.l...@med.uni-goettingen.de wrote:
 Hi,

 Ista Zahn istaz...@gmail.com writes:
 On Fri, Aug 21, 2015 at 10:20 AM, Nicolas Goaziou
 m...@nicolasgoaziou.fr wrote:
 Ista Zahn istaz...@gmail.com writes:

 Unless you've restored sanity by setting org-export-babel-evaluate to
 nil. Personally I think this is not a good default. Source block
 evaluation and export are distinct actions, and I don't see why they
 should be linked by default.

 Wild guess:

 Principle of least surprise: setting it to nil means results from Babel
 code are not refreshed before export, without user realizing about it.
 I think most users would like them to be up-to-date before export. It
 seems sane to me.

 The problem is that if the code blocks are non-trivial it slows down
 the export. Changing one line of documentation and exporting
 re-evaluates all the code blocks, which for me often takes several
 minutes. The defaults work for trivial examples, but not my real-world
 use. Since it's easy to make it work how I want it to via
 org-export-babel-evaluate I don't mean to complain too much. I posted
 mostly to make sure the OP knows about org-export-babel-evaluate, in
 case disabling code block evaluation on export makes sense for them.


 I know that problem...

 Decoupling code block evaluation and export has the problem of
 decoupling code block evaluation and export ;-), though.  If you export
 your document without evaluating first, how can you be sure that the
 resulting document is based on the latest version of the code contained
 in the code blocks?

By calling org-babel-execute-buffer before exporting ;-)

The advantage of doing it this way is that you don't have to do that
if you haven't changed a code block.

  So, from my point of view the default is the safe
 option and, thus, fine.

I agree that it is safer. In my case its safer like a 10 MPH speed
limit. Safe yes, but too slow!



 Regards,
 Andreas





Re: [O] user-error: No language for src block: (unnamed) when running `org-icalendar-combine-agenda-files`

2015-08-21 Thread Ista Zahn
On Fri, Aug 21, 2015 at 10:20 AM, Nicolas Goaziou
m...@nicolasgoaziou.fr wrote:
 Ista Zahn istaz...@gmail.com writes:

 Unless you've restored sanity by setting org-export-babel-evaluate to
 nil. Personally I think this is not a good default. Source block
 evaluation and export are distinct actions, and I don't see why they
 should be linked by default.

 Wild guess:

 Principle of least surprise: setting it to nil means results from Babel
 code are not refreshed before export, without user realizing about it.
 I think most users would like them to be up-to-date before export. It
 seems sane to me.

The problem is that if the code blocks are non-trivial it slows down
the export. Changing one line of documentation and exporting
re-evaluates all the code blocks, which for me often takes several
minutes. The defaults work for trivial examples, but not my real-world
use. Since it's easy to make it work how I want it to via
org-export-babel-evaluate I don't mean to complain too much. I posted
mostly to make sure the OP knows about org-export-babel-evaluate, in
case disabling code block evaluation on export makes sense for them.


 In any case, I don't see the harm here. OP uses invalid syntax and is
 warned about that. I think it's a decent way to proceed.

Yes, I agree about that.

Best,
Ista


 Regards,



Re: [O] user-error: No language for src block: (unnamed) when running `org-icalendar-combine-agenda-files`

2015-08-21 Thread Ista Zahn
On Fri, Aug 21, 2015 at 11:04 AM, Nicolas Goaziou
m...@nicolasgoaziou.fr wrote:
 Ista Zahn istaz...@gmail.com writes:

 I agree that it is safer. In my case its safer like a 10 MPH speed
 limit. Safe yes, but too slow!

 Doesn't Babel :cache property help here?

It does actually, to my surprise. I have not been using :cache because
the documentation says

Note that the :cache header argument will not attempt to cache
results when the :session header argument is used

and since I almost always use :session I didn't expect this to work.
To my surprise it does (at least with R source blocks, I haven't
tested yet with others). Can I now rely on this to work even with
:session?

Best,
Ista


 Regards,



Re: [O] Stable releases

2015-08-11 Thread Ista Zahn
On Tue, Aug 11, 2015 at 1:18 PM, Scott Randby sran...@gmail.com wrote:
 While I've used Org's development version in the past, I stopped doing that
 due to my failure to learn how to use git (no time) and other issues. Now, I
 only use the stable releases. But the latest 8.3 release doesn't seem so
 stable to me, so I'd like some clarification about what the Org maintainers
 mean by a stable release. Perhaps this is too vague, so let me explain a
 bit.

[snip]


 I guess what I want to know, and maybe there is no answer, is how long
 should I wait before upgrading to a stable release?

One strategy is keeping an eye on the mailing list and waiting for bug
reports to die down before upgrading.

Org is by far the most
 important piece of software I use (I hate it when I can't use Org), and bugs
 (which I know can't be avoided) make it hard, even impossible, for me to get
 my real work done. If there is a way for me to minimize encountering bugs, I
 will appreciate a description of that way.

 Scott Randby




Re: [O] latest org from Elpa error: Invalid function: org-babel-header-args-safe-fn

2015-08-08 Thread Ista Zahn
Unfortunately I now can't reproduce the problem, so I can't check if
my suggestion to byte compile ob-R.el works or not. When I did observe
the issue you describe that seemed to fix it, and at least one other
person confirmed that it worked for them as well.

Since it doesn't work for you I suggest removing org-plus-contrib (or
org), starting emacs with 'emacs -Q' and running something like

(require 'package)
(add-to-list 'package-archives
 '(org . http://orgmode.org/elpa/;) t)
(package-initialize)
(package-install 'org-plus-contrib)
;; or (package-install 'org)

Best,
Ista

On Sat, Aug 8, 2015 at 12:07 AM, Xebar Saram zelt...@gmail.com wrote:
 Hi Ista

 i did do a byte compiling but that didnt help. i got this message when i did
 byte compile

 Compiling no file at Sat Aug  8 07:06:30 2015
 Leaving directory `/home/zeltak/.emacs.d/elpa/ace-isearch-20150807.1803'
 Compiling file /home/zeltak/.emacs.d/elpa/org-20150805/ob-R.el at Sat Aug  8
 07:06:55 2015
 Entering directory `/home/zeltak/.emacs.d/elpa/org-20150805/'
 ob-R.el:72:11:Warning: reference to free variable
 `org-babel-safe-header-args'

 In end of data:
 ob-R.el:470:1:Warning: the following functions are not known to be defined:
 org-babel-header-args-safe-fn, org-babel-graphical-output-file

 best

 Z


 On Fri, Aug 7, 2015 at 10:01 PM, Ista Zahn istaz...@gmail.com wrote:

 We discussed this already in another thread[0]. The upshot was run
 M-x byte-compile-file on ob-R.el.

 Best,
 Ista
 [0] https://www.mail-archive.com/emacs-orgmode@gnu.org/msg98762.html

 On Fri, Aug 7, 2015 at 12:47 PM, Xebar Saram zelt...@gmail.com wrote:
 
  Thx for the response Bastien
 
  i removed (require 'org-install) from my init.el file (correct?) and
  restarted emacs but get the same error
 
  Invalid function: org-babel-header-args-safe-fn
 
  i also tried now to downgrade to previous version from 3/8/15 and the
  error
  is gone so its 100% reproducible with the 5/8/15 elpa version
 
  thx again
 
  Z
 
 
 
  On Fri, Aug 7, 2015 at 6:33 PM, Bastien b...@gnu.org wrote:
 
  Hi Xebar,
 
  try removing (require 'org-install), it is not needed since long.
 
  --
   Bastien
 
 





Re: [O] latest org from Elpa error: Invalid function: org-babel-header-args-safe-fn

2015-08-07 Thread Ista Zahn
We discussed this already in another thread[0]. The upshot was run
M-x byte-compile-file on ob-R.el.

Best,
Ista
[0] https://www.mail-archive.com/emacs-orgmode@gnu.org/msg98762.html

On Fri, Aug 7, 2015 at 12:47 PM, Xebar Saram zelt...@gmail.com wrote:

 Thx for the response Bastien

 i removed (require 'org-install) from my init.el file (correct?) and
 restarted emacs but get the same error

 Invalid function: org-babel-header-args-safe-fn

 i also tried now to downgrade to previous version from 3/8/15 and the error
 is gone so its 100% reproducible with the 5/8/15 elpa version

 thx again

 Z



 On Fri, Aug 7, 2015 at 6:33 PM, Bastien b...@gnu.org wrote:

 Hi Xebar,

 try removing (require 'org-install), it is not needed since long.

 --
  Bastien





Re: [O] sudo uninstall org? Can it be done?

2015-08-05 Thread Ista Zahn
I had this problem too, but only on one of my machines. In my case it was
triggered by (require 'ob-R). Running byte-compile-file on ob-R.el
fixed it for me. I don't know what that means, but maybe it will give
someone a clue as to how to track this down.

best,
Ista
On Aug 5, 2015 6:23 PM, Bastien Guerry b...@gnu.org wrote:

 Sharon Kimble boudic...@skimble.plus.com writes:

  ╭
  │org-babel-safe-header-args , and I think it said something about the
  | function being void. |
  ╰

 A similar error is also reported here:
 https://www.reddit.com/r/emacs/comments/3fuq11/org_83_released/

 Anyone knows how to reproduce and fix this?

 --
  Bastien




Re: [O] Fortran missing in List of supported code block languages?

2015-05-14 Thread Ista Zahn
On Thu, May 14, 2015 at 8:37 AM,  alain.coch...@unistra.fr wrote:
 John Kitchin writes:

   Fortran is supported in the sense that you can edit a block in
   Fortran mode. But you cannot execute a Fortran block directly
   afaik. You have to tangle it, compile it and then run the
   executable.

That is not true, you can in fact execute fortran blocks directly.
ob-fortran.el has been part of org since 2011. IMO it is a
documentation bug that it is not listed as a supported language.

Best,
Ista


 Thanks for the precision.  I guess it would not hurt to mention this
 kind of details in the doc, to some extent at least.

   For example like this:
  
   
 http://kitchingroup.cheme.cmu.edu/blog/2014/02/04/Literate-programming-example-with-Fortran-and-org-mode/

 Very helpful.  Seems to me that having such examples (at least the
 simple one) in the doc would be extremely helpful to beginners.




Re: [O] org-babel R ascii results: unable to export table

2015-04-30 Thread Ista Zahn
Hi Marco,

Here is a fairly minimal example to get you started:

 Begin Example 

#+PROPERTY: header-args:R :session *R* :results output drawer :exports both

#+BEGIN_SRC R
  library(ascii)
  options(asciiType=org)
#+END_SRC

#+BEGIN_SRC R
  ascii(mtcars[1:5, 1:5])
#+END_SRC

#+BEGIN_SRC R
  ascii(summary(lm(hp ~ wt, data = mtcars)))
#+END_SRC


### End Example

First execute the code blocks with 'M-x org-babel-execute-buffer' then
export. For more control I would refer to the manual section at
http://orgmode.org/manual/Working-With-Source-Code.html#Working-With-Source-Code

Best,
Ista

On Thu, Apr 30, 2015 at 7:32 AM, Marco Barbàra jab...@gmail.com wrote:
 Dear org-mode community,

 First, I want to apologize for subscribing mainly because I need help.

 I recently started using org-mode as a tool for reproducible research
 (trying to do R-based literate programming).

 What I'm trying to is explained in this example file:
 http://orgmode.org/worg/org-contrib/babel/examples/ascii.org
 which I downloaded trying to understand how to export R output produced
 with the R 'ascii' package.

 Running this example, after adding :exports results to
 ascii-example3 block, _on the first attempt_, the output was exported
 as an odt table (i was happy, this is my desired outcome). But
 afterwards, any subsequent attempts to export the same block resulted in
 a verbatim block, which is the same problem I was trying to solve.

 I tried to export as a latex buffer too, and even there i got a verbatim
 environment.

 I don't think it is bug, it is probably that I still don't understand
 org-babel well.

 Sorry not to provide any other sample code, but I wouldn't know where
 to begin.

 Any advice would be very appreciated.

 Thank you very much

 Marco Barbara






Re: [O] Latex export or Latex tangle? Best practice?

2015-04-27 Thread Ista Zahn
I would use LaTeX code blocks when I need to write something in LaTeX
that isn't easy to write in org mode, not to distinguish what is a
note and what is part of the draft. For that I recommend comments,
e.g.,


### Start example ###

* Section 1
** COMMENT Some rough draft notes to myself
 yadda yadda more badda
** Some stuff that should be exported
This is the actual important stuff that should be exported
*** More stuff that should be exported
yadda yada
*** COMMENT More notes and stuff don't export
*** Export this one too
bla bla

### End example ###

When you export the commented sections will be excluded.

Best,
Ista
On Mon, Apr 27, 2015 at 2:12 PM, Lawrence Bottorff borg...@gmail.com wrote:
 In a previous post I was getting at the issue of whether I should just do
 regular export or use latex code blocks for what I wanted in a final
 document. What I want is the ability to create a big, rambling, annotated
 org file -- with keeper stuff inside the latex babel blocks -- then tangle
 the .org file, thereby leaving all the annotations and lead-up notes behind.
 I'm sure I'm not alone in wanting notes to evolve into a finished
 product and orgmode would seem to offer a good path. So, I don't want to
 have to hand-edit out my so-called annotations. Is keeping the good stuff in
 latex babel blocks a best practice?

 LB



Re: [O] Help with alternative ipython session workflow

2015-04-11 Thread Ista Zahn
The settings described at
http://lists.gnu.org/archive/html/emacs-orgmode/2014-05/msg00793.html
seem to work for me. (I replaced --pylab=osx with --pylab since
I'm on Linux.)

Best
Ista

On Sat, Apr 11, 2015 at 7:09 PM, Giacomo M jackja...@gmail.com wrote:
 I have never been able to make org sessions getting along properly with
 ipython, so at the moment I'm using a sort of handmade hybrid between org
 and an ipython notebook, doing the following:
 1. Enter the first source block in a .org file
 2. Start an ipython instance with C-c C-c
 3. Keep the org/src buffer and *Python* buffer side by side
 4. Copy paragraph of code around cursor (keeping cursor in position) (I
 usually split sections of code I want to run individually with spaces)
 5. Select *Python* buffer
 6. Go to last position
 7. Type %paste
 8. Go back to other buffer (src/org)

 I probably sound like a caveman doing this over and over, but this is the
 most stable setup I could find. Plus I keep experimenting w/ code, and this
 gives me a very interactive environment. Macros helped me to automatize
 steps 4-8, but still it's not very flexible, e.g. I need the side-by-side
 buffers, with ipython already running.

 I was wondering whether anybody has any suggestions to improve this (and
 make me save some minutes of life every day), or any good reference to make
 ipython work smoothly with org src blocks

 Thanks,

 Giacomo




Re: [O] Problem with org-mode and minted

2015-04-08 Thread Ista Zahn
I think you just need to customize org-latex-minted-langs so that it
maps C to c, e.g.,

(add-to-list 'org-latex-minted-langs '(C c))

Best,
Ista

On Wed, Apr 8, 2015 at 8:11 AM, azubi az...@acm.org wrote:
 Hi all

 I've recently discovered babel (of org-mode) and I try to learn it.
 I've discovered a little problem that I cannot solve.

 Consider the following (almost) minimal example:

 
 * First example with language c

 #+BEGIN_SRC c :EXPORT results
 printf (First example \n);
 #+END_SRC

 * Second example with language C

 #+BEGIN_SRC C :EXPORT results
 printf (second example \n);
 #+END_SRC

 #+RESULTS:
 : second example
 

 The first example cannot be evaluated by a C-c C-c (?? due to the small c
 ??). The second example is evaluated without any problem.

 I've configured org-mode to use minted to colorize the source code when it
 is exported to latex.

 For the file above, the function org-export-latex-to-pdf gives the
 expected result for the first example but nothing for the second one (?? due
 to the big C ??). Minted understand c as a language but not C. The
 latex code produced by the command is (without the very long standard
 preamble):

 
 \begin{document}

 \maketitle
 \tableofcontents

 \section{First example with language c}
 \label{sec-1}

 \begin{minted}[]{c}
 printf (First example \n);
 \end{minted}
 \section{Second example with language C}
 \label{sec-2}

 \begin{minted}[]{C}
 printf (second example \n);
 \end{minted}
 % Emacs 24.3.1 (Org mode 8.2.4)
 \end{document}
 ===

 What have I done wrong ?

 Thank you in advance for your help.





Re: [O] render - as rarr on html export?

2015-03-23 Thread Ista Zahn
Not an answer to your question, but alternative: the company-math[1]
package makes it really easy to insert unicode.

Best,
Ista

[1] https://github.com/vspinu/company-math

On Mon, Mar 23, 2015 at 12:23 PM, Matt Price mopto...@gmail.com wrote:
 I feel like I've seen the answer to this somewhere but I can't find it -- is
 it possible for me to get - and = to render as rightarrows (→, ⇒)?

 \rightarrow will work, but doesn't give me the visual cue I want when
 working in org. And entering unicode directly in org is pretty distracting
 for me, as the gnome unicode shortcuts seem to turn themselves on and off
 whenever I upgrade.

 thanks!
 m




Re: [O] about htmlize.el

2015-03-12 Thread Ista Zahn
It looks like that was created just by calling 'htmlize-buffer' three
times with different visibility cycling. Does that work for you?

Best,
Ista

On Thu, Mar 12, 2015 at 12:25 PM, XIE Yuheng xyh...@gmail.com wrote:


 what I wish is org mode like web page
 see ::
   
 http://the-little-language-designer.github.io/org-html/cicada-nymph/overview.html

 On 03/12/2015 04:20 PM, Eric S Fraga wrote:
 On Wednesday, 11 Mar 2015 at 02:01, XIE Yuheng wrote:
 Hi friends ^-^,
 it is me again.
 can you guys hack htmlize.el for me,
 to make it an org-html with better support to view exported
 org-mode file online ?
 (only viewing, no editing)

 See info: (org) HTML export




Re: [O] how to get images support in Emacs on Windows?

2015-02-19 Thread Ista Zahn
You could use http://vgoulet.act.ulaval.ca/en/emacs/windows/ which comes
bundled with image support (and other stuff that you may or may not want).
On Feb 19, 2015 6:20 PM, Herbert Sitz hes...@gmail.com wrote:

 I'm trying to use inline images on Windows and (I think?) I've gotten to
 the
 point where I understand that this is not available with the standard GNU
 Emacs installation on Windows.  My understanding is that I need an
 image.dll that I can put in the bin directory.  I think that comes as
 part
 of EmacsW32 install, but that install seems to be packaged as a single
 executable, not sure how to get image.dll without running a full install of
 EmacsW32, which I don't think I want.

 So, am I correct in understanding that all I need is that 'image.dll' to
 get
 inline image support on Windows (I'm running v24.4 of Emacs).  If not, what
 more do I need to do?  And how can I get (or make) a copy of that .dll?

 Thanks,

 Herbert





Re: [O] [bug?] Link to be exported only in HTML

2015-02-04 Thread Ista Zahn
On Wed, Feb 4, 2015 at 10:15 AM, Sebastien Vauban
sva-n...@mygooglest.com wrote:

 #+TITLE: ECM Links for HTML only

 * Test

 If I want to include a link (GPL logo, here) to the HTML export, I should put 
 it
 in a block, right?

 #+begin_html
 [[http://opensource.org/licenses/GPL-3.0][http://img.shields.io/:license-gpl-blue.svg]]
 #+end_html

 Well, that does not work: the link is not rendered as a link; it's copied
 verbatim.


You need to write the link in html, not org:

#+begin_html
  a href=http://opensource.org/licenses/GPL-3.0;img
src=http://img.shields.io/:license-gpl-blue.svg;
alt=:license-gpl-blue.svg //a
#+end_html




 OTOH, the link on its own is correctly exported to HTML:

 [[http://opensource.org/licenses/GPL-3.0][http://img.shields.io/:license-gpl-blue.svg]]

 ... but it fails to be exported to LaTeX (causing a TeX capacity exceeded
 error), reason why I must not have the link when exporting to LaTeX.

I can't replicate that, for me it exports to

\href{http://opensource.org/licenses/GPL-3.0}{\url{http://img.shields.io/:license-gpl-blue.svg}}

and compiles just fine.


 Is this a bug?  Is there an alternative?

 Best regards,
   Seb

 --
 Sebastien Vauban





Re: [O] Conducting end user surveys and analyze data (was: Org-mode to feed a database)

2014-12-31 Thread Ista Zahn
On Dec 31, 2014 5:38 AM, Karl Voit devn...@karl-voit.at wrote:

 * Vikas Rawal vikasli...@agrarianresearch.org wrote:
 
  But there would be many interesting things one could do in an
  emacs/org-based solution. My  biggest worry is that it would
  require continuous training of people coming in to enter data.

 I think you can differ between the data entry platform and the
 platform where you analyze the data.

 You do have to train people using Emacs/Org-mode as well.

 When I was a researcher, I used SurveyMonkey for my surveys. It's
 open source and web-based. You get the data in CSV files AFAIR.

No, I don't believe surveymonkey is open source. Perhaps you are thinking
of limesurvey?


 I also tested Google Drive (spreadsheet) forms which were very easy
 to set up. However, the person filling out the survey needs a Google
 Drive account.

No, that is not true. You don't need a google account to fill in a Google
drive form.

The results were exported in various formats AFAIR.

 So, choosing a well known interface type (web-based forms) for
 end-users and choosing a separate power-tool for analysis (R,
 Org-mode, ...) is not a bad idea IMHO.

I agree that doing it in emacs doesn't make sense from a productivity
standpoint. The only reason to do something like this in emacs is because
it would be cool and increase your geek cred.

Best,
Ista


 --
 mail|git|SVN|photos|postings|SMS|phonecalls|RSS|CSV|XML to Org-mode:
 get Memacs from https://github.com/novoid/Memacs 

 https://github.com/novoid/extract_pdf_annotations_to_orgmode + more on
github




Re: [O] Conducting end user surveys and analyze data (was: Org-mode to feed a database)

2014-12-31 Thread Ista Zahn
On Wed, Dec 31, 2014 at 8:40 AM, Karl Voit devn...@karl-voit.at wrote:
 * Ista Zahn istaz...@gmail.com wrote:

 On Dec 31, 2014 5:38 AM, Karl Voit devn...@karl-voit.at wrote:

 When I was a researcher, I used SurveyMonkey for my surveys. It's
 open source and web-based. You get the data in CSV files AFAIR.

 No, I don't believe surveymonkey is open source. Perhaps you are thinking
 of limesurvey?

 Yes, absolutely true. I mixed them up - sorry for that. It was
 https://www.limesurvey.org with a local installation.

 I also tested Google Drive (spreadsheet) forms which were very easy
 to set up. However, the person filling out the survey needs a Google
 Drive account.

 No, that is not true. You don't need a google account to fill in a Google
 drive form.

 Really? I was not able to do so. Probably I have to re-try it again.

I've never had a problem with this--for example http://j.mp/1zvWP1G
should work without signing into google.


 In case this is true, then I'd got for Google Drive forms because of
 the very easy handling!

Yes, google is very convenient.


 The results were exported in various formats AFAIR.

 ... and I guess everything we need here is CSV :-)


 Thanks for your correction!

 --
 mail|git|SVN|photos|postings|SMS|phonecalls|RSS|CSV|XML to Org-mode:
 get Memacs from https://github.com/novoid/Memacs 

 https://github.com/novoid/extract_pdf_annotations_to_orgmode + more on github





Re: [O] Conditionally export certain sections based on predefined types

2014-12-04 Thread Ista Zahn
On Thu, Dec 4, 2014 at 1:59 PM, Pete Ley peteley11...@gmail.com wrote:
 Not a great title, but I'm not sure how to explain what I want
 succinctly.

 I'm trying to write a resume, and I'd like to be able to export
 different versions of it for different things. For instance, I don't
 necessarily want to include my hourly job experience when applying for a
 programming job, and I'd like to exclude my programming and other
 technical experience for certain job applications.

 I'm thinking something like this

 * Work experience
 ** Some hourly job
:PROPERTIES:
:export-exclude: programming
:END:

 * Programming languages
   :PROPERTIES:
   :export-exclude: hourly
   :END:

 Obviously it doesn't have to be properties, but I thought that was the
 most clear way to explain what I'm looking for. So I'd like to be able
 to export a specific type of resume, like a programming resume which
 excludes hourly jobs or an hourly resume which excludes programming
 language proficiency.

 Is there a way to do this already? Is there a canonical way to create
 this functionality? I'd rather not start hacking without a good idea of
 how more knowledgeable users might tackle this.

There might be better ways, but I do
--8---cut here---start-8-

# uncomment one of these before export.
# for hourly version:
# #+EXCLUDE_TAGS: programming
# for programming version
# #+EXCLUDE_TAGS: hourly

* Work experience:hourly:
** Some hourly job

* Programming languages :programming:

--8---cut here---end-8-

Best,
Ista




Re: [O] Executing org shell blocks on remote machine over ssh

2014-11-18 Thread Ista Zahn
On Tue, Nov 18, 2014 at 10:43 AM, Brett Viren b...@bnl.gov wrote:
 David Bjergaard davi...@duke.edu writes:

 I use org mode as a lab notebook.  I write org-src blocks to keep track
 of tasks I do at the command line, and then I copy paste them into the
 terminal.  I would really like to hit C-c C-c on the source block and
 have it executed on the remote machine.  I know that you can specify
 the remote machine according to [1], however the software I use requires
 a fairly complicated setup to get going.

 Is it just complicated, or is it also prohibitively long-running?

 If just the former, you could maybe bundle the setup into some shell
 script and source it in each of your sh source blocks.  Eg:

 #+BEGIN_SRC sh :results output :dir /ssh:lycastus:/home/bviren
   /bin/pwd
   echo $HOSTNAME
   ls -l foo.sh
   echo ---
   cat foo.sh
   echo ---
   source ./foo.sh
   echo $FOO
 #+END_SRC

 #+RESULTS:
 : /home/bviren
 : lycastus
 : -rw-rw-r-- 1 bviren bviren 16 Nov 18 10:27 foo.sh
 : ---
 : export FOO=bar
 :
 : ---
 : bar



 If the setup is purely environmental, and it takes a long time to
 perform, maybe you could do the set up once and then cache the resulting
 environment using the output of env.

I guess I'm missing something (like why the OP want's to run a shell
in a separate window), but why not just

#+BEGIN_SRC sh :results output :dir /ssh:lycastus:/home/bviren :session *shell*
  /bin/pwd
  echo $HOSTNAME
  ls -l foo.sh
  echo ---
  cat foo.sh
  echo ---
  source ./foo.sh
  echo $FOO
#+END_SRC

?

Best,
Ista


 -Brett.



Re: [O] Executing org shell blocks on remote machine over ssh

2014-11-18 Thread Ista Zahn
On Tue, Nov 18, 2014 at 1:23 PM, David Bjergaard davi...@duke.edu wrote:
 Ista Zahn istaz...@gmail.com writes:

 On Tue, Nov 18, 2014 at 10:43 AM, Brett Viren b...@bnl.gov wrote:
 David Bjergaard davi...@duke.edu writes:

 I use org mode as a lab notebook.  I write org-src blocks to keep track
 of tasks I do at the command line, and then I copy paste them into the
 terminal.  I would really like to hit C-c C-c on the source block and
 have it executed on the remote machine.  I know that you can specify
 the remote machine according to [1], however the software I use requires
 a fairly complicated setup to get going.

 Is it just complicated, or is it also prohibitively long-running?

 If just the former, you could maybe bundle the setup into some shell
 script and source it in each of your sh source blocks.  Eg:

 #+BEGIN_SRC sh :results output :dir /ssh:lycastus:/home/bviren
   /bin/pwd
   echo $HOSTNAME
   ls -l foo.sh
   echo ---
   cat foo.sh
   echo ---
   source ./foo.sh
   echo $FOO
 #+END_SRC

 #+RESULTS:
 : /home/bviren
 : lycastus
 : -rw-rw-r-- 1 bviren bviren 16 Nov 18 10:27 foo.sh
 : ---
 : export FOO=bar
 :
 : ---
 : bar



 If the setup is purely environmental, and it takes a long time to
 perform, maybe you could do the set up once and then cache the resulting
 environment using the output of env.

 I guess I'm missing something (like why the OP want's to run a shell
 in a separate window), but why not just

 #+BEGIN_SRC sh :results output :dir /ssh:lycastus:/home/bviren :session 
 *shell*
   /bin/pwd
   echo $HOSTNAME
   ls -l foo.sh
   echo ---
   cat foo.sh
   echo ---
   source ./foo.sh
   echo $FOO
 #+END_SRC

 ?

 Best,
 Ista


 -Brett.
 Hi Ista, Brett,

 Thanks for the hints, I'll try these.
 Some clarification:
 If the setup is purely environmental, and it takes a long time to
 perform, maybe you could do the set up once and then cache the resulting
 environment using the output of env.
 Unfortunately it takes a long time to set up, and its complicated (I
 have to initialize different versions of the software depending on
 which project I'm working on.) It can take up to 10 seconds to restore a
 saved environment, and it takes some setting up bootstrap the
 restoration command.
 I guess I'm missing something (like why the OP want's to run a shell
 in a separate window), but why not just
 I want the separate window because once the environment is set up, I
 also jump around a lot.

Emacs is great for jumping around a lot, another reason to run the
shell inside emacs instead of in a separate window.

I record the pieces of shell script that are
 important for reproducing results in the notebook.  The snippets are
 then recycled across many sessions, and different pieces are used at
 different times (some are even used with different pieces of software).

 What I would like is to log into the remote machine, set up the
 software, and then have a way to tell emacs to send the org-src block to
 the set up environment so that I can build up the parts I need at that
 moment.

 I know this is working against the grain of the literate programming
 paradigm where the document and the source code are coupled, and
 tangling the document produces a program that can be executed.  I'm just
 wondering if its possible.

It really does sound to me like you're just looking for the :session argument.

Best,
Ista

 If not that's fine.  Really I'm just trying
 to save myself a copy-paste (and the associated issues with it getting
 recorded in my .bash_history).

 Cheers,

 Dave



Re: [O] Inline code :results replace not working

2014-11-10 Thread Ista Zahn
On Mon, Nov 10, 2014 at 11:23 AM, Charles C. Berry ccbe...@ucsd.edu wrote:
 On Mon, 10 Nov 2014, Andreas Leha wrote:

[snip]



 Nonetheless, from a literate programming perspective, I think that
 replaceable (and raw) inline results are definitely desirable.
 Regardless of the state of their implementation in orgmode right now.


 +1.

+1 from me as well. For exactly the reason Andreas illustrated I've
given up on using inline results for the past year or so. Would be
great to see this feature become usable by implementing a system for
replacing them.

-Ista


 I find myself writing an inline src block, then typing `C-c C-c C-x u' to
 view and then remove the result, then revise, and repeat. I'd be happy to
 just leave it in the document.


 FWIW, I'm not -- yet? -- convinced we should see the results of inline
 code blocks inlined in the paragraph (and I'm not sure either it does
 not cause interpretation problems); but, for sure, I'd love to be able
 to preview the value interactively, at least.

 So, I do not doubt, that you and Nicolas are right with that
 replaceable inline results are not implemented and are -- from
 orgmodes perspective -- expected to be evaluated only during export.

 My message was meant more as a feature request saying that I consider
 replaceable inline results useful and would like to see them supported
 by org.


 Could you better explain your statement: Limiting the use of inline
 code to eval-on-export-only renders all the org-babel-execute-subtree
 and related functionality useless?

 I'm not sure to fully understand your use-case.  That'd certainly be
 worth explaining why you think it must be changed in the first instance
 if you'd like Eric or Nicolas (or someone else) to change that.


 Consider this simple toy example.  If you press 'C-c C-v s' in the
 subtree, the document is 'broken' for export.  If you press 'C-c C-v s'
 twice or more the document is 'broken' even for display.


 [deleted ECM]

 It seems like implementing removable inline results cleanly is a nettlesome
 issue.

 But with the recent implementation of `org-babel-inline-result-wrap' it
 would be trivial to wrap results with something like @@babel:%s@@,
 which can be found and removed more reliably than =%s=.

 On export, either the :back-end property of such export-snippets could be
 revised to the backend in use by a parse-tree filter or the code in each
 org-backend-export-snippet could be revised to accept such snippets.

 There is still the matter of adding code to find and remove those snippets
 where Nicolas pointed in ob-core.al.

 But it seems do-able.

 HTH,

 Chuck




Re: [O] Inline code :results replace not working

2014-11-10 Thread Ista Zahn
On Mon, Nov 10, 2014 at 3:04 PM, Grant Rettke g...@wisdomandwonder.com wrote:
 On Mon, Nov 10, 2014 at 11:03 AM, Ista Zahn istaz...@gmail.com wrote:
 On Mon, Nov 10, 2014 at 11:23 AM, Charles C. Berry ccbe...@ucsd.edu wrote:
 On Mon, 10 Nov 2014, Andreas Leha wrote:

 [snip]



 Nonetheless, from a literate programming perspective, I think that
 replaceable (and raw) inline results are definitely desirable.
 Regardless of the state of their implementation in orgmode right now.


 +1.

 +1 from me as well. For exactly the reason Andreas illustrated I've
 given up on using inline results for the past year or so. Would be
 great to see this feature become usable by implementing a system for
 replacing them.

 My approach here has been to use hidden source blocks that aren't
 exported but make it
 really easy to see the result during development. These settings
 should work on any configuration,
 so I didn't include mine here.

 ✂✂
 #+BEGIN_SRC R
 a = 10
 b = 23
 c = a + b
 #+END_SRC

 #+BEGIN_SRC R :results output silent :exports none
 c
 #+END_SRC

 The user calculated src_R{c}.
 ✂✂

 When you use these functions
 http://orgmode.org/manual/Key-bindings-and-useful-functions.html#Key-bindings-and-useful-functions
 the addition of these hidden blocks hav almost zero cost and give me
 what I want.

The problem I have is not that I miss being able to see results of the
inline block in the org-mode buffer. The problem is that I don't want
blocks to be evaluated on export (too time consuming in many cases).
So I turn that off, and either evaluate the blocks one at a time (I'm
aware of the dangers of this, not my point here) or call
org-babel-execute-buffer. Everytime I do that I get duplicate output
from inline code. As far as I can see inline code +
org-babel-execute-buffer is incompatible, which is why I gave up on
the former.

Best,
Ista



Re: [O] Trouble using julia with org-babel

2014-10-29 Thread Ista Zahn
On Wed, Oct 29, 2014 at 12:35 PM, Doyley, Marvin M.
mdoy...@ur.rochester.edu wrote:

 Hi there,

 I have been play  with julia the last couple of weeks and have been having
 some issues when I try to use it in org-babel

 More specifically, It get the following error

 ERROR: unsupported or misplaced expression using
  in _start at ./client.jl:394
  in _start at /julia/usr/lib/julia/sys.dylib


 When I execute the following code block

 #+begin_src julia
 using Winston
 #+end_src

I get the same thing, though both of these variations work for me:

#+begin_src julia
using Winston
1 + 1
#+end_src

#+RESULTS:
: 2

#+begin_src julia :results output
  using Winston
#+end_src

Hope this helps,
Ista

 #+RESULTS:

 I should mention, that everything works perfectly in eshell or when I
 execute simple code blocks like


 #+begin_src julia
 linspace(0,10,5)
 #+end_src

 #+RESULTS:
 |   0 |
 | 2.5 |
 |   5 |
 | 7.5 |
 |  10 |


 Does Any body know how to resolve this issue.

 Cheers,
 M



Re: [O] Trouble using julia with org-babel

2014-10-29 Thread Ista Zahn
On Wed, Oct 29, 2014 at 10:09 PM, Doyley, Marvin M.
mdoy...@ur.rochester.edu wrote:
 I am using release-0.3.0 what version are you using. I am also using 
 ob-julia.el

I'm using julia version 0.3.1 with GNU Emacs 24.4.1 and Org-mode
version 8.2.10. I'm using the ob-julia.el distributed with
org-plus-contrib.

Best,
Ista

 Cheers,
 M

 Sent from my iPad

 On Oct 29, 2014, at 9:43 PM, Ista Zahn istaz...@gmail.com wrote:

 On Wed, Oct 29, 2014 at 12:35 PM, Doyley, Marvin M.
 mdoy...@ur.rochester.edu wrote:

 Hi there,

 I have been play  with julia the last couple of weeks and have been having
 some issues when I try to use it in org-babel

 More specifically, It get the following error

 ERROR: unsupported or misplaced expression using
 in _start at ./client.jl:394
 in _start at /julia/usr/lib/julia/sys.dylib


 When I execute the following code block

 #+begin_src julia
 using Winston
 #+end_src

 I get the same thing, though both of these variations work for me:

 #+begin_src julia
 using Winston
 1 + 1
 #+end_src

 #+RESULTS:
 : 2

 #+begin_src julia :results output
  using Winston
 #+end_src

 Hope this helps,
 Ista

 #+RESULTS:

 I should mention, that everything works perfectly in eshell or when I
 execute simple code blocks like


 #+begin_src julia
 linspace(0,10,5)
 #+end_src

 #+RESULTS:
 |   0 |
 | 2.5 |
 |   5 |
 | 7.5 |
 |  10 |


 Does Any body know how to resolve this issue.

 Cheers,
 M



Re: [O] [PATCH] WAS Re: Bug: problem w/ R code blocks [8.3beta (release_8.3beta-362-ga92789 at /usr/local/share/emacs/site-lisp/org/)]

2014-10-07 Thread Ista Zahn
On Oct 7, 2014 3:41 PM, Henrik Singmann 
henrik.singm...@psychologie.uni-freiburg.de wrote:

 Dear all,

 Sorry to resurrect this thread but I still have the issue discussed here.
I get Error: could not find function .ess.eval when inside an R code
block with :session *R* but not without :session *R*.

 More specifically, in the following .org file the first code block works
but not the second one:

 --8---cut here---start-8---
 #+begin_src R
   date()
 #+end_src

 #+RESULTS:
 : Tue Oct 07 19:31:21 2014

 #+begin_src R :session *R*
   date()
 #+end_src

 #+RESULTS:

 --8---cut here---end---8---

 Note that I use the latest Emacs on Windows (24.3.1,
i386-mingw-nt6.1.7601) with the latest Org-mode (version 8.3beta,
release_8.3beta-427-g942eb6) and the current development version of ESS
(the same happens for ESS 14.09). Interestingly and as reported, it does
not happen when downgrading to ESS 13.09 (but as this was handled as an
org-mode problem so far I decided to keep it on this list).

 Furthermore, my .emacs file currently only consists of the following:

 --8---cut here---start-8---

 (require 'org)
 (require 'ess-site)

 (custom-set-variables
  ;; custom-set-variables was added by Custom.
  ;; If you edit it by hand, you could mess it up, so be careful.
  ;; Your init file should contain only one such instance.
  ;; If there is more than one, they won't work right.
  '(inhibit-startup-screen t)
  )
   (custom-set-faces
  ;; custom-set-faces was added by Custom.
  ;; If you edit it by hand, you could mess it up, so be careful.
  ;; Your init file should contain only one such instance.
  ;; If there is more than one, they won't work right.
  )
(org-babel-do-load-languages
   'org-babel-load-languages
   '((emacs-lisp . nil)
 (R . t)))

 (setq org-babel-R-command C:/Progra~1/R/R-3.1.1/bin/x64/rterm.exe
--slave --no-save)

 --8---cut here---end---8---

 The windows is Windows 7, 64 bit.

 Can anybody reproduce or solve?

Yes, I can reproduce with emacs 24.3.1, org 8..2.3, and ess 14.09 on
Archlinux, but only if I don't start the R session first. If I do 'M-x
R' to manually start an R process it works fine, but if there is no R
process already running I get 'Error: could not find function
.ess.eval'

Best,
Ista

 Henrik


 Am 19.09.2014 um 00:45 schrieb Charles C. Berry:

 On Thu, 18 Sep 2014, Charles C. Berry wrote:

 On Thu, 18 Sep 2014, Cook, Malcolm wrote:

 Hi,

 Hmm, I spoke too soon the problem is only partially fixed by this
patch...


 Trying to work with in org-mode with R code blocks attached to
persistent sessions (i.e. adding ':session myRsession' to the code block
header ) makes things start to break again, at least in my hands.


 Really? I have been working for hours using the :session header with no
problems.

 What exactly breaks? Do you have an example?

 FWIW, this works when I move my cursor into the source block and C-c
C-c.

 --8---cut here---start-8---
 #+BEGIN_SRC R :session myRsession
 abc - 1
 abc+1
 #+END_SRC
 --8---cut here---end---8---

 Producing

 --8---cut here---start-8---
 #+RESULTS:
 : 2
 --8---cut here---end---8---

 which is what I expect.

 I use Org-mode version 8.3beta (release_8.3beta-366-gb2fca7.

 (updated a few hours back)



 Forget to mention:

 ess-version: 14.09 [git: 9c248f1a026b6990d0cd0cd326d82854d5cafb26]


 Chuck



 --
 Dr. Henrik Singmann
 Albert-Ludwigs-Universität Freiburg, Germany
 http://www.psychologie.uni-freiburg.de/Members/singmann




Re: [O] Tangling and Exporting an Unsupported Language.

2014-10-01 Thread Ista Zahn
On Wed, Oct 1, 2014 at 3:10 AM, Malcolm Purvis malc...@purvis.id.au wrote:
 Ista == Ista Zahn istaz...@gmail.com writes:

 Ista Exporting and tangling don't require any language support.

 Ista #+begin_src foobarbas :tangle foo.bar
 Ista +end_src

 Ista is perfectly fine and will export and tangle just fine. Or did I
 Ista misunderstand your question?

 Thanks, I wasn't aware that you could put an arbitrary string as the
 language.

 I also found that I had org-latex-listings set to t, which was making
 LaTeX error because it didn't know about the languages I was trying.

 I've now switched the using the minted LaTeX package, which supports
 'text' as a language, and have started using that.

Yes, I find minted much nicer that listings, the only drawback being
that it has external dependencies. I guess you've already discovered
that you can do

(add-to-list 'org-export-latex-minted-langs '(foo bar))

where foo is the name of the language and bar is the pygments lexer
that should be used to typeset it.

Best,
Ista


 Thanks for your help.

 Malcolm

 --
Malcolm Purvis malc...@purvis.id.au




Re: [O] Tangling and Exporting an Unsupported Language.

2014-09-29 Thread Ista Zahn
Exporting and tangling don't require any language support.

#+begin_src foobarbas :tangle foo.bar
#+end_src

is perfectly fine and will export and tangle just fine. Or did I
misunderstand your question?

Best,
Ista

On Mon, Sep 29, 2014 at 2:53 AM, Malcolm Purvis malc...@purvis.id.au wrote:
 All,

 I'm writing an org document which contains code examples of a language
 not supported by Babel (a local domain specific language).  The language
 doesn't even have a supporting Emacs mode.

 I'm wondering what the best portable approach is to managing the code
 blocks.  I'm particularly interested in exporting the document to LaTeX
 and tangling the code.  I may need to share the document with others, so
 I'd prefer not to require a supporting elisp file if I can help it.

 Currently I'm using the org language, since it seems to be the most generic:

 #+begin_src org :tangle foo.bar
 #+end_src

 Is there a case for 'begin_src text' to handle arbitrary content?

 Malcolm

 --
Malcolm Purvis malc...@purvis.id.au




Re: [O] You don't like the HTML export; well, that could change!

2014-09-15 Thread Ista Zahn
Hi Fabrice,

Very very nice, I enjoy it a lot. If you are accepting feature
requests, the only thing I really miss is Next section link at the
bottom.

Best,
Ista

On Mon, Sep 15, 2014 at 2:58 PM, Fabrice Niessen fni-n...@pirilampo.org wrote:
 Hello,

 I'm announcing the release of Bigblow, a CSS + JS theme for the Org HTML
 exports.

 To use it in your own files, adding these lines should make it:

 --8---cut here---start-8---
 #+HTML_HEAD: link rel=stylesheet type=text/css 
 href=http://www.pirilampo.org/styles/bigblow/css/htmlize.css/
 #+HTML_HEAD: link rel=stylesheet type=text/css 
 href=http://www.pirilampo.org/styles/bigblow/css/bigblow.css/
 #+HTML_HEAD: link rel=stylesheet type=text/css 
 href=http://www.pirilampo.org/styles/bigblow/css/hideshow.css/
 #+HTML_HEAD: script type=text/javascript 
 src=http://www.pirilampo.org/styles/bigblow/js/jquery-1.11.0.min.js;/script
 #+HTML_HEAD: script type=text/javascript 
 src=http://www.pirilampo.org/styles/bigblow/js/jquery-ui-1.10.2.min.js;/script
 #+HTML_HEAD: script type=text/javascript 
 src=http://www.pirilampo.org/styles/bigblow/js/jquery.localscroll-min.js;/script
 #+HTML_HEAD: script type=text/javascript 
 src=http://www.pirilampo.org/styles/bigblow/js/jquery.scrollTo-1.4.3.1-min.js;/script
 #+HTML_HEAD: script type=text/javascript 
 src=http://www.pirilampo.org/styles/bigblow/js/jquery.zclip.min.js;/script
 #+HTML_HEAD: script type=text/javascript 
 src=http://www.pirilampo.org/styles/bigblow/js/bigblow.js;/script
 #+HTML_HEAD: script type=text/javascript 
 src=http://www.pirilampo.org/styles/bigblow/js/hideshow.js;/script
 --8---cut here---end---8---

 If you clone my repo from GitHub [1], it can become as easy as adding
 just one line:

 --8---cut here---start-8---
 #+SETUPFILE: path/to/Git/repo/setup/bigblow-pirilampo.setup
 --8---cut here---end---8---

 (PS- It would be very nice if we could add http references here!  Then,
 there would even be no need to copy the files locally...)

 Test it on your files, or look at the video I posted on YouTube to see
 what it looks like:

   https://www.youtube.com/watch?v=DnSGSiXYuOk

 Best regards,
 Fabrice

 PPS- I will still make some changes in a couple of days, like renaming
  the files so that they have a version number, but that I'll warn
  you when I'll get this done.

 [1] https://github.com/fniessen/org-html-themes

 --
 Fabrice Niessen
 Leuven, Belgium
 http://www.pirilampo.org/





Re: [O] specifying the coding language resulting from a a :results code source block

2014-09-11 Thread Ista Zahn
Can't you just do

#+begin_src foo :wrap src bar
   hello world
#+end_src

?

Best,
Ista


On Thu, Sep 11, 2014 at 5:11 AM, Dror Atariah dror...@gmail.com wrote:
 Is there some change in the status of this issue? Can one now specify the
 language of the result?

 Cheers,
 Dror

 --
 Mahalo Tom,

 It looks like that's what I'll be doing for the ruby block.  That said, it
 would be great if the :results code argument would allow a language
 specification.

 Greg


 On Jun 27, 2012, at 10:22 AM, Thomas S. Dye wrote:

 Greg Tucker-Kellogg address@hidden writes:

 I have a Ruby block that creates some dot code.  I'd like to be able
 to have the #+RESULTS block enclosed
 in a src block that starts #+BEGIN_SRC dot.  Using :results value
 code generates the enclosing SRC block,
 but using the same language (Ruby) used to generate the code.  Is
 there a way to specify the coding language
 of a generated #+RESULTS  src block?

 Thanks,

 Greg

 Aloha Greg,

 This works for me with an emacs-lisp code block named harris-matrix that
 generates dot code.

 #+header: :var input=harris-matrix
 #+header: :file temp.pdf
 #+header: :cmdline -Tpdf
 #+header: :results output
 #+BEGIN_SRC dot
 $input
 #+END_SRC

 It's not quite what you were after, but it might help?

 All the best,
 Tom

 --
 Thomas S. Dye
 http://www.tsdye.com



Re: [O] default headers for source code blocks

2014-09-09 Thread Ista Zahn
Hi Subhan,

I think the idea is that you should not set his on each individual
block, but set global values. For example

#+PROPERTY: header-args:sql  :exports code :tangle yes :comments noweb

Best,
Ista

On Tue, Sep 9, 2014 at 1:24 PM, Subhan Michael Tindall
subh...@familycareinc.org wrote:
 My apologies if this is in TFM, but I can’t seem to find it after
 substantial digging.

 I’m using a lot of source code blocks lately.

 What I’d like is a way to specify a set of default headers to insert when a
 new block is created.

 Right now:

 C-c C-v d sql RET

 #+begin_src sql

 #+end_src



 What I want is this:

 C-c C-v d sql RET

 #+begin_src sql  :exports code :tangle yes :comments noweb

 #+end_src



 Is there a configuration variable I can set for this?  All I can find is
 refs to see source language documentation, but nothing that actually
 indicates if/how to manage it.



 Thanks,





 Subhan Michael Tindall

 Program Analyst – FamilyCare Health Plans

 825 NE Multnomah St, Suite 1400; Portland OR 97232

 Direct: 503-471-3127

 Fax:  503-471-3177

 Email:  subh...@familycareinc.org




 This message is intended for the sole use of the individual and entity to
 which it is addressed and may contain information that is privileged,
 confidential and exempt from disclosure under applicable law. If you are not
 the intended addressee, nor authorized to receive for the intended
 addressee, you are hereby notified that you may not use, copy, disclose or
 distribute to anyone the message or any information contained in the
 message. If you have received this message in error, please immediately
 advise the sender by reply email and delete the message.  Thank you.



Re: [O] R code block produces only partial output

2014-08-23 Thread Ista Zahn
On Sat, Aug 23, 2014 at 2:35 PM, Thomas S. Dye t...@tsdye.com wrote:
 Aaron Ecay aarone...@gmail.com writes:

 Well, I think that it’s going to be difficult to make babel a better
 literate programming solution for R if we restrict ourselves not to
 use the state-of-the-art R package for low-level literate programming
 support.  Org is full of features which one needs to install other
 software to use, and I’m comfortable with the idea that babel’s R
 support should require the evaluate package.  However, it’s difficult
 to argue this point of view when no one has spoken up about their own
 requirements, and a spirit of conservatism in the face of vague
 imagined difficulties persists.

 As a regular user of babel, including ob-R, I do want to see it mature
 into a state-of-the-art, productive literate programming environment.
 I've followed babel development for a long time and my sense is that
 responsible experimentation is the norm, backed up by the ability to
 revert commits that end up causing undue headaches.  If Aaron's good
 work on ob-R raises howls of protest from users with restrictive IT
 managers, or the evaluate package somehow becomes a pariah, then at some
 point ob-R would have to drop the evaluate package requirement.  If not,
 then the rest of us can enjoy the benefits of Aaron's labor (hopefully
 on master and not as a series of patches, which are a real pain for us
 non-programmer types to maintain).

 My $0.02.

+1.

R has considerable infrastructure to support litterarate programming,
and it makes little sense to avoid using it because a) some
hypothetical users will have difficulty installing the software or b)
because other languages supported by babel lack similar functionality.
We are currently missing out on some useful things available in other
literate programming systems for R, such as the ability to easily
return interleaved input and output, and I would really like to see R
support in babel take advantage of existing R features to provide a
first-class R literate programming environment.

Best,
Ista


 Tom

 --
 Thomas S. Dye
 http://www.tsdye.com




Re: [O] How to disable block evaluation results being wrapped with a single character like =?

2014-08-04 Thread Ista Zahn
Hi Grant,

I cannot reproduce. Here is what I see:

#+BEGIN_SRC emacs-lisp
  (setq  org-babel-min-lines-for-block-output 10)
  (print 1)
#+END_SRC

#+RESULTS:
: 1

#+BEGIN_SRC emacs-lisp
  (setq  org-babel-min-lines-for-block-output 0)
  (print 1)
#+END_SRC

#+RESULTS:
#+begin_example
1
#+end_example

Perhaps try with emacs -q and see what you get.


Best,
Ista

On Mon, Aug 4, 2014 at 1:23 PM, Grant Rettke g...@wisdomandwonder.com wrote:
 That is what I was thinking.

 I had set it to 0.

 What happened is that instead of a block showing up, the results were
 delimited with a prepended '=' instead of a ':'.

 Unfortunately I forgot how this occurred, as I manually wrapped the
 result with a block instead, so org was happy to use that instead.
 Grant Rettke | ACM, ASA, FSF, IEEE, SIAM
 g...@wisdomandwonder.com | http://www.wisdomandwonder.com/
 “Wisdom begins in wonder.” --Socrates
 ((λ (x) (x x)) (λ (x) (x x)))
 “Life has become immeasurably better since I have been forced to stop
 taking it seriously.” --Thompson


 On Sun, Aug 3, 2014 at 7:24 PM, Ista Zahn istaz...@gmail.com wrote:
 I'm somewhat confused by the wrapped in = part, but I think you are
 looking for 'C-h v org-babel-min-lines-for-block-output'.

 Best,
 Ista

 On Sun, Aug 3, 2014 at 3:03 PM, Grant Rettke g...@wisdomandwonder.com 
 wrote:
 Hi,

 Sometimes block evaluation results are wrapped with a single character like 
 =.

 When exporting to latex, the results block is lost.

 How may one force block evaluation always to be wrapped properly for
 export to latex?

 org 8.2.7a

 Kind regards,

 Grant Rettke | ACM, ASA, FSF, IEEE, SIAM
 g...@wisdomandwonder.com | http://www.wisdomandwonder.com/
 “Wisdom begins in wonder.” --Socrates
 ((λ (x) (x x)) (λ (x) (x x)))
 “Life has become immeasurably better since I have been forced to stop
 taking it seriously.” --Thompson




Re: [O] How to disable block evaluation results being wrapped with a single character like =?

2014-08-03 Thread Ista Zahn
I'm somewhat confused by the wrapped in = part, but I think you are
looking for 'C-h v org-babel-min-lines-for-block-output'.

Best,
Ista

On Sun, Aug 3, 2014 at 3:03 PM, Grant Rettke g...@wisdomandwonder.com wrote:
 Hi,

 Sometimes block evaluation results are wrapped with a single character like =.

 When exporting to latex, the results block is lost.

 How may one force block evaluation always to be wrapped properly for
 export to latex?

 org 8.2.7a

 Kind regards,

 Grant Rettke | ACM, ASA, FSF, IEEE, SIAM
 g...@wisdomandwonder.com | http://www.wisdomandwonder.com/
 “Wisdom begins in wonder.” --Socrates
 ((λ (x) (x x)) (λ (x) (x x)))
 “Life has become immeasurably better since I have been forced to stop
 taking it seriously.” --Thompson




Re: [O] Enabling another language in org-babel

2014-07-31 Thread Ista Zahn
On Thu, Jul 31, 2014 at 6:52 AM, Bastien b...@gnu.org wrote:
 Hi Ista,

 Ista Zahn istaz...@gmail.com writes:

 I asked Bastien privately about getting access to the git repository,
 but will ask here as well: When I run 'git clone
 orgm...@orgmode.org:org-mode.git' I get a response saying

 Permission denied (publickey).
 fatal: Could not read from remote repository

 This should be fixed now, let me know,

Yes working now, thank you!


 --
  Bastien



Re: [O] Enabling another language in org-babel

2014-07-30 Thread Ista Zahn
I've made the suggested changes, with the exception of the part of
Emacs bit,  as this should go in contrib not core.

I asked Bastien privately about getting access to the git repository,
but will ask here as well: When I run 'git clone
orgm...@orgmode.org:org-mode.git' I get a response saying

Permission denied (publickey).
fatal: Could not read from remote repository

Does that mean my key wasn't properly added, or did I miss some required set-up?

Best,
Ista

On Tue, Jul 29, 2014 at 10:36 AM, Bastien b...@gnu.org wrote:
 Hi Ista,

 some comments on the code below.

 Ista Zahn istaz...@gmail.com writes:

 ;; Copyright (C) 2014 Ista Zahn
 ;; Author: Ista Zahn, based on ob-julia.el by G. Jay Kerns, and ob-R.el
 ;; by Eric Schulte and Dan Davison

 You need to reformat this -- see files with multiple authors in Org or
 in Emacs.

 ;; This file is not part of GNU Emacs.

 We plan to add this to Org's core, so this will be part of Emacs.

 ;; Stata and ESS are required.

 Maybe add some links for the requirements.

 (defcustom org-babel-stata-command inferior-STA-program-name
   Name of command to use for executing stata code.
   :group 'org-babel
   :version 24.4
   :package-version '(Org . 8.0)
   ^^^

 This needs to be 8.3

 ;; The following was a very complicated write object command
 ;; The replacement needs to add error catching
 ;(defvar org-babel-stata-write-object-command 
 {function(object,transfer.file){object;invisible(if(inherits(try({tfile-tempfile();write.table(object,file=tfile,sep=\\\t\,na=\nil\,row.names=%s,col.names=%s,quote=FALSE);file.rename(tfile,transfer.file)},silent=TRUE),\try-error\)){if(!file.exists(transfer.file))file.create(transfer.file)})}}(object=%s,transfer.file=\%s\))

 Maybe simply remove this, or make it more readable.

 Thanks in advance for this contribution!

 --
  Bastien
;;; ob-stata.el --- org-babel functions for stata code evaluation

;; Copyright (C) 2014 Ista Zahn
;; Author: Ista Zahn istaz...@gmail.com
;;  G. Jay Kerns
;;  Eric Schulte
;;  Dan Davison


;; This file is not part of GNU Emacs.

;; This program is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation; either version 3, or (at your option)
;; any later version.
;;
;; This program is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
;; GNU General Public License for more details.
;;
;; You should have received a copy of the GNU General Public License
;; along with GNU Emacs; see the file COPYING.  If not, write to the
;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
;; Boston, MA 02110-1301, USA.

;;; Commentary:

;; The file provides Org-Babel support for evaluating stata code.
;; It is basically result of find-and-replace stata for julia
;; in ob-julia.el by G. Jay Kerns. Only :results output works: the
;; header args must include :results output (this is the default).
;; Note that I'm not sure ':results value' makes sense or is useful 
;; but I have left all the value-processing stuff inherited from 
;; ob-julia and ob-R. ':results graphics' would be nice, but I have
;; not tried to implement it. 
;; --Ista, 07/30/2014

;;; Requirements:
;; Stata: http://stata.com
;; ESS: http://ess.r-project.org

;;; Code:
(require 'ob)
(eval-when-compile (require 'cl))

(declare-function orgtbl-to-csv org-table (table params))
(declare-function stata ext:ess-stata (optional start-args))
(declare-function inferior-ess-send-input ext:ess-inf ())
(declare-function ess-make-buffer-current ext:ess-inf ())
(declare-function ess-eval-buffer ext:ess-inf (vis))
(declare-function org-number-sequence org-compat (from optional to inc))
(declare-function org-remove-if-not org (predicate seq))

(defconst org-babel-header-args:stata
  '((width		 . :any)
(horizontal		 . :any)
(results . ((file list vector table scalar verbatim)
			(raw org html latex code pp wrap)
			(replace silent append prepend)
;; NOTE: not sure 'value' makes sense in stata
;; we may want to remove it from the list
			(output value graphics
  stata-specific header arguments.)

(add-to-list 'org-babel-tangle-lang-exts '(stata . do))

;; only ':results output' currently works, so make that the default
(defvar org-babel-default-header-args:stata '((:results . output)))

(defcustom org-babel-stata-command inferior-STA-program-name
  Name of command to use for executing stata code.
  :group 'org-babel
  :version 24.4
  :package-version '(Org . 8.3)
  :type 'string)

(defvar ess-local-process-name) ; dynamically scoped
(defun org-babel-edit-prep:stata (info)
  (let ((session (cdr (assoc :session (nth 2 info)
(when (and session (string-match ^\\*\\(.+?\\)\\*$ session))
  (save

[O] [PATCH] ob-stata.el: new file for stata code evaluation

2014-07-30 Thread Ista Zahn
Here is a patch (against master) adding babel support for evaluating
stata code. As discussed in a previous thread[1] there is a lot of
work that should be done to clean it up and make it more useful. It
does work for basic code evaluation, so I'm submitting it here in the
hope that others find it useful.

Best,
Ista

[1] https://lists.gnu.org/archive/html/emacs-orgmode/2014-06/msg00862.html
From 24d957b8fc3eb207158e94cdec1a362ba2e79ff0 Mon Sep 17 00:00:00 2001
From: Ista Zahn istaz...@gmail.com
Date: Wed, 30 Jul 2014 17:07:16 -0400
Subject: [PATCH] ob-stata.el: new file for stata code evaluation

* contrib/lisp/ob-stata.el: New file based on ob-julia.el.
* contrib/README: Document addition of new file.

ob-stata.el provides basic support for evaluating Stata code.
---
 contrib/README   |   1 +
 contrib/lisp/ob-stata.el | 313 +++
 2 files changed, 314 insertions(+)
 create mode 100644 contrib/lisp/ob-stata.el

diff --git a/contrib/README b/contrib/README
index 2a67b65..e92da14 100644
--- a/contrib/README
+++ b/contrib/README
@@ -80,6 +80,7 @@ ob-fomus.el	 --- Org-babel functions for fomus evaluation
 ob-julia.el  	 	 --- Org-babel functions for julia evaluation
 ob-mathomatic.el   	 --- Org-babel functions for mathomatic evaluation
 ob-oz.el   	 --- Org-babel functions for Oz evaluation
+ob-stata.el  --- Org-babel functions for Stata evaluation
 ob-tcl.el 		 --- Org-babel functions for tcl evaluation
 
 External libraries
diff --git a/contrib/lisp/ob-stata.el b/contrib/lisp/ob-stata.el
new file mode 100644
index 000..8a70754
--- /dev/null
+++ b/contrib/lisp/ob-stata.el
@@ -0,0 +1,313 @@
+;;; ob-stata.el --- org-babel functions for stata code evaluation
+
+;; Copyright (C) 2014 Ista Zahn
+;; Author: Ista Zahn istaz...@gmail.com
+;;  G. Jay Kerns
+;;  Eric Schulte
+;;  Dan Davison
+
+
+;; This file is not part of GNU Emacs.
+
+;; This program is free software; you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation; either version 3, or (at your option)
+;; any later version.
+;;
+;; This program is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+;; GNU General Public License for more details.
+;;
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING.  If not, write to the
+;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+;; Boston, MA 02110-1301, USA.
+
+;;; Commentary:
+
+;; The file provides Org-Babel support for evaluating stata code.
+;; It is basically result of find-and-replace stata for julia
+;; in ob-julia.el by G. Jay Kerns. Only :results output works: the
+;; header args must include :results output (this is the default).
+;; Note that I'm not sure ':results value' makes sense or is useful 
+;; but I have left all the value-processing stuff inherited from 
+;; ob-julia and ob-R. ':results graphics' would be nice, but I have
+;; not tried to implement it. 
+;; --Ista, 07/30/2014
+
+;;; Requirements:
+;; Stata: http://stata.com
+;; ESS: http://ess.r-project.org
+
+;;; Code:
+(require 'ob)
+(eval-when-compile (require 'cl))
+
+(declare-function orgtbl-to-csv org-table (table params))
+(declare-function stata ext:ess-stata (optional start-args))
+(declare-function inferior-ess-send-input ext:ess-inf ())
+(declare-function ess-make-buffer-current ext:ess-inf ())
+(declare-function ess-eval-buffer ext:ess-inf (vis))
+(declare-function org-number-sequence org-compat (from optional to inc))
+(declare-function org-remove-if-not org (predicate seq))
+
+(defconst org-babel-header-args:stata
+  '((width		 . :any)
+(horizontal		 . :any)
+(results . ((file list vector table scalar verbatim)
+			(raw org html latex code pp wrap)
+			(replace silent append prepend)
+;; NOTE: not sure 'value' makes sense in stata
+;; we may want to remove it from the list
+			(output value graphics
+  stata-specific header arguments.)
+
+(add-to-list 'org-babel-tangle-lang-exts '(stata . do))
+
+;; only ':results output' currently works, so make that the default
+(defvar org-babel-default-header-args:stata '((:results . output)))
+
+(defcustom org-babel-stata-command inferior-STA-program-name
+  Name of command to use for executing stata code.
+  :group 'org-babel
+  :version 24.4
+  :package-version '(Org . 8.3)
+  :type 'string)
+
+(defvar ess-local-process-name) ; dynamically scoped
+(defun org-babel-edit-prep:stata (info)
+  (let ((session (cdr (assoc :session (nth 2 info)
+(when (and session (string-match ^\\*\\(.+?\\)\\*$ session))
+  (save-match-data (org-babel-stata-initiate-session session nil)
+
+(defun org-babel-expand

Re: [O] Enabling another language in org-babel

2014-07-28 Thread Ista Zahn
Hi all,

Please find code attached that implements stata support in org-babel.
The attached ob-stata.el is a modified version of ob-julia.el. It
currently supports evaluation of stata code from babel code blocks
with ':results output' (and this has been set as the default). Neither
':results value' nor ':results graphics' work. I suspect that
':results value' doen't make sense for stata, in which case all the
value-specific stuff should be removed. I would like to eventually get
':results graphics' working, but have not yet implemented it.

If there are no objections I would like to add this to contrib.

Best,
Ista

On Mon, Jul 28, 2014 at 9:20 AM, Bastien b...@gnu.org wrote:
 Hi Ista,

 Ista Zahn istaz...@gmail.com writes:

 I don't know if this is ready for contrib yet (though I don't object
 if you think it is). I'm not sure what quality standards exist for
 contrib, but this is really quick and dirty; it would be nice to at
 least implement graphics support. On the other hand its better than
 nothing, so maybe it does make sense to add it to contrib.

 Yes, it makes sense to add it to contrib, it will help others step up
 and improve the code if needed.

 Also I'm not sure what the development process is once things go in
 contrib (sorry for my ignorance!). Does contrib live in the same code
 repository as the rest of org, or are things in contrib developed
 separately and pulled in later?

 contrib/ lives in the same Git repository than the rest of Org (which
 is arguably a problem).  So everything is developed at the same place.

 Once you send me your public key, I'll grant you write access to the
 repository and you can push commits.

 In short feel free to add it to contrib if you want, but be aware that
 it is  in pretty rough shape.

 Please provide a separate commit on the list for this piece of code,
 so that we can review it and commit it.  And if you want to get push
 access, please send me your public key.

 Thanks!

 --
  Bastien
;;; ob-stata.el --- org-babel functions for stata code evaluation

;; Copyright (C) 2014 Ista Zahn
;; Author: Ista Zahn, based on ob-julia.el by G. Jay Kerns, and ob-R.el
;; by Eric Schulte and Dan Davison


;; This file is not part of GNU Emacs.

;; This program is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation; either version 3, or (at your option)
;; any later version.
;;
;; This program is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
;; GNU General Public License for more details.
;;
;; You should have received a copy of the GNU General Public License
;; along with GNU Emacs; see the file COPYING.  If not, write to the
;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
;; Boston, MA 02110-1301, USA.

;;; Commentary:

;; The file provides Org-Babel support for evaluating stata code.
;; It is basically result of find-and-replace stata for julia
;; in ob-julia.el by G. Jay Kerns. Only :results output works: the
;; header args must include :results output (this is the default).
;; Note that I'm not sure ':results value' makes sense or is useful 
;; but I have left all the value-processing stuff inherited from 
;; ob-julia and ob-R. ':results graphics' would be nice, but I have
;; not tried to implement it.

;;; Requirements:

;; Stata and ESS are required.

;;; Code:
(require 'ob)
(eval-when-compile (require 'cl))

(declare-function orgtbl-to-csv org-table (table params))
(declare-function stata ext:ess-stata (optional start-args))
(declare-function inferior-ess-send-input ext:ess-inf ())
(declare-function ess-make-buffer-current ext:ess-inf ())
(declare-function ess-eval-buffer ext:ess-inf (vis))
(declare-function org-number-sequence org-compat (from optional to inc))
(declare-function org-remove-if-not org (predicate seq))

(defconst org-babel-header-args:stata
  '((width		 . :any)
(horizontal		 . :any)
(results . ((file list vector table scalar verbatim)
			(raw org html latex code pp wrap)
			(replace silent append prepend)
;; NOTE: not sure 'value' makes sense in stata
;; we may want to remove it from the list
			(output value graphics
  stata-specific header arguments.)

(add-to-list 'org-babel-tangle-lang-exts '(stata . do))

;; only ':results output' currently works, so make that the default
(defvar org-babel-default-header-args:stata '((:results . output)))

(defcustom org-babel-stata-command inferior-STA-program-name
  Name of command to use for executing stata code.
  :group 'org-babel
  :version 24.4
  :package-version '(Org . 8.0)
  :type 'string)

(defvar ess-local-process-name) ; dynamically scoped
(defun org-babel-edit-prep:stata (info)
  (let ((session (cdr (assoc :session (nth 2 info)
(when

Re: [O] Evaluating inline source blocks on export issue

2014-07-24 Thread Ista Zahn
On Thu, Jul 24, 2014 at 6:14 AM, Andreas Leha
andreas.l...@med.uni-goettingen.de wrote:
 Nick Dokos ndo...@gmail.com writes:

 Grant Rettke g...@wisdomandwonder.com writes:

 Thanks for looking Thomas and Nick.

 When I set this and export

 ,
 | (setq org-export-babel-evaluate t)
 `

 I get the expected result of

 ,
 | Here is a `16', stuck in the middle of some prose.
 `

 But when I do this and export

 ,
 | (setq org-export-babel-evaluate 'inline-only)
 `

 I get this output which is not what I expected

 ,
 | Here is a , stuck in the middle of some prose.
 `

 I thought that I was enabling inline code block execution correctly
 and making the inline call correctly.

 How does it look should it be doing what I had wanted?


 I don't think you can: the `type' (see below) of the inline code is not
 `inline' as one might think at first, but `lob', presumably because
 call_foo is defined in the library-of-babel.

 The relevant code is in ob-exp.el:org-babel-exp-results:

 ,
 |   ...
 |   (when (and (or (eq org-export-babel-evaluate t)
 |  (and (eq type 'inline)
 |   (eq org-export-babel-evaluate 'inline-only)))
 |  (not (and hash (equal hash (org-babel-current-result-hash)
 |   ...
 `

 Then I would like to turn this into a feature request:  Enable
 inline-block-specific settings.

I'm not sure if this solves your problem, but

--8---cut here---start-8---
 #+name: squareFun
 #+begin_src emacs-lisp :exports none
   (defun square (it) (* it it))
 #+end_src

 #+RESULTS: squareFun
 : square

Here is a src_emacs-lisp{(square 10)}, from an inline source block.
--8---cut here---end---8---

does work with org-export-babel-evaluate set to 'inline-only. You do
have to evaluate the squareFun block before exporting.

Best,
Ista




 This does not only hold for the evaluation, but also for default header
 arguments.  Different settings for inline code are quite useful.  I do
 have to specify [:results raw] on the block-to-block basis quite a lot
 and would benefit a lot from global inline-specific settings.

 As always, point me to the way to do it, if (quite likely) this is
 possible already.

 Regards,
 Andreas





Re: [O] org-ref in action

2014-06-27 Thread Ista Zahn
Yes, totally off topic for this thread, please start a new one.

On Fri, Jun 27, 2014 at 12:27 AM, Xebar Saram zelt...@gmail.com wrote:
 Hi all

 off topic a bit again. im an academic (asst. prof) in Epidemiology and have
 been using org-mode for about a year now. i love using org but im really not
 very technical at all. it has always been a dream for me to ditch word and
 move over to Latex and even better orgmode to write my scientific
 publications, writing my CV etc.
 The problem is i cant really find a good for dummies guide on how to
 really get started. again im really not technical so i always give up really
 fast on this.

 Do you guys think i should give it a shot (again not very technical :)) and
 if so what would be the steps/guides to follow? perhaps start by drafting a
 CV since thats perhaps easier?

 kind regards

 Z.






 On Thu, Jun 26, 2014 at 9:44 PM, Matt Lundin m...@imapmail.org wrote:

 Alan Schmitt alan.schm...@polytechnique.org writes:

  On 2014-06-26 16:39, Matt Lundin m...@imapmail.org writes:
 
  By contrast, ox-bibtex.el runs citations through bibtex2html, which is
  pretty much limited to the old-fashioned bibtex formats.
 
  What would be required for bibtex2html to take biblatex input? I thought
  the backend format was similar or the same (as you can tell, I know
  nothing of biblatex).

 I don't think this is possible without some major
 hacking/conversion/filtering. Biblatex has many more entry types and
 fields than bibtex. I've found that most of the older bibtex utils
 (bibtools, bibtex2html) choke on my biblatex files.

 Even if biblatex2html did read biblatex data, its output, I believe, is
 limited to bibtex styles, which cannot handle more complex formats. Many
 scientific journals require bibtex formats. But many humanities
 disciplines have more complicated bibliographical requirements that
 bibtex cannot handle.

 Best,
 Matt





Re: [O] Enabling another language in org-babel

2014-06-25 Thread Ista Zahn
Hi Bastien,

I don't know if this is ready for contrib yet (though I don't object
if you think it is). I'm not sure what quality standards exist for
contrib, but this is really quick and dirty; it would be nice to at
least implement graphics support. On the other hand its better than
nothing, so maybe it does make sense to add it to contrib.

Also I'm not sure what the development process is once things go in
contrib (sorry for my ignorance!). Does contrib live in the same code
repository as the rest of org, or are things in contrib developed
separately and pulled in later?

In short feel free to add it to contrib if you want, but be aware that
it is  in pretty rough shape.

Best,
Ista

On Wed, Jun 25, 2014 at 4:33 AM, Bastien b...@gnu.org wrote:
 Hi Ista,

 Ista Zahn istaz...@gmail.com writes:

 The code is available at
 https://gist.github.com/izahn/5745dcf6dd07a6b05084

 Looks good -- would you like to add it to the contrib/ directory
 in Org's repository?

 As for the original question, I think it would be a nice addition,
 let's put it somewhere on our collective TODO list :)

 --
  Bastien



Re: [O] Babel-R vs. ESS

2014-06-25 Thread Ista Zahn
Hi Shiyuan,

On Wed, Jun 25, 2014 at 3:08 AM, Shiyuan gshy2...@gmail.com wrote:
 Hi all,
 I am learning R and  use Emacs to work with R. I googled around and I
 found two options: ESS and Org-R/Org-Babel.

Org-Babel and ESS are not really alternatives; in fact the complement
each other nicely. Org gives you a lightweight markup language, and a
way to embed source code blocks. You can edit/evaluate/test R source
code blocks using ESS.

 Babel speaks multiple languages( Any languages?-if we write some sort of
 parser, which I assume is not terribly difficult under Babel?).

 But if R is the primary language I would use, which option (Babel-R vs ESS)
 is more advisable? I do want a nice integration of graphics/source code into
 a paper/slides.

Basically if you're using R in emacs you want to be using ESS. You can
also use org-mode to easily create reports, slides, etc. with embedded
R code.


Best,
Ista

 Any suggestions/options are appreciated.

 Shiyuan



Re: [O] Enabling another language in org-babel

2014-06-24 Thread Ista Zahn
I just hacked up a rudimentary ob-stata.el by replacing julia with
stata in ob-julia.el by G. Jay Kerns (and making a few other minor
tweaks). Only :results output works (no graphics, no :results
value). In short it's in pretty rough shape, but it does work for some
basic things. Perhaps someone with better emacs-lisp can polish it up.
The code is available at
https://gist.github.com/izahn/5745dcf6dd07a6b05084

Best,
Ista

On Tue, Jun 24, 2014 at 8:05 AM, Rainer M Krug rai...@krugs.de wrote:
 Eric Schulte schulte.e...@gmail.com writes:

 Brendan Halpin brendan.hal...@ul.ie writes:

 Does there exist any documentation on extending org-babel to another
 language?


 Hi Brendan,

 There is a template [1] which may be filled out to add support for a new
 language.  More generally simply defining a function named
 `org-babel-execute:foo' will cause babel to try to execute foo code
 blocks using that function.  See the template for existing
 `org-babel-execute:*' functions.


 Relatedly, is anyone working on adding Stata coverage to org-babel?


 I'm not but who knows.  If you do add support for Stata please consider
 contributing it to Org-mode (see [2]).

 stata should be not to difficult to add, as ESS supports stata and I
 would guess that most functions would be the same (or very similar)

 Cheers,

 Rainer


 Best,
 Eric



 Regards,

 Brendan


 Footnotes:
 [1]  
 http://orgmode.org/w/worg.git/blob/HEAD:/org-contrib/babel/ob-template.el

 [2]  http://orgmode.org/worg/org-contribute.html

 --
 Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, 
 UCT), Dipl. Phys. (Germany)

 Centre of Excellence for Invasion Biology
 Stellenbosch University
 South Africa

 Tel :   +33 - (0)9 53 10 27 44
 Cell:   +33 - (0)6 85 62 59 98
 Fax :   +33 - (0)9 58 10 27 44

 Fax (D):+49 - (0)3 21 21 25 22 44

 email:  rai...@krugs.de

 Skype:  RMkrug

 PGP: 0x0F52F982



Re: [O] org-ref in action

2014-06-24 Thread Ista Zahn
John,

This is simply amazing. I think this covers basically every item on my
org-mode reference handling wish list.  It's really great, thank you!

Will this be on Melpa soon?

-Ista

On Tue, Jun 24, 2014 at 2:45 PM, John Kitchin jkitc...@andrew.cmu.edu wrote:
 Hello everyone,

 org-ref has basically stabilized. You can get the latest code at
 https://github.com/jkitchin/jmax/blob/master/org-ref.org.

 I made a little screen capture video here to show you what it does:
 https://www.youtube.com/watch?v=JyvpSVl4_dg

 Try it out, if it looks interesting, and let me know if you find any
 bugs!

 Thanks,

 --
 ---
 John Kitchin





Re: [O] Exporting LaTeX source blocks with HTML backend

2014-03-03 Thread Ista Zahn
Hi Xavier,

I think

#+begin_src latex :results drawer :exports results
  \begin{align*}
  x=x\\
  y=y
  \end{align*}
#+end_src

will give both syntax highlighting (in the code block) as well as
properly displayed equations in both latex and html export.

Best,
Ista

On Mon, Mar 3, 2014 at 2:39 PM, Xavier Garrido xavier.garr...@gmail.com wrote:
 Hi Richard,

 Le 03/03/2014 20:24, Richard Lawrence a écrit :

 I am facing one issue when I am exporting from orgmode to html. I like
 to write LaTeX code within #+BEGIN_SRC latex ... #+END_SRC block mainly
 to take benefit/advantage of the syntax highlighting (debugging long
 LaTeX equations is simpler). The problem is that these code blocks are
 not exported at all by the html export backend whereas the LaTeX backend
 does. Of course, an easy solution will be to remove the
 #+BEGIN_SRC/#+END_SRC lines and both latex and html exporters will just
 do it right. But, as I said, syntax highlighting is really useful and I
 can't imagine living without it.

 I don't quite understand what you're looking for here.  Are you wanting
 these blocks to be exported as source code?  Or do you want them to be
 interpreted somehow?


 I would like to get them interpreted as raw LaTeX code in such way MathJax
 can reinterpret them as you said.


 Removing the BEGIN_SRC/END_SRC lines will just result in raw LaTeX code
 getting dumped into your HTML, and a browser won't know what to do with
 that (at least not without help...are you wanting MathJax to interpret
 it?).

 As a summary I would like to do the following

 #+BEGIN_SRC org
 * Test LaTeX block
 Syntax highlighting is always nice but the following block is not
 exported in html. An option will be to remove the #+BEGIN_SRC
 latex/#+END_SRC lines

 #+BEGIN_SRC latex
   \begin{align*}
   x=x\\
   y=y
   \end{align*}
 #+END_SRC

 When I export this using the HTML exporter, the LaTeX code is wrapped in
 a div with class=org-src-container, and the actual code appears
 inside a pre tag.  Is this the behavior you see?  Is that not what you
 want?

 In my case, the code is not even wrapped into org-src-container class, it
 just does not appear at all.




 If you are instead looking to get something in your HTML output that
 looks like the result of compiling the LaTeX code, I am not exactly sure
 how to accomplish this, but it looks like there is some useful
 information in the section Math formatting in HTML export in the Org
 manual about either using MathJax or preprocessing LaTeX code into
 images with dvipng.


 Actually, I just want to get the LaTeX code translated into raw code. As I
 wrote, there is one solution, pretty easy to implement and may be used by
 most of the org users : write raw LaTeX inside org document and use MathJax
 for example, to interpret it in a convenient way. It is going to work for
 both exporter html and latex. The point here is that using raw LaTeX code
 makes me lose the syntax highlighting which is really useful for debugging
 long LaTeX equation.

 Cheers,
 Xavier

 Hope that helps,
 Richard


 (If possible, please encrypt your reply to me using my PGP key:
 Key ID: CF6FA646
 Fingerprint: 9969 43E1 CF6F A646.
 See http://www.ocf.berkeley.edu/~rwl/encryption.html for more
 information.)






Re: [O] link interfering with brackets when abbreviated

2014-03-02 Thread Ista Zahn
Another user here, chiming in to support Nicolas's position. From my
perspective orgmode is so vast and complicated that the number one
thing we need (even from a user perspective) is predictability. I'd
rather see minor conveniences removed in favor of a constancy and a
logical interface.

Best,
Ista

On Sun, Mar 2, 2014 at 4:16 PM, Gustav Wikström gustav.e...@gmail.com wrote:
 Hi, a user signing in. Although not involved in the development of this
 piece of software I'm taking the opportunity to chime in anyway.

 I'd like to give Nicolas Goaziou my support in this issue. It makes it much
 simpler to understand, use, develop and maintain the software if it is
 congruent. A well defined syntax, and tools that respect the rules of how to
 parse it, will IMO be of big importance moving forward.

 About the issue of two links on the same line.. From my perspective (for
 what it's worth); Trying to open a link when not being inside a link with
 the mark should give the same behaviour as trying to open a link when on a
 headline. It is not certain which link is intended to be opened, so why not
 give the user the options available instead of guessing? Set the scope to
 parse to the current paragraph, to make a difference from calling C-c C-o
 from the headline. That, to me, is the intuitive behaviour.

 About the issue of links in comments (My opinion, for what it's worth): It's
 a comment.. Expect it to behave as one. Worst case: copy the link and paste
 it in the browser.

 About the issue of links in properties: Wouldn't it be nice to allow this?
 Maybe a future functionality to consider?


 Best regards

 Gustav Wikström



Re: [O] No ODT export option

2014-01-10 Thread Ista Zahn
Hi Ken,

ODT export isn't enabled by default. You can enable it by putting

(require 'ox-odt)

in your config file and restart emacs.

Best,
Ista

On Fri, Jan 10, 2014 at 11:23 AM, Ken Mankoff mank...@gmail.com wrote:
 Hi,

 I'd like to export to ODT or even directly to DOC. But I notice I do not
 have an ODT export option. Can someone help me set this up?

 I'm running org-20140107/ from ELPA on OS X in the emacs 24.3
 (emacsformacosx distribution from http://emacsformacosx.com/). In my ELPA
 folder I see:

 $ find . | grep -i odt
 ./org-20140107/etc/styles/OrgOdtContentTemplate.xml
 ./org-20140107/etc/styles/OrgOdtStyles.xml
 ./org-20140107/ox-odt.el
 ./org-20140107/ox-odt.elc

 But when I'm in emacs in org-mode and I do ESC-x apropos org-odt and
 examine org-odt-data-dir the content of that variable are
 /usr/share/emacs/etc/org which does not exist.

 Any help for ODT (and/or DOC) much appreciated.

 FYI I also have LibreOffice installed which is how I will view the ODT
 files, and/or do the DOC conversion if I can't get that straight from org.

 Thank you,

Ken Mankoff



Re: [O] Export each top level heading to separate file

2014-01-05 Thread Ista Zahn
On Sun, Jan 5, 2014 at 8:40 AM, John Kitchin jkitc...@andrew.cmu.edu wrote:
 Try this:


 (org-map-entries
  (lambda ()
(let ((level (nth 1 (org-heading-components)))
  (title (nth 4 (org-heading-components
  (if (= level 1)
  (org-entry-put (point) :EXPORT_FILE_NAME: title
  nil nil)

 It seems to do what you want.

Dear John,

Thank you thank you! Using your code as I template I managed to write
a function that does what I wanted:

(defun my-exp-headings-to-markdown ()
  Export each top-level heading to markdown.
  (interactive)
  (org-map-entries
   (lambda ()
 (let ((level (nth 1 (org-heading-components)))
  (title (nth 4 (org-heading-components
   (if (= level 1)
  (org-entry-put (point) EXPORT_FILE_NAME title))
   (if (= level 1)
  (org-md-export-to-markdown nil 1 nil
   nil nil))

Note that I had to remove the : from the second argument to
org-entry-put to get it working properly on my system. Not sure if
that was a bug in your original example or not.

Best,
Ista


 John

 ---
 John Kitchin
 Associate Professor
 Doherty Hall A207F
 Department of Chemical Engineering
 Carnegie Mellon University
 Pittsburgh, PA 15213
 412-268-7803
 http://kitchingroup.cheme.cmu.edu



 On Sat, Jan 4, 2014 at 7:36 PM, Ista Zahn istaz...@gmail.com wrote:

 On Sat, Jan 4, 2014 at 6:41 PM, Alan L Tyree alanty...@gmail.com wrote:
  On 05/01/14 09:45, Charles Millar wrote:
 
  Ista and all,
 
  On 1/4/2014 5:29 PM, Ista Zahn wrote:
 
  Hi all,
 
  I'm looking for a way to export each top-level heading to a separate
  markdown file. Ideally I would like to have the exported files named
  according to the heading. For example I would like this org file
 
  ---
  * Section one
  Section one text
  * Section two
  ** Section two a
  Section two text
  * Section three
  Section three text
  ---
 
  To generate three files:
 
  --- Section one.md ---
  Section one text
 
  ---
 
  --- Section two.md---
  ## Section two a
 
  Section two text
 
  ---
 
  --- Section three.md -
  # Section three
 
  Section three text
 
  ---
 
  I suspect that the publishing framework might support this, but I've
  thus far avoided it because it looks pretty complicated to set up.
  Before I dive in I'd like to know if the publishing framework is the
  correct place to look for this functionality or if there is an easier
  way to do it.
 
 
 
  I have a similar question regarding LaTeX export. How to export a
  heading
  (any heading, regardless of level) within a file to heading.tex instead
  of
  file.tex? So far the only solution I have cobbled together is to C-x
  C-f
  'file.tex and then C-x C-w heading.tex .  I then typeset heading.tex
  using TeXworks. Perhaps I should note that my exported heading is
  tagged so
  that the heading is ignored.
 
  Charlie Millar
 
  ---
  This email is free from viruses and malware because avast! Antivirus
  protection is active.
  http://www.avast.com
 
 
 
  Use properties to set the export file name -- example:
:PROPERTIES:
:EXPORT_TITLE: Internet banking fraud
:EXPORT_FILE_NAME: internet-fraud
:EXPORT_AUTHOR: Alan L Tyree
:Citation: (2011) 22 JBFLP 214
:EXPORT_OPTIONS: num:nil toc:nil
:END:

 Thanks, gets me half the way there. Setting properties as you
 described and exporting each sub-tree works properly. Now how can I do
 this for all the top-level headings in a file?

 Best,
 Ista

 
  If I understood your question properly.
 
  Cheers,
  Alan
 
 
 
  --
  Alan L Tyreehttp://www2.austlii.edu.au/~alan
  Tel:  04 2748 6206  sip:typh...@iptel.org
 
 





Re: [O] Export each top level heading to separate file

2014-01-05 Thread Ista Zahn
On Sun, Jan 5, 2014 at 4:56 PM, John Kitchin jkitc...@andrew.cmu.edu wrote:
 hmm.. I don't know if it was a bug, I ran the code on my system before
 sending it, and it worked for me ;)

Your original code ran for me as well, but it inserted
'::EXPORT_FILE_NAME::' where it should be just ':EXPORT_FILE_NAME:'

 I am glad you figured it out on your
 system.

 you could avoid the double if statements like this:


 (defun my-exp-headings-to-markdown ()
   Export each top-level heading to markdown.
   (interactive)
   (org-map-entries
(lambda ()
  (let ((level (nth 1 (org-heading-components)))
(title (nth 4 (org-heading-components
(when (= level 1)
  (org-entry-put (point) EXPORT_FILE_NAME title)
  (org-md-export-to-markdown nil 1 nil)
nil nil))

Great, thanks!

Best,
Ista


 The when macro is like an if macro, with no else body.

 John

 ---
 John Kitchin
 Associate Professor
 Doherty Hall A207F
 Department of Chemical Engineering
 Carnegie Mellon University
 Pittsburgh, PA 15213
 412-268-7803
 http://kitchingroup.cheme.cmu.edu



 On Sun, Jan 5, 2014 at 2:49 PM, Ista Zahn istaz...@gmail.com wrote:

 On Sun, Jan 5, 2014 at 8:40 AM, John Kitchin jkitc...@andrew.cmu.edu
 wrote:
  Try this:
 
 
  (org-map-entries
   (lambda ()
 (let ((level (nth 1 (org-heading-components)))
   (title (nth 4 (org-heading-components
   (if (= level 1)
   (org-entry-put (point) :EXPORT_FILE_NAME:
  title
   nil nil)
 
  It seems to do what you want.

 Dear John,

 Thank you thank you! Using your code as I template I managed to write
 a function that does what I wanted:

 (defun my-exp-headings-to-markdown ()
   Export each top-level heading to markdown.
   (interactive)
   (org-map-entries
(lambda ()
  (let ((level (nth 1 (org-heading-components)))
   (title (nth 4 (org-heading-components
(if (= level 1)
   (org-entry-put (point) EXPORT_FILE_NAME title))
(if (= level 1)
   (org-md-export-to-markdown nil 1 nil
nil nil))

 Note that I had to remove the : from the second argument to
 org-entry-put to get it working properly on my system. Not sure if
 that was a bug in your original example or not.

 Best,
 Ista

 
  John
 
  ---
  John Kitchin
  Associate Professor
  Doherty Hall A207F
  Department of Chemical Engineering
  Carnegie Mellon University
  Pittsburgh, PA 15213
  412-268-7803
  http://kitchingroup.cheme.cmu.edu
 
 
 
  On Sat, Jan 4, 2014 at 7:36 PM, Ista Zahn istaz...@gmail.com wrote:
 
  On Sat, Jan 4, 2014 at 6:41 PM, Alan L Tyree alanty...@gmail.com
  wrote:
   On 05/01/14 09:45, Charles Millar wrote:
  
   Ista and all,
  
   On 1/4/2014 5:29 PM, Ista Zahn wrote:
  
   Hi all,
  
   I'm looking for a way to export each top-level heading to a
   separate
   markdown file. Ideally I would like to have the exported files
   named
   according to the heading. For example I would like this org file
  
   ---
   * Section one
   Section one text
   * Section two
   ** Section two a
   Section two text
   * Section three
   Section three text
   ---
  
   To generate three files:
  
   --- Section one.md ---
   Section one text
  
   ---
  
   --- Section two.md---
   ## Section two a
  
   Section two text
  
   ---
  
   --- Section three.md -
   # Section three
  
   Section three text
  
   ---
  
   I suspect that the publishing framework might support this, but
   I've
   thus far avoided it because it looks pretty complicated to set up.
   Before I dive in I'd like to know if the publishing framework is
   the
   correct place to look for this functionality or if there is an
   easier
   way to do it.
  
  
  
   I have a similar question regarding LaTeX export. How to export a
   heading
   (any heading, regardless of level) within a file to heading.tex
   instead
   of
   file.tex? So far the only solution I have cobbled together is to C-x
   C-f
   'file.tex and then C-x C-w heading.tex .  I then typeset
   heading.tex
   using TeXworks. Perhaps I should note that my exported heading is
   tagged so
   that the heading is ignored.
  
   Charlie Millar
  
   ---
   This email is free from viruses and malware because avast! Antivirus
   protection is active.
   http://www.avast.com
  
  
  
   Use properties to set the export file name -- example:
 :PROPERTIES:
 :EXPORT_TITLE: Internet banking fraud
 :EXPORT_FILE_NAME: internet-fraud
 :EXPORT_AUTHOR: Alan L Tyree
 :Citation: (2011) 22 JBFLP 214
 :EXPORT_OPTIONS: num:nil toc:nil
 :END:
 
  Thanks, gets me half the way there. Setting properties as you
  described and exporting each sub-tree works properly. Now how can I do
  this for all

[O] Exporting markdown specific string

2014-01-04 Thread Ista Zahn
Hi all,

I'm trying to figure out how to export a line (say foo) only when
exporting to markdown.

For latex there is
'#+LATEX: foo'
and for html there is
'#+HTML: foo'
but neither
'#+MD: foo'
nor
'#+MARKDOWN: foo'
does the trick.

Of course
'#+HTML: foo'
exports foo to markdown since the markdown exporter is derived from
the html exporter. But I'd really like to include stuff in the
markdown export that does not also get included in the html export.

Suggestions? I'm using org-plus-contrib: Org-mode version 8.2.4
(8.2.4-18-g4ee7e6-elpaplus) installed using M-x install-packages.

Thanks,
Ista



Re: [O] Exporting markdown specific string

2014-01-04 Thread Ista Zahn
On Sat, Jan 4, 2014 at 1:40 PM, Charles Berry ccbe...@ucsd.edu wrote:
 Bastien bzg at gnu.org writes:


 Charles Berry ccberry at ucsd.edu writes:

  No it won't.
 
  ox-md.el does not define a transcoder for keyword and falls back to its
  parent:

 Thanks.

 I just added this transcoder to the master branch.


 Looking at org-md-export-block shouldn't it export HTML export blocks as
 well, since markdown allows literal html?

Yes, and as far as I can tell it does. But as I explained in my
original question I want certain text exported to markdown but not to
html.

Best,
Ista


 HTH,

 Chuck





[O] Export each top level heading to separate file

2014-01-04 Thread Ista Zahn
Hi all,

I'm looking for a way to export each top-level heading to a separate
markdown file. Ideally I would like to have the exported files named
according to the heading. For example I would like this org file

---
* Section one
Section one text
* Section two
** Section two a
Section two text
* Section three
Section three text
---

To generate three files:

--- Section one.md ---
Section one text

---

--- Section two.md---
## Section two a

Section two text

---

--- Section three.md -
# Section three

Section three text

---

I suspect that the publishing framework might support this, but I've
thus far avoided it because it looks pretty complicated to set up.
Before I dive in I'd like to know if the publishing framework is the
correct place to look for this functionality or if there is an easier
way to do it.

Thanks,
Ista



Re: [O] Export each top level heading to separate file

2014-01-04 Thread Ista Zahn
On Sat, Jan 4, 2014 at 6:41 PM, Alan L Tyree alanty...@gmail.com wrote:
 On 05/01/14 09:45, Charles Millar wrote:

 Ista and all,

 On 1/4/2014 5:29 PM, Ista Zahn wrote:

 Hi all,

 I'm looking for a way to export each top-level heading to a separate
 markdown file. Ideally I would like to have the exported files named
 according to the heading. For example I would like this org file

 ---
 * Section one
 Section one text
 * Section two
 ** Section two a
 Section two text
 * Section three
 Section three text
 ---

 To generate three files:

 --- Section one.md ---
 Section one text

 ---

 --- Section two.md---
 ## Section two a

 Section two text

 ---

 --- Section three.md -
 # Section three

 Section three text

 ---

 I suspect that the publishing framework might support this, but I've
 thus far avoided it because it looks pretty complicated to set up.
 Before I dive in I'd like to know if the publishing framework is the
 correct place to look for this functionality or if there is an easier
 way to do it.



 I have a similar question regarding LaTeX export. How to export a heading
 (any heading, regardless of level) within a file to heading.tex instead of
 file.tex? So far the only solution I have cobbled together is to C-x C-f
 'file.tex and then C-x C-w heading.tex .  I then typeset heading.tex
 using TeXworks. Perhaps I should note that my exported heading is tagged so
 that the heading is ignored.

 Charlie Millar

 ---
 This email is free from viruses and malware because avast! Antivirus
 protection is active.
 http://www.avast.com



 Use properties to set the export file name -- example:
   :PROPERTIES:
   :EXPORT_TITLE: Internet banking fraud
   :EXPORT_FILE_NAME: internet-fraud
   :EXPORT_AUTHOR: Alan L Tyree
   :Citation: (2011) 22 JBFLP 214
   :EXPORT_OPTIONS: num:nil toc:nil
   :END:

Thanks, gets me half the way there. Setting properties as you
described and exporting each sub-tree works properly. Now how can I do
this for all the top-level headings in a file?

Best,
Ista


 If I understood your question properly.

 Cheers,
 Alan



 --
 Alan L Tyreehttp://www2.austlii.edu.au/~alan
 Tel:  04 2748 6206  sip:typh...@iptel.org





Re: [O] Beamer export: one question and one bug

2013-11-03 Thread Ista Zahn
On Sun, Nov 3, 2013 at 5:06 AM, Jarmo Hurri jarmo.hu...@syk.fi wrote:

 Greetings.

 Set '#OPTIONS: H:2', then top level headlines become sections (and are
 listed in the table of contents) and second-level headlines become the
 frames.

 Yep, that will happen. However, the original idea was to get frame
 headlines into the table of contents.


As far as I know this is a beamer design decision. The idea seems to
be that if your presentation is short enough that the individual frame
titles would fit in a table of contents then you don't actually need
one; see the beamer user guide at
http://ctan.mackichan.com/macros/latex/contrib/beamer/doc/beameruserguide.pdf.

Best,
Ista

  In order to achieve this I would
 have to have H:2 and repeat the frame title as follows:

 # 
 #+TITLE: Beamer test
 #+OPTIONS: ':nil *:t -:t ::t :t H:2 \n:nil ^:t arch:headline
 #+OPTIONS: author:t c:nil creator:comment d:(not LOGBOOK) date:t e:t
 #+OPTIONS: email:nil f:t inline:t num:t p:nil pri:nil prop:nil stat:t
 #+OPTIONS: tags:t tasks:t tex:t timestamp:t toc:t todo:t |:t
 #+CREATOR: Emacs 24.2.1 (Org mode 8.2.1)
 #+DESCRIPTION:
 #+EXCLUDE_TAGS: noexport
 #+KEYWORDS:
 #+LANGUAGE: en
 #+SELECT_TAGS: export

 * This is the first slide
 ** This is the first slide
   - with some fancy text
 * And this is the second slide
 ** And this is the second slide
   - with one commented item...
 # 

 The output is correct, but requires duplication of information, which is
 practically always a bad idea.

 Jarmo





Re: [O] Beamer export: one question and one bug

2013-11-02 Thread Ista Zahn
On Mon, Oct 28, 2013 at 10:13 AM, Nick Dokos ndo...@gmail.com wrote:
 Jarmo Hurri jarmo.hu...@syk.fi writes:

 Greetings again.

 1. First the question: when I export the org file below as Beamer (C-c
C-e l O), I get an empty outline. How do I fix this?

 Seems to work fine for me with the older version that I was running,
 but I upgraded to latest and I get the beamer presentation I expected.

 I think I posed my initial question in a way that begs for a
 misunderstanding. When I export the file as Beamer, I get a title page,
 two slides _and_ an empty outline. Maybe someone interpreted my initial
 question to mean that I get _only_ an empty outline. I would like for
 the titles of the slides to appear in the outline. How do I achieve
 this?

 (I know that I can get rid of the outline by setting toc:nil.)


 Ah, indeed I misunderstood.

 AFAIK, toc-entries are created by \section{...} and the beamer exporter
 does not add \section headers - there might be a way to do that but I
 don't know it.

Set '#OPTIONS: H:2', then top level headlines become sections (and are
listed in the table of contents) and second-level headlines become the
frames. For example:

#+TITLE: Beamer test
#+OPTIONS: ':nil *:t -:t ::t :t H:2 \n:nil ^:t arch:headline
#+OPTIONS: author:t c:nil creator:comment d:(not LOGBOOK) date:t e:t
#+OPTIONS: email:nil f:t inline:t num:t p:nil pri:nil prop:nil stat:t
#+OPTIONS: tags:t tasks:t tex:t timestamp:t toc:t todo:t |:t
#+CREATOR: Emacs 24.2.1 (Org mode 8.2.1)
#+DESCRIPTION:
#+EXCLUDE_TAGS: noexport
#+KEYWORDS:
#+LANGUAGE: en
#+SELECT_TAGS: export

* This is the first section
** This is the first slide
   - with some fancy text

* This is the second section
** And this is the second slide
  - with one commented item...
#  - ... containing a [[https://www.google.com/#q%3Dorg%2Bmode][link]]
that will amaze the reader


Best,
Ista

 There also might be a beamer way of having frames add their title to the
 TOC without \section help, but again I don't know whether that's
 possible.

 Nick





Re: [O] Problem with beamer export

2013-10-09 Thread Ista Zahn
Any chance the fix can be pushed out to http://orgmode.org/elpa/?

Thanks,
Ista


On Mon, Oct 7, 2013 at 11:09 AM, Nicolas Goaziou n.goaz...@gmail.comwrote:

 Hello,

 Marvin Doyley marvin...@gmail.com writes:

  I just updated to Org 8.2.1 and for some reason when I export a frame I
 get
 
  \subsection{Title}
 
 
  rather than
 
  \begin{frame}{Title}
 
  \end{frame}
 
 
  Is this a bug or am I doing something wrong ?

 This is a bug I introduced recently. It should now be fixed.

 Thank you for reporting it.


 Regards,

 --
 Nicolas Goaziou




Re: [O] BUG?: BABEL - Release 8.2

2013-09-21 Thread Ista Zahn
I observe the same behavior with org installed from
elpa/org-plus-contrib-20130916.

Best,
Ista

On Sat, Sep 21, 2013 at 9:54 AM, Rainer M Krug rai...@krugs.de wrote:
 Just to reiterate - is this only me or others as well? I consider this
 as a serious problem, as it can result in loss of data.

 If it is only me, I have to dig deeper into my config.

 Cheers,

 Rainer

 Rainer M Krug rai...@krugs.de writes:

 Carsten Dominik carsten.domi...@gmail.com writes:


 Hi everyone,

 I have just released version 8.2 of Org mode.  This is rather a minor 
 release,
 mainly designed to do some stabilization and cleanup before the merge
 into Emacs.  Bastien will do this next week (?).

 Just upgraded, to 8.2 and I found a bug:

 When starting to edit a code block via C-c ' everything works as expected
 and the code block is highlighted and an indirect buffer is opened.

 When I click into the highlighted block, I an send to the indirect
 buffer. This behavior changes, after saving with C-s, even when nothing
 has been edited: the area in the original org file looses its magic, and
 looks normal again and can also be edited!

 he indirect buffer stays functional and, upon close vie C-c ' saves the
 changes into the original buffer and overwrites changes done in this block.

 Can somebody please confirm?

 Rainer
 #secure method=pgpmime mode=sign

 --
 Rainer M. Krug

 email: RMKrugatgmaildotcom





[O] ox-bibtex in contrib?

2013-07-31 Thread Ista Zahn
Hi all,

I have org-plus-contrib installed using elpa from
http://orgmode.org/elpa/, but this doesn't seem to include
ox-bibtex.el. Should it? Or does this need to be installed separately?

Thanks,
Ista



Re: [O] [RFC] BibELTeX: native bibtex support in org-mode

2013-06-12 Thread Ista Zahn
On Wed, Jun 12, 2013 at 6:48 AM, Rüdiger Sonderfeld
ruedi...@c-plusplus.de wrote:
 Rasmus rasmus at gmx.us writes:


 Rüdiger Sonderfeld ruediger at c-plusplus.de writes:

  I've started writing BibELTeX as an alternative to =ox-bibtex.el=.
 
  https://github.com/ruediger/bibeltex

 Would you consider providing a test file showing off its features?

 I added a file test/example.org.  Put bibeltex.el somewhere in your load-path
 and require it.  This should be enough to make it work (use unload-feature to
 remove it again).

 You can then export the document to any format you like.  Good test case is
 using org-mode export (ox-org.el).

Thank you for this, I've been waiting for this capability a long time.
I look forward to giving it a more through test!

Best,
Ista



 I'm skeptical but probably it is 'cause I've misunderstood something!
 Someone put a lot of thought into writing e.g. biblatex or
 odt-bibliographies.  Surely(?) we would want to leverage upon those
 and only have org-support insofar as serving some backend-specific
 parser enough information to do its work?

 Certainly.  BibELTeX is designed to do this.  For LaTeX export it just
 generates the corresponding LaTeX instructions (can be adopted even for
 biblatex).

 But except for LaTeX there doesn't seem to be a real support for bibliography.
 It can be simulated for html using bibtex2html (ox-bibtex.el).  But even that
 is not compatible with biber/biblatex.  That's the reason behind BibELTeX.

 Regards





Re: [O] Examples of orgmode+beamer presentations?

2013-04-15 Thread Ista Zahn
I'm not clear on whether you are looking for templates or examples,
but if the later, maybe my slides at
http://projects.iq.harvard.edu/rtc/event/introduction-r will be of
some interest. Scroll down to the bottom and download the .zip file.
The rintro.pdf is the beamer export of the rintro.org file.

HTH,
Ista

On Mon, Apr 15, 2013 at 11:18 AM, Angel de Vicente ang...@iac.es wrote:
 Hi,

 I'm trying to find examples of presentations made with orgmode and
 beamer. Ideally I would like to see sample presentations first (in PDF),
 so that I can get one that looks as close to what I would need, and then
 I would like to get the source code for it. Are there any good templates
 out there? (Something similar to
 http://draketo.de/light/english/politics-and-free-software/recipes-presentations-beamer-latex-using-emacs-org-mode,
 but hopefully with more options).

 Is there anything out there?

 Thanks,
 --
 Ángel de Vicente
 http://angel-de-vicente.blogspot.com/





Re: [O] python sessions

2013-03-25 Thread Ista Zahn
On Mon, Mar 25, 2013 at 11:40 AM, Eric Schulte schulte.e...@gmail.com wrote:
 John Hendy jw.he...@gmail.com writes:

 On Sun, Mar 24, 2013 at 9:38 PM, Nick Dokos nicholas.do...@hp.com wrote:
 Eric Schulte schulte.e...@gmail.com wrote:

 
  From participating in evaluating code throughout the discussion and
  catching the comments throughout, I'd say yes, at least in terms of
  how other babel languages function. In other words =#+begin_src R
  :session foo= creates an R session named foo whereas doing the same
  with =python= instead of =R= does not yield a named session.
 
  From what others experienced, however, the functionality was working
  correctly (results were persistent across blocks and two differently
  names blocks created two different sessions), just not named
  correctly.
 

 See the cond form starting at line 169 in ob-python.el.  Different
 session functionality is used based on the `org-babel-python-mode'
 variable, and on the version of Emacs in use (prior to 24.1 or not).

 The branch taken when `org-babel-python-mode' equals 'python is
 certainly broken, as it never saves the name of the newly created
 buffer, so session re-use and use of multiple named sessions probably
 works only when `org-babel-python-mode' equals 'python-mode.


 That's me: org-babel-python-mode's value is python, so it's no wonder
 it's broken given what Eric says. I'm on emacs 24.3.50 where there is
 python.el but no python-mode.el. I tried the cheap workaround of
 switching the value to python-mode, but that does a (require
 'python-mode) somewhere, so that option is out as well.

 I'm on Emacs 24.3.1 and have no python-mode.el, either (only
 python.el). My setup is working correctly (again, with the caveat of
 not having named sessions).


 It sounds like we have the same setup, and the following un-named
 session example does not work for me.  The first code block evaluates
 successfully, but it doesn't appear to be having any impact on the
 default session (e.g., in the *Python* buffer).

 Returns the value of x as expected.

 #+begin_src python :session
   x = 1
   return x
 #+end_src

 #+RESULTS:
 : 1

 #+begin_src python :session
   return x
 #+end_src

 #+RESULTS:

 The second code block /should/ have access to the x variable defined
 previous, but instead it throws an error because x is undefined.

 Currently I'd say session support for python is completely broken.

As of this morning I've joined the it does not work crowd. Python
sessions worked for me last week, but are now completely broken for me
in the way Eric and others describe.

Best,
Ista


 --
 Eric Schulte
 http://cs.unm.edu/~eschulte




Re: [O] python sessions

2013-03-25 Thread Ista Zahn
On Mon, Mar 25, 2013 at 1:41 PM, John Hendy jw.he...@gmail.com wrote:
 On Mon, Mar 25, 2013 at 12:27 PM, Andreas Röhler
 andreas.roeh...@easy-emacs.de wrote:
 Am 25.03.2013 17:43, schrieb Eric Schulte:

 John Hendy jw.he...@gmail.com writes:

 On Mon, Mar 25, 2013 at 11:01 AM, Ista Zahn istaz...@gmail.com wrote:

 On Mon, Mar 25, 2013 at 11:40 AM, Eric Schulte schulte.e...@gmail.com
 wrote:

 John Hendy jw.he...@gmail.com writes:

 On Sun, Mar 24, 2013 at 9:38 PM, Nick Dokos nicholas.do...@hp.com
 wrote:

 Eric Schulte schulte.e...@gmail.com wrote:


  From participating in evaluating code throughout the discussion
 and
 catching the comments throughout, I'd say yes, at least in terms of
 how other babel languages function. In other words =#+begin_src R
 :session foo= creates an R session named foo whereas doing the
 same
 with =python= instead of =R= does not yield a named session.

  From what others experienced, however, the functionality was
 working
 correctly (results were persistent across blocks and two
 differently
 names blocks created two different sessions), just not named
 correctly.


 See the cond form starting at line 169 in ob-python.el.  Different
 session functionality is used based on the `org-babel-python-mode'
 variable, and on the version of Emacs in use (prior to 24.1 or not).

 The branch taken when `org-babel-python-mode' equals 'python is
 certainly broken, as it never saves the name of the newly created
 buffer, so session re-use and use of multiple named sessions
 probably
 works only when `org-babel-python-mode' equals 'python-mode.


 That's me: org-babel-python-mode's value is python, so it's no wonder
 it's broken given what Eric says. I'm on emacs 24.3.50 where there is
 python.el but no python-mode.el. I tried the cheap workaround of
 switching the value to python-mode, but that does a (require
 'python-mode) somewhere, so that option is out as well.


 I'm on Emacs 24.3.1 and have no python-mode.el, either (only
 python.el). My setup is working correctly (again, with the caveat of
 not having named sessions).


 It sounds like we have the same setup, and the following un-named
 session example does not work for me.  The first code block evaluates
 successfully, but it doesn't appear to be having any impact on the
 default session (e.g., in the *Python* buffer).

  Returns the value of x as expected.

  #+begin_src python :session
x = 1
return x
  #+end_src

  #+RESULTS:
  : 1

  #+begin_src python :session
return x
  #+end_src

  #+RESULTS:

 The second code block /should/ have access to the x variable defined
 previous, but instead it throws an error because x is undefined.

 Currently I'd say session support for python is completely broken.


 As of this morning I've joined the it does not work crowd. Python
 sessions worked for me last week, but are now completely broken for me
 in the way Eric and others describe.


 Interesting... checked out back to that commit
 (eff59a15d76647ce8282626b9eb463dc3706d56e) and it still doesn't work.
 On a whim, I checked my pacman log (Arch's install system) and
 coincidentally on Mar 20 /after/ I wrote that post in which things
 work, I ran a system package update.

 $ grep -i emacs /var/log/pacman.log

 [2013-03-20 12:51] upgraded emacs (24.2-4 - 24.3-1)

 Using the Arch Rollback Machine, I downloaded Emacs 24.2.4 and
 downgraded (also required downgrading imageMagick from 6.8.3.10 -
 6.8.2.3). Now it works again (refer to the reproducible example from
 the mailing list post):
 - http://www.mail-archive.com/emacs-orgmode@gnu.org/msg68238.html

 Eric, your example fails for me. I get:


 Yes, because my example only works in external (non session) execution
 with the current buggy code, where as your example works with session
 execution in the old working code.


 x = 1
 return x

File stdin, line 1
 SyntaxError: 'return' outside function

 This works, hoever:

 #+begin_src python :session
x = 1
x
 #+end_src

 #+RESULTS:
 : 1

 #+begin_src python :session
x
 #+end_src

 #+RESULTS:
 : 1

 So, with emacs 24.2.4 and current Org-mode (pulled just now) and clean
 make, *both* named and un-named sessions work for me on Arch Linux.


 Aha! Thanks for sleuthing this out.  So the problem lies in changes to
 the python.el distributed with Emacs.  I don't suppose we can ask
 whoever made these changes to python.el to fix the breakage they've
 caused in Org-mode?

 Thanks,


 Please give me some time still to investigate. Still doubt it's python.el
 But if yes, probably will be able to tell more.

 Possibly, but know that for me it works with one Emacs version and not
 another, both using the same git version of Org and same minimal
 config/setup/test file. Perhaps those affected here should post their
 Emacs versions?

Worked for me last week with emacs 24.2.1 and org 8.0-pre
(release_8.0-pre-54-gb5a853. Not working now with emacs 24.3.1 and org
8.0-pre

Re: [O] python sessions

2013-03-20 Thread Ista Zahn
On Wed, Mar 20, 2013 at 2:44 AM, Andreas Röhler
andreas.roeh...@easy-emacs.de wrote:
 Am 20.03.2013 04:07, schrieb Nick Dokos:

 John Hendy jw.he...@gmail.com wrote:

 On Tue, Mar 19, 2013 at 4:40 PM, Gary Oberbrunner ga...@oberbrunner.com
 wrote:

 I must be failing to understand something.  I'm running Emacs 24.3 on
 Windows, with latest trunk org-mode.  I can't get python functions to
 persist across blocks in session mode.  Here's my foo.org:

 ===

 * My Document
 #+BEGIN_SRC python :exports results :results output :session
 def foo(x):
return x+1
 print hi
 #+END_SRC

 #+RESULTS:
 : hi

 #+BEGIN_SRC python :exports results :results output :session
 print foo(100)
 print bye
 #+END_SRC

 

 In session mode, shouldn't foo be defined in the second python block?
 When
 I export this, I get NameError: name 'foo' is not defined

 I may be doing something wrong, because if I name my python session, I
 never
 see a buffer of that name, and I expected to.  Any help?

 --
 Gary


 You should probably post your babel configuration from .emacs. This
 works for me (mostly). I'm using python 3.3 and so the print function
 has changed to requiring parentheses. I can switch to a buffer called
 *Python*, however, and =print(hi)= works fine.

 If I change to =print(foo(100))=, I get 101 in the #+RESULTS block.


 I don't - I get the same error as Gary.

 And looking at the code of org-babel-python-initiate-session-by-key,
 I don't understand how it's supposed to work: python-buffer is nil
 to begin with; the cond takes the first branch and starts a python
 session.
 When we come to

(setq org-babel-python-buffers
 (cons (cons session python-buffer)
   (assq-delete-all session org-babel-python-buffers)))

 python-buffer is still nil, so we are cooked.

 Maybe python-buffer was set as a side-effect of run-python in earlier
 versions of emacs? If so, it does not seem to be the case now.

 Nick

 Org-mode version 8.0-pre (release_8.0-pre-144-g855dcf.dirty @
 /home/nick/elisp/org-mode/lisp/)
 GNU Emacs 24.3.50.2 (x86_64-unknown-linux-gnu, GTK+ Version 2.24.4) of
 2012-12-29 on alphaville



 AFAIU :session is broken, because Python shell as opened by run-python or
 py-shell isn't used by ob-babel.
 Seems ob-babel sends it's code w/ an own shell command, thus opening a new
 python shell internally every time.

 Did :session ever work? Then I might be wrong with this comment.

Not only did it work, it currently works for me. I seem to remember
bad interaction with python modes other than the one shipped with
emacs. In my .emacs I have

;; Python
;; there are several modes. Currently using
https://github.com/fgallina/python.el
;; hopefully oneday a glorious default python mode will be shipped
with emacs and we won't need this anymore.

;; (add-to-list 'load-path ~/.emacs.d/izahn)
;; (require 'python)

;; (setq
;;  python-shell-interpreter ipython
;;  python-shell-interpreter-args 
;;  python-shell-prompt-regexp In \\[[0-9]+\\]: 
;;  python-shell-prompt-output-regexp Out\\[[0-9]+\\]: 
;;  python-shell-completion-setup-code
;;from IPython.core.completerlib import module_completion
;;  python-shell-completion-module-string-code
;;';'.join(module_completion('''%s'''))\n
;;  python-shell-completion-string-code
;;';'.join(get_ipython().Completer.all_completions('''%s'''))\n)

;; (require 'python-mode) ;;

;; python auto completion
(require 'ac-python)

All the python-mode and ipython mode stuff is commented out partly
because it did not play nice with org-mode. Using the default python
mode works for me. So, for those of you who are finding that this is
not working, what python mode are you using?

Best,
Ista


 Andreas






Re: [O] python sessions

2013-03-20 Thread Ista Zahn
On Wed, Mar 20, 2013 at 2:15 PM, Nick Dokos nicholas.do...@hp.com wrote:
 John Hendy jw.he...@gmail.com wrote:

 On Wed, Mar 20, 2013 at 12:25 PM, Nick Dokos nicholas.do...@hp.com wrote:
  Andreas Röhler andreas.roeh...@easy-emacs.de wrote:
 
  Seems `org-babel-execute':python doesn't get the session flag.
 
  Edebug: org-babel-execute:python
  org-babel-execute:python
  executing Python code block...
   [4 times]
  Result: ((:comments . #1=) (:shebang . #1#) (:cache . no)
  (:padline . #1#) (:noweb . no) (:tangle . no) (:exports
  . results) (:results . replace output) (:hlines . no)
  (:padnewline . yes) (:session) (:result-type . output)
 
  Sure it does:   ^^
 
  What it does with it is another matter however. Am I missing something?

 I was thinking the concern was over not having the session named
 properly, but might be wrong (Andreas could confirm).


 I guessed Andreas tried with an unnamed session (but I agree it would be
 best if he confirms): afaics, if I use a session name, it's passed
 correctly in the params argument of org-babel-execute:python as
 (:session . foo), but in the later processing,
 org-babel-python-buffers is not set correctly.

 I've not used python prior to this, but I use R almost daily in Org
 and if I do #+begin_src R :session R, I get a buffer actually named
 =R=. In this case, I expected the buffer name would be *PyFoo*.
 Checking if it was an issue with asterisks, I used =:session py= and
 still just get the default *Python* buffer created.


 Yes, I think it's ob-python's problem: but as I said before, I don't
 understand why it works for you (and Ista Zahn).

I guess it depends on the definition of works. I don't get python
buffers with the name of the :session variable. But I do get separate
python buffers (.e.g., *Python*, *Python*2) for each session, and
python blocks get executed in the right python process. To me that
equals works, but if the issue is that the buffers don't get named
with the value of :session then no, that doesn't work for me either.

Best,
Ista


 Nick






Re: [O] python sessions

2013-03-20 Thread Ista Zahn
On Wed, Mar 20, 2013 at 2:43 PM, Andreas Röhler
andreas.roeh...@easy-emacs.de wrote:

 I guess it depends on the definition of works. I don't get python
 buffers with the name of the :session variable.


 Reads as it works only with named sessions, but fails with unnamed

It fails to name the python process buffers. Everything else works as
expected. Consider this example:

8-cut here8
#+BEGIN_SRC python :exports results :results output :session *foo*
  def foo(x):
return(x+1)

#+END_SRC

#+RESULTS:


#+BEGIN_SRC python :exports results :results output :session *bar*
  def bar(x):
return(x+2)

#+END_SRC

#+RESULTS:

#+BEGIN_SRC python :exports results :results output :session *foo*
  print(foo(100))
  print(bar(100))

#+END_SRC

#+RESULTS:
: 101
: Traceback (most recent call last):
:   File stdin, line 1, in module
: NameError: name 'bar' is not defined

#+BEGIN_SRC python :exports results :results output :session *bar*
  print(foo(100))
  print(bar(100))

#+END_SRC

#+RESULTS:
: Traceback (most recent call last):
:   File stdin, line 1, in module
: NameError: name 'foo' is not defined
: 102

8-cut here8

the foo function exists when I use :session foo (and not with :session
bar), and the bar function exists when I uses :session bar (and not
with :session foo). That equals works in my book. The only thing
that doesn't work is that I have buffers

. * tmp.org   1657  Org   ~/Desktop/tmp.org
  * *Python*2332  Inferior Python:
  * *Python*   332  Inferior Python:

instead of

. * tmp.org   1657  Org   ~/Desktop/tmp.org
  * *foo*  332  Inferior Python:
  * *bar*  332  Inferior Python:

This is with GNU Emacs 24.2.1 and Org-mode version 8.0-pre
(release_8.0-pre-54-gb5a853

Best,
Ista



  But I do get separate

 python buffers (.e.g., *Python*, *Python*2) for each session, and
 python blocks get executed in the right python process. To me that
 equals works, but if the issue is that the buffers don't get named
 with the value of :session then no, that doesn't work for me either.

 Best,
 Ista


 Nick










Re: [O] python sessions

2013-03-20 Thread Ista Zahn
On Wed, Mar 20, 2013 at 3:53 PM, Andreas Röhler
andreas.roeh...@easy-emacs.de wrote:
 Am 20.03.2013 20:42, schrieb Ista Zahn:

 On Wed, Mar 20, 2013 at 2:43 PM, Andreas Röhler
 andreas.roeh...@easy-emacs.de wrote:


 I guess it depends on the definition of works. I don't get python
 buffers with the name of the :session variable.



 Reads as it works only with named sessions, but fails with unnamed

Oops, sorry I totally misread this before. I guess my last email
didn't make much sense!



 It fails to name the python process buffers.


 May you try still an unnamed session as sent by OP?

Unnamed sessions works as expected:


#+BEGIN_SRC python :exports results :results output :session
  def foo(x):
return(x+1)

#+END_SRC

#+RESULTS:


#+BEGIN_SRC python :exports results :results output :session
  def bar(x):
return(x+2)

#+END_SRC

#+RESULTS:

#+BEGIN_SRC python :exports results :results output :session
  print(foo(100))
  print(bar(100))

#+END_SRC

#+RESULTS:
: 101
: 102



 Andreas




Re: [O] python sessions

2013-03-20 Thread Ista Zahn
On Wed, Mar 20, 2013 at 4:25 PM, Gary Oberbrunner ga...@oberbrunner.com wrote:
 Ista, what OS are you on?  Maybe this (or part of it anyway) is only a
 Windows problem?

Maybe -- I'm on Arch Linux.



 On Wed, Mar 20, 2013 at 4:12 PM, Ista Zahn istaz...@gmail.com wrote:

 On Wed, Mar 20, 2013 at 3:53 PM, Andreas Röhler
 andreas.roeh...@easy-emacs.de wrote:
  Am 20.03.2013 20:42, schrieb Ista Zahn:
 
  On Wed, Mar 20, 2013 at 2:43 PM, Andreas Röhler
  andreas.roeh...@easy-emacs.de wrote:
 
 
  I guess it depends on the definition of works. I don't get python
  buffers with the name of the :session variable.
 
 
 
  Reads as it works only with named sessions, but fails with unnamed

 Oops, sorry I totally misread this before. I guess my last email
 didn't make much sense!

 
 
  It fails to name the python process buffers.
 
 
  May you try still an unnamed session as sent by OP?

 Unnamed sessions works as expected:


 #+BEGIN_SRC python :exports results :results output :session
   def foo(x):
 return(x+1)

 #+END_SRC

 #+RESULTS:


 #+BEGIN_SRC python :exports results :results output :session
   def bar(x):
 return(x+2)

 #+END_SRC

 #+RESULTS:

 #+BEGIN_SRC python :exports results :results output :session
   print(foo(100))
   print(bar(100))

 #+END_SRC

 #+RESULTS:
 : 101
 : 102


 
  Andreas
 




 --
 Gary



Re: [O] posting guide?

2013-03-13 Thread Ista Zahn
+1

On Wed, Mar 13, 2013 at 3:13 PM, Jay Kerns gjkerns...@gmail.com wrote:
 The past few days have reminded me of something somebody famous
 once said [1]. I can already see work being done to protect the
 community for the future, yet I believe there is more we might do
 to be even stronger.

 I understand and appreciate Bastien's stated position regarding
 moderator controls [2], and in that particular case I think he
 did the right thing. At the same time, I do not possess his
 seemingly superhuman level of patience, temperance, and couth.

 Yes, I can add people to my SPAM filter (which I did, BTW), but
 that action protects only *me*.  It does not protect the
 community. Further, my later blissful ignorance means I am
 unavailable to respond to future threats, so malicious
 individuals are left to run rampant and destroy everybody else
 still hanging around.  Of course, if *everybody* agrees to divert
 to SPAM then we're all set.

 That's my point: I propose that we, as a community, come to some
 sort of consensus as to what un/acceptable behavior is and an
 accepted mechanism of response.  One way to accomplish this is
 with a posting guide. I have some thoughts about this:

 1. It should be written and maintained by the community. On
 Worg, for instance.

 2. It should be minimal. Posting guides sometimes go overboard,
 to the extent that they can be (and sometimes are) used as a
 weapon.  I do *not* propose that.  If we insist on 1) then I
 trust the community to handle it with care.

 3. It should contain things which help new users draft messages
 that are informative and targeted to whatever problem they're
 having, things they might not have known otherwise (things like
 M-x org-version, M-x toggle-debug-on-error, etc.).

 4. I think we can all agree that messages like this [3] should
 not be tolerated, ever, under any circumstances.  If a person
 resorts to ad hominem attacks of this sort (or similar)
 then (s)he should promptly be shown the door.  Period.  As far as
 I am concerned, that's pretty much the only thing I can't
 stomach, but maybe the larger community considers other subjects
 to be off-topic or unwelcome on the list.  That would be for the
 community to decide.


 All the above is a long-winded way to say that every community
 has some /minimum/ standards and expectations of conduct,
 otherwise we're just a bunch of people standing around in the
 same (virtual) place.  To date, these expectations have lived
 unspoken or scattered around in emails here or there.  I propose
 that we come together in a community-driven way to define when
 it's time to say Welcome! and when it's time to say, Get
 lost.

 I understand that there are valid arguments against posting
 guides, not the least of which including what I said above in 2).
 Maybe this community doesn't want a posting guide.  OK.  But even
 in that case we've at least agreed that we don't want a posting
 guide and can get back to work.

 If we *do* decide that a minimal posting guide makes sense, then
 it wouldn't be of much use unless there are those among us willing
 to enforce it when individuals maliciously disregard the
 agreement of the community.  I would probably have been one of
 those people had I known there was some consensus about what is
 OK and what isn't.  Now is the time to decide.


 I have a mental first draft of things that could go in one, but
 there's no point moving forward if there isn't a general feeling
 that this would be something good to do.  And, I'd like the Org
 old-timers to feel free to take the reins and run with it if they
 so choose.

 Cheers,

 --
 Jay

 [1] http://www.quotes.net/quote/2101
 [2] http://lists.gnu.org/archive/html/emacs-orgmode/2013-03/msg00449.html
 [3] http://lists.gnu.org/archive/html/emacs-orgmode/2013-03/msg00747.html

 --
 G. Jay Kerns, Ph.D.
 Youngstown State University
 http://people.ysu.edu/~gkerns/




Re: [O] BUG org-babel-execute-src-block: No org-babel-execute function for python!

2013-02-26 Thread Ista Zahn
On Tue, Feb 26, 2013 at 10:42 AM, Andreas Röhler
andreas.roeh...@easy-emacs.de wrote:
 Am 26.02.2013 14:49, schrieb Bastien:

 Hi Andreas,

 Andreas Röhler andreas.roeh...@easy-emacs.de writes:

 org-babel-execute-src-block: No org-babel-execute function for python!

 When evaluating the following block C-c C-c starting from emacs -Q


 You need

 (org-babel-do-load-languages
   'org-babel-load-languages
   '((python . t)))

 See (info (Org)Languages)

 HTH,


 Bugs exists after loading that.

What is the nature of the bugs?

 Please tell if you need more info.

what is the result of 'M-x org-version'?

Also, try this simple test and report the results:
1. start emaces with emacs -q
2. visit a new file with a .org extension, e.g., tmp.org
3. paste this in:
8cut here8
Place cursor in the code block below and press C-c C-c

#+begin_src emacs-lisp :exports none
  (org-babel-do-load-languages
   'org-babel-load-languages
   '((python . t)))
#+end_src

#+BEGIN_SRC python :results output
a = 5
b = 16
print(a + b)
#+END_SRC
8cut here8
4. place the cursor inside the first code block and press C-c C-c
5. place the cursor inside the second code block and press C-c C-c
6. let us know what happens

Best,
Ista



 Andreas




Re: [O] org-export-babel-evaluate and :exports none

2013-02-22 Thread Ista Zahn
On Fri, Feb 22, 2013 at 3:49 PM, Achim Gratz strom...@nexgo.de wrote:
 Nicolas Goaziou writes:
 I'm just starting over because that wasn't a correct solution. I'm not
 even sure about what bug this patch fixed.

 The bug was that Babel blocks were evaluated during export when
 org-export-babel-evaluate was explicitly set to nil (the default value
 is t).

FWIW, I have not experienced this bug. I always set
org-export-babel-evaluate to nil, and this has always had the desired
effect of preventing babel evaluation on export.

Best,
Ista


 Anyway, it isn't org-export-babel-evaluate's job to tell when to
 evaluate a source code block.

 The documentation says that its job is exactly that, if the context is
 export.

 --8---cut here---start-8---
 Documentation:
 Switch controlling code evaluation during export.
 When set to nil no code will be evaluated as part of the export
 process.
 --8---cut here---end---8---

 It may be org-babel-exp-process-buffer's.

 You call org-export-execute-babel-code however, which doesn't check the
 above variable.

 BTW, the function org-export-execute-babel-code is called before it is
 being defined.  Not sure why this doesn't give a warning.

 Why should it? It's not a macro, after all.

 Ah yes.  To much C++ the last month.


 Regards,
 Achim.
 --
 +[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]+

 Factory and User Sound Singles for Waldorf Q+, Q and microQ:
 http://Synth.Stromeko.net/Downloads.html#WaldorfSounds





Re: [O] org-export-babel-evaluate and :exports none

2013-02-19 Thread Ista Zahn
On Mon, Feb 18, 2013 at 3:17 PM, Nicolas Goaziou n.goaz...@gmail.com wrote:
 Hello,

 Ista Zahn istaz...@gmail.com writes:

 Thanks for checking Jay. I just tried with make update2 (usually I use
 make update), with the same result as I got before (i.e., the code
 block is exported). Just to make sure -- you ran the test with emacs
 -q right?

 Anybody else try this?
 Thanks!
 Ista

 I confirm the problem. It is coming from
 12d592b73223f3b0628e10f0f627447b1a312203. I reverted it.

I confirm it is now working as expected. Thank you!
-Ista


 Thanks you.


 Regards,

 --
 Nicolas Goaziou



Re: [O] org-export-babel-evaluate and :exports none

2013-02-18 Thread Ista Zahn
Hi all,

Just checking to see if anyone was able to reproduce this or if I am
the only one with this problem.

Thanks,
Ista

On Sun, Feb 17, 2013 at 9:24 AM, Ista Zahn istaz...@gmail.com wrote:
 Hi,

 I upgraded to the latest git version yesterday, and am loving the new
 exporter. Congrats to all involved!

 However, when I set org-export-babel-evaluate to nil the new latex
 exporter (I have not tried the others) ignores :exports none source
 block header arguments. To reproduce:

 1. start emacs with 'emacs -q' and visit a file named tmp.org with the
 following contents:
 start org example

 #+TITLE: Source block export test

 * Source block export

 #+name: test
 #+begin_src emacs-lisp :exports none :results silent :tangle no
   ;should not be exported but is
 (setq org-export-babel-evaluate nil)
 #+end_src

 /end org example

 2. place the point inside the test block and press 'C-c-c' to evaluate it
 3. export to latex file with 'C-e l l'

 the resulting tmp.tex incorrectly contains

 \begin{verbatim}
 ;should not be exported but is
   (setq org-export-babel-evaluate nil)
 \end{verbatim}

 If this is an error on my part please correct my examples! Otherwise
 please consider this a bug report. 'M-x org-version' reports Org-mode
 version 7.9.3e (7.9.3e-1107-g45442f @
 /usr/share/emacs/site-lisp/org/) on my system, which I believe to be
 the latest.

 Best,
 Ista



Re: [O] org-export-babel-evaluate and :exports none

2013-02-18 Thread Ista Zahn
On Mon, Feb 18, 2013 at 1:59 PM, Jay Kerns gjkerns...@gmail.com wrote:
 Dear Ista,


 On Mon, Feb 18, 2013 at 1:22 PM, Ista Zahn istaz...@gmail.com wrote:
 Hi all,

 Just checking to see if anyone was able to reproduce this or if I am
 the only one with this problem.

 Thanks,
 Ista

 I just make update2'ed, followed your recipe, but my tmp.tex did not
 incorrectly have the exported source block.  So, I guess I can't
 reproduce, unfortunately.

Thanks for checking Jay. I just tried with make update2 (usually I use
make update), with the same result as I got before (i.e., the code
block is exported). Just to make sure -- you ran the test with emacs
-q right?

Anybody else try this?
Thanks!
Ista


 --
 Jay Kerns



Re: [O] org-odt: command line options for soffice bug?

2013-02-18 Thread Ista Zahn
On Mon, Feb 18, 2013 at 3:49 PM, Vinh Nguyen vinhdi...@gmail.com wrote:
 On Sat, Feb 16, 2013 at 2:33 PM, Vinh Nguyen vinhdi...@gmail.com wrote:
 Hi,

 I was having issues exporting to a doc file with this in my init file:
 (setq org-export-odt-preferred-output-format doc)

 After some debugging, it appears my soffice command takes a single
 dash (-), not double dash (--) for command line arguments.  When I
 change to

 soffice -headless -convert-to %f%x -outdir %d %i

 in org-odt.el, things seem to work.  I am running org-mode 7.9.3e on
 Emacs 24.1.50.1 and LibreOffice 3.3.4 on Ubuntu 11.04.  Not sure if
 this is specific to me or not, but it should be fixed in org-mode.
 Thanks!


 Just checked LibreOffice on my Mac OS X, and it uses two dashes for
 arguments.  Weird that LibreOffice on Ubuntu uses one dash.  Can
 anyone else confirm?  I guess the emacs function should determine the
 current OS to decide whether to use single or double dash for command
 line arguments...

LibreOffice 3.6 on archlinux uses double dash.

-Ista


 -- Vinh




[O] org-export-babel-evaluate and :exports none

2013-02-17 Thread Ista Zahn
Hi,

I upgraded to the latest git version yesterday, and am loving the new
exporter. Congrats to all involved!

However, when I set org-export-babel-evaluate to nil the new latex
exporter (I have not tried the others) ignores :exports none source
block header arguments. To reproduce:

1. start emacs with 'emacs -q' and visit a file named tmp.org with the
following contents:
start org example

#+TITLE: Source block export test

* Source block export

#+name: test
#+begin_src emacs-lisp :exports none :results silent :tangle no
  ;should not be exported but is
(setq org-export-babel-evaluate nil)
#+end_src

/end org example

2. place the point inside the test block and press 'C-c-c' to evaluate it
3. export to latex file with 'C-e l l'

the resulting tmp.tex incorrectly contains

\begin{verbatim}
;should not be exported but is
  (setq org-export-babel-evaluate nil)
\end{verbatim}

If this is an error on my part please correct my examples! Otherwise
please consider this a bug report. 'M-x org-version' reports Org-mode
version 7.9.3e (7.9.3e-1107-g45442f @
/usr/share/emacs/site-lisp/org/) on my system, which I believe to be
the latest.

Best,
Ista



Re: [O] OT, but not really: todays XKCD

2013-02-12 Thread Ista Zahn
On Tue, Feb 12, 2013 at 10:10 AM, Jambunathan K kjambunat...@gmail.com wrote:
 Bastien b...@altern.org writes:

 It's important for two reasons: to keep a nice atmosphere on the list,
 so that people feel comfortable asking stupid questions; and to let
 other developers focus on their work (while you try to help newbies
 with their problems).  It would have been difficult for you to focus
 on the ODT exporter or to Nicolas to focus on the new export engine
 if I didn't put enough energy to maintain the whole beast.

 Last line is comical.  It reminds me of name Dilbert, for reason I
 cannot fathom.  The worth of managers is over-estimated, particularly
 when the estimation is done by managers themselves.

I dislike this kind of negativity, so I've added you to my spam filter. Bye bye.

-Ista



Re: [O] New exporter (org-e-odt) not creating content.xml

2012-11-28 Thread Ista Zahn
On Wed, Nov 28, 2012 at 10:15 AM, Giovanni Ridolfi
giovanni.rido...@yahoo.it wrote:
 Da: Ista Zahn istaz...@gmail.com
 Inviato: Martedì 27 Novembre 2012 15:55

 I can't seem to get the new odt exporter working on my Windows machine
 at work (it works fine on Linux at home).
 [...]

 So it seems that the new exporter is not creating content.xml, or
 META-INF/manifest.xml. Again this only happens on Windows. It is
 reproducible every time, and is reproducible starting with emacs -q
 and then loading only org and org-e-odt.


 Specifically, when I call
 'M-x export-dispatch o o'  I get an odt archive with the following
 contents.

 M Filemode  Length  Date Time  File
- --    ---    --
  -rw-rw-rw-39  26-Nov-2012  17:31:16  mimetype
  drwxrwxrwx 0  26-Nov-2012  17:31:16  meta-inf/
  -rw-rw-rw-   782  26-Nov-2012  17:31:16  meta.xml
  -rw-rw-rw- 66559  26-Nov-2012  17:31:16  styles.xml
- --    ---    --
 67380 4 files

 Like Rainer I cannot reproduce.

 what is
 -  your org-version ?
 'M-org-version' produces

 Org-mode version N/A (N/A @ c:/Documents and
 Settings/IZAHN/.emacs.d/izahn/org-mode/lisp/)

 but this is orgmode from git, updated yesterday.
 well I cannot trust you ;-)

 I think you did not configure/build org properly (Achim may confirm here).

 Please read the documentation (M-x org-info)

Yes, I've read the documentation.

 and the worg page here:

 http://orgmode.org/worg/org-hacks.html

Is that really necessary? I keep org updated using the instructions at
http://orgmode.org/worg/org-faq.html#keeping-current-with-Org-mode-development.
ad hoc code, quick hacks and workarounds does not sound like what I
want...


 and please, configure org properly.

The only thing I see that I missed is make autoloads, and indeed
after running this I get a sensible org-version:

Org-mode version 7.9.2 (release_7.9.2-638-g09cfdb @
/Users/izahn/.emacs.d/izahn/org-mode/lisp/)

Then we can investigate if this behaviour is
 really a bug or is it due to misconfiguration.

Fair enough. Unfortunately I'm not at my Windows machine today, so I
can't test to see if 'make autoloads' changed anything.

Best,
Ista


 -  emacs version?
 GNU Emacs 24.2.1 (i386-mingw-nt5.1.2600) of 2012-08-28 on MARVIN
  emacs is the windows version fromhttp://ftp.gnu.org/gnu/emacs/windows/

 The OS is Windows XP professional with service pack 3.

 Here:
 Org-mode version 7.9.2 (d344fda @
 GNU Emacs 24.2.1 (i386-mingw-nt6.1.7601) of 2012-08-29 on MARVIN
 Windows 7

 Same as me.
 Please check your configuration/activation.

 I started emacs with emacs -q and evaluated the following lines with 'C-x-e':
 Is is not useful if you have not configured/activated org.


 cheers,
 Giovanni



Re: [O] New exporter (org-e-odt) not creating content.xml

2012-11-27 Thread Ista Zahn
Hi all,

On Tue, Nov 27, 2012 at 3:40 AM, Giovanni Ridolfi
giovanni.rido...@yahoo.it wrote:
 Hi, Ista,


 Da: Ista Zahn istaz...@gmail.com
 Inviato: Lunedì 26 Novembre 2012 23:44

 I can't seem to get the new odt exporter working on my Windows machine
 at work (it works fine on Linux at home).
 [...]

 So it seems that the new exporter is not creating content.xml, or
 META-INF/manifest.xml. Again this only happens on Windows. It is
 reproducible every time, and is reproducible starting with emacs -q
 and then loading only org and org-e-odt.



 Specifically, when I call
 'M-x export-dispatch o o'  I get an odt archive with the following
 contents.

 M Filemode  Length  Date Time  File
- --    ---    --
  -rw-rw-rw-39  26-Nov-2012  17:31:16  mimetype
  drwxrwxrwx 0  26-Nov-2012  17:31:16  meta-inf/
  -rw-rw-rw-   782  26-Nov-2012  17:31:16  meta.xml
  -rw-rw-rw- 66559  26-Nov-2012  17:31:16  styles.xml
- --    ---    --
 67380 4 files

 Like Rainer I cannot reproduce.

 what is
 -  your org-version ?
'M-org-version' produces

Org-mode version N/A (N/A @ c:/Documents and
Settings/IZAHN/.emacs.d/izahn/org-mode/lisp/)

but this is orgmode from git, updated yesterday.

 -  emacs version?
GNU Emacs 24.2.1 (i386-mingw-nt5.1.2600) of 2012-08-28 on MARVIN
 - are you under cygwin ?
I have cygwin installed, but emacs is the windows version from
http://ftp.gnu.org/gnu/emacs/windows/

The OS is Windows XP professional with service pack 3.

 Here:
 Org-mode version 7.9.2 (d344fda @
 GNU Emacs 24.2.1 (i386-mingw-nt6.1.7601) of 2012-08-29 on MARVIN
 Windows 7

 with my .emacs:
 (require 'org)
 ...
 (require 'org-export)
 (require 'org-e-odt)

I started emacs with emacs -q and evaluated the following lines with 'C-x-e':

;; Look recursively in .emacs.d for elisp files and packages
(let ((default-directory ~/.emacs.d/))
  (normal-top-level-add-to-load-path '(.))
  (normal-top-level-add-subdirs-to-load-path))

;; just to make sure...
(mapc (lambda (path) (add-to-list 'load-path path))
  '(~/.emacs.d/elpa/elnode-0.9.9
~/.emacs.d/izahn/org-mode/lisp
~/.emacs.d/izahn/org-mode/contrib/lisp
~/.emacs.d/izahn/org-ehtml/src
~/.emacs.d/izahn/org-ehtml/test/lisp))

(require 'org)
(require 'org-export)
(require 'org-e-odt)

 

 I call with M-x export-dispatch  3 o o
 (3 is to select the subtree)

I also tried selecting just the subtree, with the same results, i.e.,
no content.xml


 With this subtree:
 ---
 *** test
 test B /b/ *g*   +Carsten+
  test 2
 hello
 ---

  *Message*  buffer:
 Using vacuous schema
 Unknown LaTeX option.  Forcing verbatim.
 Formatting LaTeX using verbatim
 Wrote c:/Users/. ./AppData/Local/Temp/odt-3456fvm/meta.xml
 Using schema c:/Users/. 
 ./programs/emacs-o/org/etc/schema/od-schema-v1.2-cs01.rnc [2 times]
 Saving file c:/Users/. ./AppData/Local/Temp/odt-3456fvm/styles.xml...
 Wrote c:/Users/. ./AppData/Local/Temp/odt-3456fvm/styles.xml
 Wrote c:/Users/. ./AppData/Local/Temp/odt-3456fvm/mimetype
 Using vacuous schema
 Saving file c:/Users/. 
 ./AppData/Local/Temp/odt-3456fvm/META-INF/manifest.xml...
 Wrote c:/Users/. ./AppData/Local/Temp/odt-3456fvm/META-INF/manifest.xml
 Saving file c:/Users/. ./AppData/Local/Temp/odt-3456fvm/content.xml...
 Wrote c:/Users/. ./AppData/Local/Temp/odt-3456fvm/content.xml
 (No changes need to be saved)
 Creating ODT file...
 Running c:/Users/. ./programs/zip/bin/zip -mX0 test.odt mimetype
 Running c:/Users/. ./programs/zip/bin/zip -rmTq test.odt .
 Created c:/Users/. ./AppData/Roaming/test.odt
 Parsing archive file...done.

My *Messages* buffer shows

Using vacuous schema
OVERVIEW
LaTeX to MathML converter not available.
Formatting LaTeX using verbatim
Wrote c:/DOCUME~1/IZAHN/LOCALS~1/Temp/odt-3688Mws/meta.xml
Using schema ~/.emacs.d/izahn/org-mode/etc/schema/od-schema-v1.2-cs01.rnc
[2 times]
Saving file c:/Documents and Settings/IZAHN/Local
Settings/Temp/odt-3688Mws/styles.xml...
Wrote c:/Documents and Settings/IZAHN/Local Settings/Temp/odt-3688Mws/styles.xml
Wrote c:/DOCUME~1/IZAHN/LOCALS~1/Temp/odt-3688Mws/mimetype
Using vacuous schema
Creating ODT file...
Running zip -mX0 test.odt mimetype
Running zip -rmTq test.odt .
Created c:/Documents and Settings/IZAHN/Desktop/test.odt
Parsing archive file...done.



  file  test.odt:

 M Filemode  Length  Date Time  File
 - --    ---    -
   -rw-rw-rw-39  27-Nov-2012  09:23:16  mimetype
   -rw-rw-rw- 21823  27-Nov-2012  09:23:16  content.xml
   drwxrwxrwx 0  27-Nov-2012  09:23:16  meta-inf/
   -rw-rw-rw-   573  27-Nov-2012  09:23:16  META-INF/manifest.xml
   -rw-rw-rw-   818  27-Nov-2012  09:23:16  meta.xml
   -rw-rw-rw- 66559  27-Nov-2012  09:23:16  styles.xml

Re: [O] New exporter (org-e-odt) not creating content.xml

2012-11-27 Thread Ista Zahn
Thank you, I'm currently working around this with

;; fix f'ed up windows temp directory
(if (eq system-type 'windows-nt)
  (setq temporary-file-directory c:/tmp/)
)

in my init.el, and odt export is now working as expected.

Best,
Ista

On Tue, Nov 27, 2012 at 12:46 PM, Jambunathan K kjambunat...@gmail.com wrote:
 Jambunathan K kjambunat...@gmail.com writes:

 Ista

 Your suspicion is confirmed.

 If this is true, then either my
 understanding of `get-file-buffer' is incorrect or that
 `get-file-buffer' is buggy.

 Please let me know what I can do to help figure this out.

 I have filed a bug:

 http://debbugs.gnu.org/cgi/bugreport.cgi?bug=13013

 Irrespective of what the Emacs maintainers feel about this issue, I will
 push a fix.  (But fix will take couple of day's time to hit the repo.)


 To add to that

 As a temporary work around, you can also do
 M-x customize-variable RET temporary-file-directory RET

 and point in to some directory that doesn't have spaces or long names.

 With my (future) fix, the above customization may not be necessary.


 Jambunathan K.



[O] New exporter (org-e-odt) not creating content.xml

2012-11-26 Thread Ista Zahn
I can't seem to get the new odt exporter working on my Windows machine
at work (it works fine on Linux at home). Specifically, when I call
'M-x export-dispatch o o'  I get an odt archive with the following
contents.

M Filemode  Length  Date Time  File
- --    ---    --
  -rw-rw-rw-39  26-Nov-2012  17:31:16  mimetype
  drwxrwxrwx 0  26-Nov-2012  17:31:16  meta-inf/
  -rw-rw-rw-   782  26-Nov-2012  17:31:16  meta.xml
  -rw-rw-rw- 66559  26-Nov-2012  17:31:16  styles.xml
- --    ---    --
 67380 4 files

Comparing with the old exporter (i.e., 'C-e o') I find

M Filemode  Length  Date Time  File
- --    ---    -
  -rw-rw-rw-39  26-Nov-2012  17:31:00  mimetype
  -rw-rw-rw- 25556  26-Nov-2012  17:31:00  content.xml
  drwxrwxrwx 0  26-Nov-2012  17:31:00  meta-inf/
  -rw-rw-rw-   573  26-Nov-2012  17:31:00  META-INF/manifest.xml
  -rw-rw-rw-   807  26-Nov-2012  17:31:00  meta.xml
  -rw-rw-rw- 67037  26-Nov-2012  17:31:00  styles.xml
- --    ---    -
 94012 6 files

So it seems that the new exporter is not creating content.xml, or
META-INF/manifest.xml. Again this only happens on Windows. It is
reproducible every time, and is reproducible starting with emacs -q
and then loading only org and org-e-odt.

Thanks for any suggestions, and please let me know what other
information I can provide to make it easier for you to help me.

Best,
Ista



Re: [O] Source block processing changes

2012-11-06 Thread Ista Zahn
On Tue, Nov 6, 2012 at 8:22 AM, Eric Schulte schulte.e...@gmail.com wrote:
 Ista Zahn istaz...@gmail.com writes:

 Hi all,

 I've been silently suffering since the changes to source block
 processing announced at the end of September[1]. I had been using
 (abusing?) ':results org' to write results that would be processed as
 orgmode syntax and exported to both latex and html. For example, this

 #+name: tst
 #+begin_src R :results output org :exports results
   library(ascii)
   cat(* First ten\n)
   print(ascii(head(mtcars)), type=org)
   cat(\n* Last ten\n)
   print(ascii(tail(mtcars)), type=org)
 #+end_src

 used to give me heading First ten followed by a table nicely
 formatted in html or latex depending on the export target, followed by
 a heading Last ten, again followed by a nicely formatted table.
 Changing the data or the code in the block would update the contents.
 This was very convenient, and I relied heavily on this to generate
 reports.

 Now it seems that this very useful feature no longer exists, and try
 as I might I cannot find a way to duplicate it. Using ':results
 drawer' or ':results org' gives me verbatim export

 This was a bug in :results drawer, which should *not* escape its
 results.  I've just pushed up a fix for this so :results drawer should
 now be a drop-in replacement for your previous use-case of :results
 org (as was the original intent of this change).

Thank you, all is working as desired now! One small niggle: the
'::RESULTS:' and ':END:' strings are included in the exported html.
Not sure if this is intentional, but it seems to me that they should
be removed (or at lease given a class so we can hide them via css)

Thanks again!
Ista

 Best,

 --
 Eric Schulte
 http://cs.unm.edu/~eschulte



Re: [O] Source block processing changes

2012-11-06 Thread Ista Zahn
On Tue, Nov 6, 2012 at 11:44 AM, Nicolas Goaziou n.goaz...@gmail.com wrote:
 Ista Zahn istaz...@gmail.com writes:

 Thank you, all is working as desired now! One small niggle: the
 '::RESULTS:' and ':END:' strings are included in the exported html.
 Not sure if this is intentional, but it seems to me that they should
 be removed (or at lease given a class so we can hide them via css)

 That's because you're inserting a headline within a drawer, which isn't
 valid Org syntax. You cannot use a drawer for your specific use-case.

Well, it works at the moment (I can live with the extra ':RESULTS:'
strings). So currently I _can_ use a drawer for my use case -- the
question is whether this is likely to break in the future.

Another question is what is and is not allowed in a drawer? Is this documented?

Best,
Ista

 Regards,



Re: [O] Source block processing changes

2012-11-06 Thread Ista Zahn
On Tue, Nov 6, 2012 at 12:16 PM, Nicolas Goaziou n.goaz...@gmail.com wrote:
 Ista Zahn istaz...@gmail.com writes:

 On Tue, Nov 6, 2012 at 11:44 AM, Nicolas Goaziou n.goaz...@gmail.com wrote:
 Ista Zahn istaz...@gmail.com writes:

 Thank you, all is working as desired now! One small niggle: the
 '::RESULTS:' and ':END:' strings are included in the exported html.
 Not sure if this is intentional, but it seems to me that they should
 be removed (or at lease given a class so we can hide them via css)

 That's because you're inserting a headline within a drawer, which isn't
 valid Org syntax. You cannot use a drawer for your specific use-case.

 Well, it works at the moment (I can live with the extra ':RESULTS:'
 strings). So currently I _can_ use a drawer for my use case -- the
 question is whether this is likely to break in the future.

 This is already broken. In Org syntax,

   :RESULTS:
   * Headline
   :END:

 means a paragraph containing :RESULTS: text, then an headline
 containing a section with a paragraph containing :END: text. In other
 words, headlines have precedence over drawers.

 Expecting Org to recognize a drawer here is like playing with fire. You
 cannot know when it will burn you.

 Another question is what is and is not allowed in a drawer? Is this
 documented?

 A drawer can contain anything but a headline and another drawer.

OK, great. The ability to generate headlines from source blocks is not
crucial, I'll change them to plain lists.

 I'm not
 talking about properties drawer which is special. This is not explicitly
 documented.


 Regards,



  1   2   >