Re: [Orgmode] Tracking time with MobileOrg

2010-10-07 Thread Carsten Dominik

Hi Richard,

On Oct 7, 2010, at 12:55 AM, Richard Moreland wrote:


Hi Jeff,

I'm glad you mentioned this.  It is on my list of things to work on  
next.


Support for clocking in MobileOrg would be very valuable.  And of course
I'd be happy to handle the Emacs side.



I still need to coordinate it with Carsten to make sure the approach  
is sound and that he can support me by updating org-mobile.el.


My plan for the UI is this:

- Two methods to clock in a new task:  First, you can tap and hold  
on a node, then click the 'Clock in' button.  Alternatively, you can  
open up the node details page and click a similar 'Clock in' button.


Sounds good.



- To clock out, you can use the same method, but the button would  
say 'Clock out' instead.  Since it would be tedious to find the  
current clocking item,


Yes, this would be totally annoying if you *had to* find
that entry back just to clock out.

Of course, clocking into another item should stop the
running clock.



I'm considering...

- A tab/icon at the bottom for Clocking (like the 4 existing icons  
at the bottom).  I may make it optional in the Settings page.  If  
you are clocking, there will be an indicator on the icon letting you  
know so, perhaps by overlaying the clock time on the icon somehow.


Yes, show the time!

Maybe you could also modify the application badge to show that
the clock is running.  Not the with time, but just add a little clock,  
or change the color of the badge or...


- If you click on the clocking icon at the bottom, a list of  
recently clocked tasks will be shown, with the active one being  
highlighted.  You can stop the running clock, or start the clock on  
any of your recent items.


This would be excellent.  This list of recently clocked items
could also be made to survive when you sync.  You could
keep a list of the IDs or OLPs and only verify the existence
of the node after a sync.  So while the collected times would
be written to the server and then no longer be visible in the
clock list, the items themselves should stay.



When you sync and run org-mobile-pull, the time logs would be added  
to the correct nodes (I'll need Carsten or a volunteer to help me  
integrate this part).


Yes, I'll do that.



I believe this workflow would make it easy to clock in (either by  
navigating to the node in the outline, searching for it on the  
Search page, or identifying a recently clocked item) and clock out.


I haven't covered any type of reporting within the app, I was hoping  
to keep things relatively simple.


I don't think reporting would be needed.  Just the list of recent  
items, with information of the time clocked on these items seems to be  
enough.

Everything else can happen in Emacs.

But if there is a need for this let me know.  Perhaps clicking on an  
entry in the recently clocked list could display the start/stop  
times and some summary info.


Yes.  You might even consider allowing to edit the times - but I don't
think this is so important.



Let me know what you think, it would help to have some feedback on  
the workflow before I begin.


Please don't let encryption drop from your priority list :)

Cheers

- Carsten



Thanks,
Richard

On Oct 6, 2010, at 2:41 PM, Jeff Kowalczyk wrote:

Can the current version of MobileOrg be used for a simple time  
tracking

workflow? (i.e. does it have an easy clock in and clock out?)

My wife has a need for a simple time tracking application on the  
iPhone. The
only number needed is total hours spent per period (e.g. month) on  
one task, the

full-time job.

I use Org Mode for my own worklogs, and would do any necessary pre- 
templating
and post-processing on the resultant Org file, if a rapid-capture  
strategy can

be worked out for MobileOrg.

Given how much I use and like Org Mode myself, I'd be really  
pleased if we can

work with Org as a file format for this application, rather than some
closed-source app.

Thanks,
Jeff



___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode



___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode



___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] How do I convert org to OpenOffice?

2010-10-07 Thread Eric S Fraga
On Wed, 06 Oct 2010 14:10:30 -0700, Henri-Paul Indiogine hindiog...@gmail.com 
wrote:
 
 Hi Eric!
 
 Eric S Fraga ucec...@ucl.ac.uk writes:
  org document
   - export as HTML (C-c e h)
   - open in OOo 
   - select and copy all (C-a C-c)
   - open new document in OOo (A-f n t [I believe]) 
   - paste selection (C-v)
   - save (in my case, often as MS Word)
   - go and cry because you have to degrade org mode so much ;-)
 
 1. export should be C-c C-e h

Yes, sorry, typo.

 2. My BibTeX references are not exported.  Am I missing something or is
 it not possible this way?

Not possible this way.  If you need bibtex then latex2rtf, as
mentioned by others, is what I have used in the past.

 3. How could I have some sort of version control?  My advisor uses the
 accursed MS Word and that is all he knows.

I am not sure what you are asking.  I use version control (git/hg/rcs)
for all of my org files regardless of whether I export them or not.
-- 
Eric S Fraga
GnuPG: 8F5C 279D 3907 E14A 5C29  570D C891 93D8 FFFC F67D
___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] Re: Bibtex and latex export

2010-10-07 Thread Eric S Fraga
On Wed, 06 Oct 2010 19:21:33 +0200, Achim Gratz strom...@nexgo.de wrote:
 
 Hi Eric,
 
 Eric S Fraga ucec...@ucl.ac.uk writes:
  | /usr/bin/texi2dvi: Processing /home/ucecesf/.../file.tex ...
  | egrep: Invalid range end
  | /usr/bin/texi2dvi: cannot read .//home/ucecesf/.../file.tex, skipping.
 
 Something somewhere tries to make a local path from an absolute one by
 prepending ./, which fails (predictably).  Is the input readable at
 the original path?  Not sure the error message from egrep has to do with
 it or not, but it must be in any case one of the processes started by
 texi2dvi (does not show up on my system, I only have calls to grep when
 I trace it, but one of the sub-processes might still use it).  I think
 texi2dvi also invokes shell scripts, so any funny configuration in the
 environment, especially where path points to, could throw it off.

As far as I know, there is nothing out of the ordinary with my paths
etc (please note that the /.../ above was an edit on my part to hide a
rather long path).  Any hints as to what I can do to explore this
would be most helpful.  How can I get a trace on what texi2dvi is
doing?  (sh -v /usr/bin/texi2dvi?)

Thanks,
eric
-- 
Eric S Fraga
GnuPG: 8F5C 279D 3907 E14A 5C29  570D C891 93D8 FFFC F67D
___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] Re: Bibtex and latex export

2010-10-07 Thread Eric S Fraga
On Wed, 6 Oct 2010 18:40:12 +0200, Carsten Dominik carsten.domi...@gmail.com 
wrote:
 On Oct 6, 2010, at 5:02 PM, Eric S Fraga wrote:

[...]

  Reading between the lines, I gather it is the change to
  org-latex-to-pdf-process that has caused me problems.  The output I
  get when the export takes place is:
 
  ,
  | /usr/bin/texi2dvi: Processing /home/ucecesf/.../file.tex ...
  | egrep: Invalid range end
  | /usr/bin/texi2dvi: cannot read .//home/ucecesf/.../file.tex,
  skipping.
  `
 
 
 That is bad - I have no idea here.  Maybe a non-standard
 version of egrep?  But I am really guessing here.

Well, I'm running Debian Linux (testing+unstable mix) so it could be
something I (or Debian) have done.  I've got grep-2.6.3-3 installed
which is from Debian testing.

Is there any way to see what egrep is trying to do? 

 Lets see if this affects more people - for the time being you might
 just change the variable to have it make 2-3 pdflatex runs.

Yes, no problem at all.  This is what I did later but exporting to
latex and running pdflatex myself got me through when the crisis
happened!

Thanks,
eric
-- 
Eric S Fraga
GnuPG: 8F5C 279D 3907 E14A 5C29  570D C891 93D8 FFFC F67D
___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] Themes Compatible with color-theme.el

2010-10-07 Thread Ian Barton

I have about as much talent for designing colour themes as the average
goldfish. That's unfair, the goldfish are better than me:) So I use
someone else's them and customize it a bit.

In a recent bout of fiddling I decided to try out a few new themes. I
searched the mailing list and there has been quite a bit of discussion
about themes for org. However, when I look at Worg
(http://orgmode.org/worg/org-tutorials/org-appearance.php), the
information about colour themes is very sparse. Also when I look at
the org source code the one theme mentioned in Worg (zenburn) isn't in
Worg/color-themes, but there is another one (railscast), which isn't
mentioned on Worg.

There is also a link to one of Bastien's pages at
http://www.cognition.ens.fr/~guerry/org-color-themes.html which is now
a Monty Python parrot (deceased).

I would like to tidy up the Worg section on themes and add a screen
shot for each theme.

Colour themes I have been able to find .el files for.
color-theme-colorful-obsolescence.el
color-theme-railscast.el
color-theme-tangotango.el
color-theme-zenburn.el
color-theme-sva.el

However, color-theme-sva.el seems to have at least one syntax error,
so if Sebastien Vauban fixes it before I do, perhaps he could post
anlother version here.

There is one theme mentioned in the mailing list where I can't find an
.el file: color-theme-cl-frame.el

If anyone would like to post their theme as a reply to this message, I
would be happy to incorporate it into Worg.

Ian.

___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] Re: clocktable: maximum level 0 does not only avoid listing items but also does not calculate items

2010-10-07 Thread Rainer Stengele
Am 22.07.2010 09:47, schrieb Carsten Dominik:
 
 On Jul 22, 2010, at 9:16 AM, Rainer Stengele wrote:
 
 Am 21.07.2010 16:24, schrieb Carsten Dominik:

 On Jul 13, 2010, at 11:21 AM, Rainer Stengele wrote:

 Hi all!

 lately I use the marvelous clocktables a lot...

 For toplevel clocktables which just sum up all I use :maxlevel 0

 The manual reads

 :maxlevelMaximum level depth to which times are listed in the table.

 which I misunderstood.
 I understood: an unlisted item does not mean that its time is not added!
 But it looks like :maxlevel 0 does not add everything up.


 I cannot reproduce this, :maxlevel 0 works for me.


 Ok, maybe the manual is a bit misleading here.



 How can I get a clocktable without any details which simply adds up 
 everything in the scope?

 BTW, the :stepskip0 parameter does not seem to be included in the manual.

 It is in the manual.

 - Carsten


 Rainer





 Carsten,

 maybe I misunderstood.


 1. Without maxlevbel I get I get

 #+BEGIN: clocktable :scope (file1.org file2) :timestamp t :tstart 
 2010-05-01 Sa 00:00 :tend  2010-07-31 Sa 23:55
 Clock summary at [2010-07-22 Do 09:07]

 | File  | L | Timestamp   | Headline   | Time |  
   ||
 |---+---+-++--++|
 |   |   | Timestamp   | *Total time*   | *327:51* |  
   ||
 ...



 with :maxlevel 0 I get


 #+BEGIN: clocktable :maxlevel 0 :scope (file1.org file2) :timestamp t 
 :tstart 2010-05-01 Sa 00:00 :tend  2010-07-31 Sa 23:55
 Clock summary at [2010-07-22 Do 09:11]

 | File | L | Timestamp | Headline | Time |
 |--+---+---+--+--|
 |  |   | Timestamp | *Total time* | *232:17* |
 |--+---+---+--+--|
 #+END:


 I would like to get the same results!
 
 Indeed, this looks wrong.
 
 Unfortunately I don't have time to look at this before my vacation (starting 
 tomorrow) :(
 Please remind me when I get back.
 
 - Carsten
 

Hi Carsten,

this is still open, I just tested. I feel like this is a near to major bug
because it will simply vary your (work) time calculation if you choose 
different maxlevels.

- Rainer


___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] Re: Bibtex and latex export

2010-10-07 Thread Sébastien Vauban
Hi Eric,

Eric S Fraga wrote:
 As far as I know, there is nothing out of the ordinary with my paths etc
 (please note that the /.../ above was an edit on my part to hide a rather
 long path). Any hints as to what I can do to explore this would be most
 helpful. How can I get a trace on what texi2dvi is doing? (sh -v
 /usr/bin/texi2dvi?)

I tried:

#+begin_src emacs-lisp
(setq org-latex-to-pdf-process '(sh -v -x texi2dvi -p -b -c -V %f))
#+end_src

and only see the following in *Messages*:

#+begin_src log
Exporting to LaTeX...done
Processing LaTeX file 
/home/sva/Projects/Institutions/Forem/Pfi/pfi/Specs/2010-DMFA-et-Autres/Devis-Demandes-2010.tex...
(Shell command failed with code 2 and some error output)
Processing LaTeX file 
/home/sva/Projects/Institutions/Forem/Pfi/pfi/Specs/2010-DMFA-et-Autres/Devis-Demandes-2010.tex...done
Exporting to PDF...done
#+end_src

The default way, for comparison:

#+begin_src emacs-lisp
(setq org-latex-to-pdf-process '(texi2dvi -p -b -c -V %f))
#+end_src

displays:

#+begin_src log
Exporting to LaTeX...done
Processing LaTeX file 
/home/sva/Projects/Institutions/Forem/Pfi/pfi/Specs/2010-DMFA-et-Autres/Devis-Demandes-2010.tex...done
Exporting to PDF...done
#+end_src

So, I've got no idea on how to see the real calls made in sh, for debugging
purpose. Thanks for the =-v= switch to sh. Only knew =-x=...

Best regards,
  Seb

-- 
Sébastien Vauban


___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] Re: org-clock-idle-time resolving dialogues seem to stack up for each passed idle time period

2010-10-07 Thread Rainer Stengele
Am 06.08.2010 09:35, schrieb Rainer Stengele:
 hi all,
 
 having set org-clock-idle-time to 15 minutes the dialogue to resolve the idle 
 time shows correctly after 15 minutes of idle time.
 Many times I simply press j just to jump to the running clock.
 
 What I experience is that I have to press j several times until the 
 dialogue gets finally closed.
 It looks like the resolving dialogues are stacking up, one for each 
 org-clock-idle-time period that has passed.
 
 Can anybody confirm this - well - bug?
 
 
 Rainer
 
 
 ___
 Emacs-orgmode mailing list
 Please use `Reply All' to send replies to the list.
 Emacs-orgmode@gnu.org
 http://lists.gnu.org/mailman/listinfo/emacs-orgmode
 
Hi all,

this still bugs me. After leaving idle my emacs for some time longer
than the configured idle time I have to apply answers to the idle-time
dialogue several times. I cannot simply press j to jump to the open clock but
have to press j an unknown many times, mostly ending up with one or more j
characters at the point I am being jumped to finally...

Looks like I am the only one using this feature?

Anybody has an idea?

Rainer

___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] Re: Themes Compatible with color-theme.el

2010-10-07 Thread Sébastien Vauban
Hi Ian,

Ian Barton wrote:
 Colour themes I have been able to find .el files for.
 color-theme-colorful-obsolescence.el
 color-theme-railscast.el
 color-theme-tangotango.el
 color-theme-zenburn.el
 color-theme-sva.el

Excellent initiative, to collect themes and update Worg!


 However, color-theme-sva.el seems to have at least one syntax error,
 so if Sebastien Vauban fixes it before I do, perhaps he could post
 anlother version here.

Here is my fully functional release of the day. Please signal me any
trouble.

Best regards,
  Seb

-- 
Sébastien Vauban


color-theme-sva.el
Description: application/emacs-lisp
___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] Re: Themes Compatible with color-theme.el

2010-10-07 Thread Ian Barton

On 07/10/10 09:56, Sébastien Vauban wrote:

Hi Ian,

Ian Barton wrote:

Colour themes I have been able to find .el files for.
color-theme-colorful-obsolescence.el
color-theme-railscast.el
color-theme-tangotango.el
color-theme-zenburn.el
color-theme-sva.el


Excellent initiative, to collect themes and update Worg!



However, color-theme-sva.el seems to have at least one syntax error,
so if Sebastien Vauban fixes it before I do, perhaps he could post
anlother version here.


Here is my fully functional release of the day. Please signal me any
trouble.


Hi Seb,

Thanks that version works fine.

Ian.

___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] Re: custom postamble in HTML export

2010-10-07 Thread Łukasz Stelmach
Carsten Dominik carsten.domi...@gmail.com writes:

 On Oct 5, 2010, at 6:43 PM, Łukasz Stelmach wrote:

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

 :postamble is meant to completely replace the automatic
 postamble Org creates,

 But what if I like the information it puts there?

 Then you have a case which Org currently does not handle.

Yes, it does. org-export-html-postamble may also be a function. So it'll
be a lot better for all of us, and especially for the code, if I just
c'n'p the automatic postamble code as a custom function and add there
what I need. The only minor problem here is how to load the function
only when it's needed, no sooner than I open any of the files that
require it. But it's for something completely different ;-)

 You would have to introduce a new variable, org-export-html-postamble-
 extra and arrange for it to be handled correctly with publishing
 properties etc etc.

According to Larry Wall[1], laziness is one of the greatest virtues
of programmers[2]. Right next to impatiens and hubris ;-)

[1] http://en.wikipedia.org/wiki/Larry_Wall
[2] http://en.wikipedia.org/wiki/Larry_Wall#Virtues_of_a_programmer

-- 
Miłego dnia,
Łukasz Stelmach


___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] Header levels and section numbering 3, in LaTeX export

2010-10-07 Thread Scot Becker
Indraneel,

  Thanks Scot, exactlt what I was looking for, and I was actually
 deliberating on the Tractacus!

Funny.  Glad it looks like it may work.

 I couldn't get easylist to understand the
 \star symbol that orgmode uses. Do you know how to do that?

No.  You might have seen the footnote in the easylist documentation
(on p. 2) which says:

You might not be happy with the symbols and maybe you'd like to use
another one, or simply have your favorite symbol
as default to avoid remembering such a cumbersome name as 'pilcrow'.
Here's a simple hack that does the job: select the
entire code of the package, and replace all occurrences of Ÿ (-- the
pilcrow) with your symbol. Make sure you won't use it in the list for
other purposes, though.

I've not tried this, however.  It would be nice if there were a dead
easy way to get easylist and org-mode to work well together, since the
two are very natural partners.  Let me know if you can make this work.

 And also to skip
 the first 3 stars in a level4 heading (if I want to retain latex's default
 top 3 levels)?

I've never actually gone all the way to making a document
easy-to-publish with Easylist.  I've just manually converted
org-mode's stars to a character Easylist can understand, then manually
wrapped the whole thing in a LaTeX preamble.  The ideal would be to
automate the process, perhaps by using org-babel and putting your
easylist sections in special code blocks. But I've not taken the time
to figure all that out.

Failing that, I bet you could do a halfway hack with minimal amount of
manual work.  For example (if I understand you correctly), you could
make an org document like this:

* Regular org heading
** Subheading
** Here's a third-level heading
STARTLIST
 My first thesis, which is longer and wordier than it probably should be.
* Of course it's nothing compared to the length of its supporting arguments
*  Both of them
 Here is my second thesis, as convincing as the first
ENDLIST

Org-mode will let you do all of that, just fine.  Then either
manually, or with a temporary latex export hook, do something like
this:

replace STARTLIST with \begin{easylist} and ENDLIST with \end{easylist}
replace ' ' with ' ' and '* ' with ' ' and ** ' with ' ', etc.


If you do it in an export hook, I think you'd want to do it in one
that runs before everything else.  That way org-mode will leave
everthing in your easylist environment alone.  What that will do to
quotation marks and /emphasis/ I don't know.

This should leave you with an easylist which starts at level '1', in a
document which uses org's header levels 1-3 in the normal latex way.
Is that what you want?

Make sure in the preamble, you have \usepackage[ampersand]{easylist}

Let me know if you need help figuring any of this out in detail.
That's just a rough sketch.

Cheers,

Scot

___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] Orgmode and filling

2010-10-07 Thread Guy Wiener
Yes, that seems to do the trick - Thanks!
Btw, why is this option the default in org-mode? It is the opposite of
the fundamental mode.

:- Guy

On Wed, Oct 6, 2010 at 5:22 PM, Giovanni Ridolfi
giovanni.rido...@yahoo.itwrote:

 Guy Wiener wiener@gmail.com writes:

 Hi, Guy,

  When the cursor crosses the edge of the
  frame, instead of placing a long line marker and moving to the next
  line, the entire buffer is shifted to the left and the cursor remains
  on the same line.

  Can this behavior be disabled, and replaced the the same behavior as
  in fundamental text editing? It is really annoying, especially when
  using auto-fill mode.

 M-x toggle-truncate-lines  does help?

 so that Truncate long lines disabled.

 Or place in your .emacs:
 (setq truncate-lines t)

 cheers,
 Giovanni

___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] Orgmode and filling

2010-10-07 Thread Carsten Dominik


On Oct 7, 2010, at 12:04 PM, Guy Wiener wrote:


Yes, that seems to do the trick - Thanks!
Btw, why is this option the default in org-mode? It is the opposite  
of the fundamental mode.


Because tables and source code look bad with lines wrapped around.
I have put a feature request into Emacs, asking for truncate-lines
to become a text property, then I could exclude tables from wrapping -  
but until then, I'll keep the truncation default.


- Carsten



:- Guy

On Wed, Oct 6, 2010 at 5:22 PM, Giovanni Ridolfi giovanni.rido...@yahoo.it 
 wrote:

Guy Wiener wiener@gmail.com writes:

Hi, Guy,

 When the cursor crosses the edge of the
 frame, instead of placing a long line marker and moving to the  
next
 line, the entire buffer is shifted to the left and the cursor  
remains

 on the same line.

 Can this behavior be disabled, and replaced the the same behavior as
 in fundamental text editing? It is really annoying, especially when
 using auto-fill mode.

M-x toggle-truncate-lines  does help?

so that Truncate long lines disabled.

Or place in your .emacs:
(setq truncate-lines t)

cheers,
Giovanni

___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


- Carsten




___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] Re: Orgmode and filling

2010-10-07 Thread Tassilo Horn
Guy Wiener wiener@gmail.com writes:

Hi!

 Btw, why is this option the default in org-mode? It is the opposite of
 the fundamental mode.

It makes no big difference when using filling, because then you don't
have long lines that are truncated anyway.  The only lines that won't be
filled and might get long are headlines.  And those look weird when
being broken across many lines. (Try it out!)

Bye,
Tassilo


___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] Tracking time with MobileOrg

2010-10-07 Thread Richard Moreland

On Oct 7, 2010, at 2:38 AM, Carsten Dominik wrote:

 Please don't let encryption drop from your priority list :)

I actually got that working last night, I just need to add the Settings option 
for the user's passphrase and I'll prepare it for beta/release this evening.

-Richard


___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] Tracking time with MobileOrg

2010-10-07 Thread Carsten Dominik


On Oct 7, 2010, at 1:10 PM, Richard Moreland wrote:



On Oct 7, 2010, at 2:38 AM, Carsten Dominik wrote:


Please don't let encryption drop from your priority list :)


I actually got that working last night, I just need to add the  
Settings option for the user's passphrase and I'll prepare it for  
beta/release this evening.


Great!

- Carsten




___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] [Babel] Handling of errors when using Ledger

2010-10-07 Thread Sébastien Vauban
#+TITLE: Handling of errors when using Ledger
#+LANGUAGE:  en_US

* Journal data

#+srcname: data
#+begin_src ledger :tangle journal.dat
2008/01/03 * (SCORPIOS ) SEB VAUBAN
Assets:Bank:Checking:77400530   550.00 
EUR
Assets:Bank:Transferred

2008/01/01 * ( ) UNKNOWN-PAYEE
Assets:Bank:Checking:7740053021.91 
EUR
Expenses:Unknown
#+end_src

* Testing

** Default case

Here the results of the standards =registry= command:

#+srcname: registry-cmd
#+begin_src ledger :cmdline reg :noweb yes :session
data
#+end_src

#+results: registry-cmd
: 08-Jan-03 SEB VAUBANAs:Ba:Che:77400530   550.00 EUR   550.00 
EUR
: Asset:Bank:Transferred  -550.00 EUR   
 0
: 08-Jan-01 UNKNOWN-PAYEE As:Ba:Che:7740053021.91 EUR21.91 
EUR
: Expenses:Unknown -21.91 EUR   
 0

This is a perfectly acceptable output. Ideally, it could be converted to a
real Org table, but that's not the purpose of this posting.

** Other default case

Here, I would like to take a look at the transactions which involve the
unknown account:

#+srcname: just-show-unknown
#+begin_src ledger :cmdline reg unknown :noweb yes :session
data
#+end_src

#+results: just-show-unknown
: 08-Jan-01 UNKNOWN-PAYEE Expenses:Unknown -21.91 EUR   -21.91 
EUR

Perfect result. That will serve as demo.

** No output
   :PROPERTIES:
   :ID:   52aa2449-0c3d-4dee-ad57-8b2e916ed501
   :END:

#+srcname: no-output
#+begin_src ledger :cmdline reg unkXXXnown :noweb yes :session
data
#+end_src

#+results: no-output

** Error neither trapped nor shown

Let's imagine I thought (which was the case at some point) I needed to enclose
the parameters between quotes:

#+srcname: quoted-params
#+begin_src ledger :cmdline reg unknown :noweb yes :session
data
#+end_src

#+results: quoted-params

Nothing is returned. In fact, I would expect an error to be thrown, the same
way it should when run in a shell:

#+begin_src sh
ledger -f journal.dat reg unknown
#+end_src

that is:

: ~ledger -f journal.dat reg unknown
: Error: Unrecognized command 'reg unknown'
: 
: ~echo $?
: 1

Here, the shown results is exactly the same as in the 
[[id:52aa2449-0c3d-4dee-ad57-8b2e916ed501][No output]] case. As if
the command ended successfully, with an empty results set...

* Observations and suggestions

I don't know if this is a common problem (to Org-Babel) or only to the Ledger
part of it, but I think *we* should somehow improve the handling of errors.

- Maybe displaying a =#+results-err= block which would be what's shown on
  =/dev/stderr=, when not void?

- And having a way to display the error code would be a plus.

Best regards,
  Seb

-- 
Sébastien Vauban


___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] portable absolute links in HTML export

2010-10-07 Thread Łukasz Stelmach
Hello.

Is there a simple way to create hyperlinks with *absolute* paths that
would work after both: simple file export (C-c C-e h) and publishing on
a remote server (C-c C-e F). I'd like to create a _menu.org file that
contains some navigation links and #+INCLUDE: it (BTW. M-Tab can't
complete #+INC) in every single file I create and publish.

The problem now looks like there should be separete _menu.org files for
each directory if I want to use relative paths in the menu links, that
work after local (C-c C-e h) and remote (C-c C-e h) export. When I put
absolute paths that work on

Let's say I've got a structure like this

~/WWW/index.org
~/WWW/_menu.org
~/stuff/index.org
~/things/index.org
~/problems/index.org

after publishing the index.org files are available at:

http://example.com/~stl/
http://example.com/~stl/stuff/
http://example.com/~stl/things/
http://example.com/~stl/problems/

respectively.

The _menu.org that works in the main index.org looks like this:

+ [[file:index.org][Home]]
+ [[file:stuff/index.org][Stuff]]
+ [[file:things/index.org][Things]]
+ [[file:problems/index.org][Problems]]

But when I #+INCLUDE it in the stuff/index.org file the links point at

http://example.com/~stl/stuff/index.html
http://example.com/~stl/stuff/stuff/index.html
http://example.com/~stl/stuff/things/index.html
http://example.com/~stl/stuff/problems/index.html

On the other hand if I replace file: links with absolute http: ones I
won't be able to navigate between the HTML files created locally with
C-c C-e h.

+ [[http://example.com/~stl/index.org][Home]]
+ [[http://example.com/~stl/stuff/index.org][Stuff]]
+ [[http://example.com/~stl/things/index.org][Things]]
+ [[http://example.com/~stl/problems/index.org][Problems]]

Is there any secret way to overcome such a problem?

-- 
Miłego dnia,
Łukasz Stelmach


___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] portable absolute links in HTML export

2010-10-07 Thread Carsten Dominik


On Oct 7, 2010, at 2:21 PM, Łukasz Stelmach wrote:


Hello.

Is there a simple way to create hyperlinks with *absolute* paths that
would work after both: simple file export (C-c C-e h) and publishing  
on

a remote server (C-c C-e F). I'd like to create a _menu.org file that
contains some navigation links and #+INCLUDE: it (BTW. M-Tab can't
complete #+INC) in every single file I create and publish.


Maybe you can use link abbreviations and define the abbreviation  
differently for both cases.


- Carsten



The problem now looks like there should be separete _menu.org files  
for

each directory if I want to use relative paths in the menu links, that
work after local (C-c C-e h) and remote (C-c C-e h) export. When I put
absolute paths that work on

Let's say I've got a structure like this

~/WWW/index.org
~/WWW/_menu.org
~/stuff/index.org
~/things/index.org
~/problems/index.org

after publishing the index.org files are available at:

http://example.com/~stl/
http://example.com/~stl/stuff/
http://example.com/~stl/things/
http://example.com/~stl/problems/

respectively.

The _menu.org that works in the main index.org looks like this:

+ [[file:index.org][Home]]
+ [[file:stuff/index.org][Stuff]]
+ [[file:things/index.org][Things]]
+ [[file:problems/index.org][Problems]]

But when I #+INCLUDE it in the stuff/index.org file the links point at

http://example.com/~stl/stuff/index.html
http://example.com/~stl/stuff/stuff/index.html
http://example.com/~stl/stuff/things/index.html
http://example.com/~stl/stuff/problems/index.html

On the other hand if I replace file: links with absolute http: ones I
won't be able to navigate between the HTML files created locally with
C-c C-e h.

+ [[http://example.com/~stl/index.org][Home]]
+ [[http://example.com/~stl/stuff/index.org][Stuff]]
+ [[http://example.com/~stl/things/index.org][Things]]
+ [[http://example.com/~stl/problems/index.org][Problems]]

Is there any secret way to overcome such a problem?

--
Miłego dnia,
Łukasz Stelmach


___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


- Carsten




___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] Re: portable absolute links in HTML export

2010-10-07 Thread Łukasz Stelmach
Carsten Dominik carsten.domi...@gmail.com writes:

 On Oct 7, 2010, at 2:21 PM, Łukasz Stelmach wrote:

 Is there a simple way to create hyperlinks with *absolute* paths that
 would work after both: simple file export (C-c C-e h) and publishing
 on
 a remote server (C-c C-e F). I'd like to create a _menu.org file that
 contains some navigation links and #+INCLUDE: it (BTW. M-Tab can't
 complete #+INC) in every single file I create and publish.

 Maybe you can use link abbreviations and define the abbreviation
 differently for both cases.

Any suggestion where/when can I automatically alter
org-link-abbrev-alist for each of export procedures. Creating wrappers
around org-export-as-html* and org-publish* looks easy, except I'd have
to make my own copy of org-export to call them. Of course editing #+LINK
is also a not so bad option.

-- 
Miłego dnia,
Łukasz Stelmach


___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] Re: portable absolute links in HTML export

2010-10-07 Thread Łukasz Stelmach
Łukasz Stelmach lukasz.stelm...@iem.pw.edu.pl writes:

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

 On Oct 7, 2010, at 2:21 PM, Łukasz Stelmach wrote:

 Is there a simple way to create hyperlinks with *absolute* paths that
 would work after both: simple file export (C-c C-e h) and publishing
 on
 a remote server (C-c C-e F). I'd like to create a _menu.org file that
 contains some navigation links and #+INCLUDE: it (BTW. M-Tab can't
 complete #+INC) in every single file I create and publish.

 Maybe you can use link abbreviations and define the abbreviation
 differently for both cases.

 Any suggestion where/when can I automatically alter
 org-link-abbrev-alist for each of export procedures. 

No need to :-) In the main index.org i put

#+LINK examplewww: file:

and in the others

#+LINK examplewww: file:../

and it works :-)

Thanks a lot.
-- 
Miłego dnia,
Łukasz Stelmach


___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] Re: Bibtex and latex export

2010-10-07 Thread Nick Dokos
Eric S Fraga ucec...@ucl.ac.uk wrote:

 On Wed, 06 Oct 2010 19:21:33 +0200, Achim Gratz strom...@nexgo.de wrote:
  
  Hi Eric,
  
  Eric S Fraga ucec...@ucl.ac.uk writes:
   | /usr/bin/texi2dvi: Processing /home/ucecesf/.../file.tex ...
   | egrep: Invalid range end
   | /usr/bin/texi2dvi: cannot read .//home/ucecesf/.../file.tex, skipping.
  
  Something somewhere tries to make a local path from an absolute one by
  prepending ./, which fails (predictably).  Is the input readable at
  the original path?  Not sure the error message from egrep has to do with
  it or not, but it must be in any case one of the processes started by
  texi2dvi (does not show up on my system, I only have calls to grep when
  I trace it, but one of the sub-processes might still use it).  I think
  texi2dvi also invokes shell scripts, so any funny configuration in the
  environment, especially where path points to, could throw it off.
 
 As far as I know, there is nothing out of the ordinary with my paths
 etc (please note that the /.../ above was an edit on my part to hide a
 rather long path).  Any hints as to what I can do to explore this
 would be most helpful.  How can I get a trace on what texi2dvi is
 doing?  (sh -v /usr/bin/texi2dvi?)
 

There is an explicit egrep on line 1563 or thereabouts (my version
says

# texi2dvi --- produce DVI (or PDF) files from Texinfo (or (La)TeX) sources.
# $Id: texi2dvi,v 1.104 2007/09/10 00:36:30 karl Exp $

at the top of the file):


  # If the COMMAND_LINE_FILENAME is not absolute (e.g., --debug.tex),
  # prepend `./' in order to avoid that the tools take it as an option.
  echo $command_line_filename | $EGREP '^(/|[A-z]:/)' 6 \
  || command_line_filename=./$command_line_filename


The regular expression seems a bit weird (upper case A to lower case
z?), but I can't see off the top of my head how it gets tripped up.  For
tracing, try

   sh -x texi2dvi 

Nick

___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] Re: portable absolute links in HTML export

2010-10-07 Thread Łukasz Stelmach
Łukasz Stelmach lukasz.stelm...@iem.pw.edu.pl writes:

 Łukasz Stelmach lukasz.stelm...@iem.pw.edu.pl writes:

 In the main index.org i put

 #+LINK examplewww: file:

 and in the others

 #+LINK examplewww: file:../

 and it works :-)

As long as I don't use #+SETUPFILE.

-- 
Miłego dnia,
Łukasz Stelmach


___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] Re: [Org-Babel] Export environments for shell results?

2010-10-07 Thread Sébastien Vauban
Hi Dan,

Dan Davison wrote:
 Sébastien Vauban writes:
 #+TITLE: Org-Babel export environments for shell results

 * Example

 ** Medium output

 #+srcname: is-converted-to-listings
 #+begin_src sh :results output :exports both
 grep autoload ~/Downloads/emacs/site-lisp/org-mode/lisp/ob.el | cut -d # 
 -f 4
 #+end_src

 (It's nice that your email is in Org format; I can get the contents into an
 Org buffer quickly.

That's the goal, indeed. The quicker you can test, the quicker you can fix
and/or answer. So, it's a win-win. And it allows me to test any fix quickly as
well, and let you know. So, second win-win.

To be honest, I would even wanna go one (huge -- for me, at the moment) step
further (= bridge), and have made up some real test case in this document,
using ERT... and have a pass/fail table... But not able yet to do so...


 Could I ask you to make the source blocks reproducible in the future, so
 that we can execute them without having to alter file paths etc?)

Sure. I'll do.

Here, I could have used another file that I can expect to be always at a fixed
place (like grepping in ~/.emacs or some such).

Generally speaking, you'd want me to pass the path as an Org :var parameter?
Or using default environment vars from the system?


 #+results: is-converted-to-listings
 #+begin_example
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 #+end_example

 gets translated (in LaTeX) to:

 #+begin_src latex
 \begin{lstlisting}
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 \end{lstlisting}
 #+end_src

 ** Short output

 ... while

 #+srcname: is-converted-to-verbatim
 #+begin_src sh :results output :exports both
 grep autoload ~/Downloads/emacs/site-lisp/org-mode/lisp/ob.el | cut -d # 
 -f 4 | head -n 3
 #+end_src

 #+results: is-converted-to-verbatim
 : autoload
 : autoload
 : autoload

 gets translated (in LaTeX) to:

 #+begin_src latex
 \begin{verbatim}
  autoload
  autoload
  autoload
 \end{verbatim}
 #+end_src

 with a leading space (that you don't see when running the command in the
 shell).

 The only difference is the shell command is adding =head -n 3=.

 * Questions

 1. Why that difference of behavior?

 I suspect this is due to 

 org-babel-min-lines-for-block-output is a variable defined in `ob.el'.
 Its value is 10

 Documentation:
 The minimum number of lines for block output.
 If number of lines of output is equal to or exceeds this
 value, the output is placed in a #+begin_example...#+end_example
 block. Otherwise the output is marked as literal by inserting
 colons at the starts of the lines. This variable only takes
 effect if the :results output option is in effect.

OK. Did not know about that.

Not sure, though, that I understand the link between a certain number of
lines, and the type of block the result is wrapped in. I could easily imagine
that every such result would be wrapped in an example block, or -- the
opposite -- that it always is presented with a colon in front of every line.


 2. What's the determining factor for switching between =verbatim= and
=lstlisting= environments?

 I'm no expert on latex export. But if the colon form and the block form are
 equivalent in Org,

OK... In a way, you confirm my point of view, considering that both are
equivalent in Org...


 then perhaps it is a bug that they have non-equivalent latex export?

Exactly what I'm thinking...


 I didn't realise that begin_example resulted in a lstlisting environment
 when using listings with Org.

My only custom (AFAIK) is:

--8---cut here---start-8---
;; tell org to use listings (instead of verbatim) for source code
(setq org-export-latex-listings t)

;; if you want fontified source code, then you must include the
;; `listings' package
(add-to-list 'org-export-latex-packages-alist '( listings) t)

;; if you want colored source code, then you need to include the
;; `xcolor' package
(add-to-list 'org-export-latex-packages-alist '( xcolor) t)
--8---cut here---end---8---


 3. Why is there a leading space in the =verbatim= environment?

 I guess it is due to the space after the colon in the Org buffer.

I find it nice (not to say necessary) to have a space after the colon in the
Org buffer.

But, when exporting, as both have been added as a prefix in front of every
result line, both should be removed, ensuring no extra space in the LaTeX
output...

Thanks for your answer.

Best regards,
  Seb

-- 
Sébastien Vauban


___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org

Re: [Orgmode] Re: Bibtex and latex export

2010-10-07 Thread Eric S Fraga
On Thu, 07 Oct 2010 09:29:59 -0400, Nick Dokos nicholas.do...@hp.com wrote:
 
 Eric S Fraga ucec...@ucl.ac.uk wrote:
 
  On Wed, 06 Oct 2010 19:21:33 +0200, Achim Gratz strom...@nexgo.de wrote:
   
   Hi Eric,
   
   Eric S Fraga ucec...@ucl.ac.uk writes:
| /usr/bin/texi2dvi: Processing /home/ucecesf/.../file.tex ...
| egrep: Invalid range end
| /usr/bin/texi2dvi: cannot read .//home/ucecesf/.../file.tex, skipping.
   
   Something somewhere tries to make a local path from an absolute one by
   prepending ./, which fails (predictably).  Is the input readable at
   the original path?  Not sure the error message from egrep has to do with
   it or not, but it must be in any case one of the processes started by
   texi2dvi (does not show up on my system, I only have calls to grep when
   I trace it, but one of the sub-processes might still use it).  I think
   texi2dvi also invokes shell scripts, so any funny configuration in the
   environment, especially where path points to, could throw it off.
  
  As far as I know, there is nothing out of the ordinary with my paths
  etc (please note that the /.../ above was an edit on my part to hide a
  rather long path).  Any hints as to what I can do to explore this
  would be most helpful.  How can I get a trace on what texi2dvi is
  doing?  (sh -v /usr/bin/texi2dvi?)
  
 
 There is an explicit egrep on line 1563 or thereabouts (my version
 says
 
 # texi2dvi --- produce DVI (or PDF) files from Texinfo (or (La)TeX) sources.
 # $Id: texi2dvi,v 1.104 2007/09/10 00:36:30 karl Exp $
 
 at the top of the file):
 
 
   # If the COMMAND_LINE_FILENAME is not absolute (e.g., --debug.tex),
   # prepend `./' in order to avoid that the tools take it as an option.
   echo $command_line_filename | $EGREP '^(/|[A-z]:/)' 6 \
   || command_line_filename=./$command_line_filename
 
 
 The regular expression seems a bit weird (upper case A to lower case
 z?), but I can't see off the top of my head how it gets tripped up.  For
 tracing, try
 
sh -x texi2dvi 
 
 Nick

Thanks Nick.  If I do this:

: (setq org-latex-to-pdf-process '(sh -x /usr/bin/texi2dvi -p -b -c -V %f))

the following is a snippet of the output:

,
| + echo /home/ucecesf/s/teaching/cape/lectures/matlab.tex+ egrep ^(/|[A-z]:/)
| egrep: Invalid range end
| + command_line_filename=.//home/ucecesf/s/teaching/cape/lectures/matlab.tex
| + test -r .//home/ucecesf/s/teaching/cape/lectures/matlab.tex
| + error 1 cannot read .//home/ucecesf/s/teaching/cape/lectures/matlab.tex, 
skipping.
`

Because the egrep fails completely, the script assumes that it does
need to prepend ./ to the file name even though the file name
already starts with / (and is definitely *not* a DOS type file name
;-).

I don't understand why the egrep is failing although it definitely has
something to do with A-z range; if I try the egrep at the shell and
use A-Za-z instead of A-z, the command works fine.  Does it work
for anybody else on Linux?

I wonder if the problem with the range is locale dependent?  My locale
is en_GB.UTF-8.  The manual page for egrep does indicate that ranges
may not mean the same thing in different locales and suggests using
locale C.  I don't want to change my locale but maybe it could be set
for the invocation of texi2dvi...  (yech).

This is obviously not an org problem as such but I am surprised it's
working for anybody at all...

I guess I'll stick to multiple invocations of pdflatex directly for
the time being.

cheers,
eric
-- 
Eric S Fraga
GnuPG: 8F5C 279D 3907 E14A 5C29  570D C891 93D8 FFFC F67D
___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] [babel] Writing R-packages the org way?

2010-10-07 Thread Rainer M Krug
Hi

I am about to write an R package, and as I am an org-mode and org-babel
user, I would (obviously) like to use org-mode for that.

Is there a recommended way of writing an R package in org-babel, or do I
have effectively wrap the R code for the documentation etc. into source
blocks in babel?

Any suggestions how to best proceed?

Dream: I would like to have one org file which contains everything
(documentation, code, other relevant files) and if I export or tangle the
file, I have the package ready.

Is there anything like that?

Rainer

-- 
NEW GERMAN FAX NUMBER!!!

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

Centre of Excellence for Invasion Biology
Natural Sciences Building
Office Suite 2039
Stellenbosch University
Main Campus, Merriman Avenue
Stellenbosch
South Africa

Cell:   +27 - (0)83 9479 042
Fax:+27 - (0)86 516 2782
Fax:+49 - (0)321 2125 2244
email:  rai...@krugs.de

Skype:  RMkrug
Google: r.m.k...@gmail.com
___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] Re: Bibtex and latex export

2010-10-07 Thread Nick Dokos
Eric S Fraga ucec...@ucl.ac.uk wrote:

 : (setq org-latex-to-pdf-process '(sh -x /usr/bin/texi2dvi -p -b -c -V %f))
 
 the following is a snippet of the output:
 
 ,
 | + echo /home/ucecesf/s/teaching/cape/lectures/matlab.tex+ egrep ^(/|[A-z]:/)
 | egrep: Invalid range end
 | + command_line_filename=.//home/ucecesf/s/teaching/cape/lectures/matlab.tex
 | + test -r .//home/ucecesf/s/teaching/cape/lectures/matlab.tex
 | + error 1 cannot read .//home/ucecesf/s/teaching/cape/lectures/matlab.tex, 
 skipping.
 `
 

What's that '+' sign at the end of the path? 

 Because the egrep fails completely, the script assumes that it does
 need to prepend ./ to the file name even though the file name
 already starts with / (and is definitely *not* a DOS type file name
 ;-).
 
 I don't understand why the egrep is failing although it definitely has
 something to do with A-z range; if I try the egrep at the shell and
 use A-Za-z instead of A-z, the command works fine.  Does it work
 for anybody else on Linux?
 
I'm using en_US.UTF-8  on Ubuntu 8.10 and it seems to work for me.

The regexp does look funny: there are non-letters included in the
range and it may be that different versions of egrep are more or less
strict in checking it. I would change the texi2dvi script to use [A-Za-z]
and submit a bug report to texinfo.

 I wonder if the problem with the range is locale dependent?  My locale
 is en_GB.UTF-8.  The manual page for egrep does indicate that ranges
 may not mean the same thing in different locales and suggests using
 locale C.  I don't want to change my locale but maybe it could be set
 for the invocation of texi2dvi...  (yech).
 

You can always change the LOCALE just for the texi2dvi invocation.
I believe that the following works (untested):

LANG=C texi2dvi 

or maybe

LC_ALL=C texi2dvi ...

Nick

___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] [babel] Writing R-packages the org way?

2010-10-07 Thread Erik Iverson



Rainer M Krug wrote:

Hi

I am about to write an R package, and as I am an org-mode and org-babel 
user, I would (obviously) like to use org-mode for that.


Is there a recommended way of writing an R package in org-babel, or do I 
have effectively wrap the R code for the documentation etc. into source 
blocks in babel?


That's what I do.  I've looked into converting an org-file to
Roxygen or Rd markup, but never got very far.  My idea at the time
was to do something like:

* function1
** Help
*** Title
this is function 1 title
*** Description
function1 does this...
*** Usage
function1(arg1, arg2, ...)
*** Arguments
arg1: the first argument
*** Examples
function1(arg1 = x, arg2 = y)
**Definition
begin_src R :tangle R/package.R
function1 - function(arg1, arg2) {

}




Any suggestions how to best proceed?

Dream: I would like to have one org file which contains everything 
(documentation, code, other relevant files) and if I export or tangle 
the file, I have the package ready.


Well, that functionality is essentially present with code blocks
and tangling, except the documentation part.



Is there anything like that?

Rainer

--
NEW GERMAN FAX NUMBER!!!

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


Centre of Excellence for Invasion Biology
Natural Sciences Building
Office Suite 2039
Stellenbosch University
Main Campus, Merriman Avenue
Stellenbosch
South Africa

Cell:   +27 - (0)83 9479 042
Fax:+27 - (0)86 516 2782
Fax:+49 - (0)321 2125 2244
email:  rai...@krugs.de mailto:rai...@krugs.de

Skype:  RMkrug
Google: r.m.k...@gmail.com mailto:r.m.k...@gmail.com




___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] Re: [babel] Writing R-packages the org way?

2010-10-07 Thread Dan Davison
Rainer M Krug r.m.k...@gmail.com writes:

 Hi

 I am about to write an R package, and as I am an org-mode and org-babel
 user, I would (obviously) like to use org-mode for that.

 Is there a recommended way of writing an R package in org-babel, or do I
 have effectively wrap the R code for the documentation etc. into source
 blocks in babel?

 Any suggestions how to best proceed?

 Dream: I would like to have one org file which contains everything
 (documentation, code, other relevant files) and if I export or tangle the
 file, I have the package ready.

 Is there anything like that?

Hi Rainer,

This sounds like a seriously good idea, and I wish it already
existed. However...not as far as I know. I'd be very happy to help in
any way I can if you decide to take this on.

Dan


 Rainer

___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] Re: Bibtex and latex export

2010-10-07 Thread Eric S Fraga
On Thu, 07 Oct 2010 10:22:25 -0400, Nick Dokos nicholas.do...@hp.com wrote:
 
 Eric S Fraga ucec...@ucl.ac.uk wrote:
 
  : (setq org-latex-to-pdf-process '(sh -x /usr/bin/texi2dvi -p -b -c -V 
  %f))
  
  the following is a snippet of the output:
  
  ,
  | + echo /home/ucecesf/s/teaching/cape/lectures/matlab.tex+ egrep 
  ^(/|[A-z]:/)
  | egrep: Invalid range end
  | + 
  command_line_filename=.//home/ucecesf/s/teaching/cape/lectures/matlab.tex
  | + test -r .//home/ucecesf/s/teaching/cape/lectures/matlab.tex
  | + error 1 cannot read 
  .//home/ucecesf/s/teaching/cape/lectures/matlab.tex, skipping.
  `
  
 
 What's that '+' sign at the end of the path? 

I think that's sh -x indicating a | between commands; it's not
actually in the file name.  Mind you, even if it were part of the file
name, things should work (well, maybe not latex itself...).

  I don't understand why the egrep is failing although it definitely has
  something to do with A-z range; if I try the egrep at the shell and
  use A-Za-z instead of A-z, the command works fine.  Does it work
  for anybody else on Linux?
  
 I'm using en_US.UTF-8  on Ubuntu 8.10 and it seems to work for me.

Interesting.

 The regexp does look funny: there are non-letters included in the
 range and it may be that different versions of egrep are more or less
 strict in checking it. I would change the texi2dvi script to use [A-Za-z]
 and submit a bug report to texinfo.

I think I will do so.  The thing is that the check is very much for
DOS file names so I don't actually care what that part of the regex is
doing!

 You can always change the LOCALE just for the texi2dvi invocation.
 I believe that the following works (untested):
 
 LANG=C texi2dvi 
 
 or maybe
 
 LC_ALL=C texi2dvi ...

but this may have unexpected side effects?  I'm not sure if any of the
latex suite use the locale...

Thanks again,
eric
-- 
Eric S Fraga
GnuPG: 8F5C 279D 3907 E14A 5C29  570D C891 93D8 FFFC F67D
___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] Re: Bibtex and latex export

2010-10-07 Thread Nick Dokos
Eric S Fraga ucec...@ucl.ac.uk wrote:

  ... I would change the texi2dvi script to use [A-Za-z]
  and submit a bug report to texinfo.
 
 I think I will do so.  The thing is that the check is very much for
 DOS file names so I don't actually care what that part of the regex is
 doing!
 

M$ will get you one way or another :-)

BTW, if you do

 echo /foo | egrep '^(/|[A-z]:/)'

do you get the bad range end error message? If so, then your egrep
is indeed stricter than mine.

  LC_ALL=C texi2dvi ...
 
 but this may have unexpected side effects?  I'm not sure if any of the
 latex suite use the locale...
 

Yeah, perhaps...

Nick

___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] Re: Tracking time with MobileOrg

2010-10-07 Thread Ilya Shlyakhter
Richard Moreland rlm at ncogni.to writes:
 My plan for the UI is this:

Thanks a lot for working on this.

It would also be useful to have commands to adjust the clock log:
delete a clock entry, subtract some duration from it (if you got distracted
with another task for a while), adjust its endpoints.

ilya


___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] Re: [babel] Writing R-packages the org way?

2010-10-07 Thread Dan Davison
Erik Iverson er...@ccbr.umn.edu writes:

 Rainer M Krug wrote:
 Hi

 I am about to write an R package, and as I am an org-mode and
 org-babel user, I would (obviously) like to use org-mode for that.

 Is there a recommended way of writing an R package in org-babel, or
 do I have effectively wrap the R code for the documentation
 etc. into source blocks in babel?

 That's what I do.  I've looked into converting an org-file to
 Roxygen or Rd markup, but never got very far.  My idea at the time
 was to do something like:

 * function1
 ** Help
 *** Title
 this is function 1 title
 *** Description
 function1 does this...
 *** Usage
 function1(arg1, arg2, ...)
 *** Arguments
 arg1: the first argument
 *** Examples
 function1(arg1 = x, arg2 = y)
 **Definition
 begin_src R :tangle R/package.R
 function1 - function(arg1, arg2) {

 }



 Any suggestions how to best proceed?

 Dream: I would like to have one org file which contains everything
 (documentation, code, other relevant files) and if I export or
 tangle the file, I have the package ready.

 Well, that functionality is essentially present with code blocks
 and tangling, except the documentation part.

Hi Erik,

Would you mind expanding on that -- what are we missing for the
documentation part?

Dan

___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] Re: [babel] Writing R-packages the org way?

2010-10-07 Thread Erik Iverson


Dan Davison wrote:

Erik Iverson er...@ccbr.umn.edu writes:


Rainer M Krug wrote:

Hi

I am about to write an R package, and as I am an org-mode and
org-babel user, I would (obviously) like to use org-mode for that.

Is there a recommended way of writing an R package in org-babel, or
do I have effectively wrap the R code for the documentation
etc. into source blocks in babel?

That's what I do.  I've looked into converting an org-file to
Roxygen or Rd markup, but never got very far.  My idea at the time
was to do something like:

* function1
** Help
*** Title
this is function 1 title
*** Description
function1 does this...
*** Usage
function1(arg1, arg2, ...)
*** Arguments
arg1: the first argument
*** Examples
function1(arg1 = x, arg2 = y)
**Definition
begin_src R :tangle R/package.R
function1 - function(arg1, arg2) {

}



Any suggestions how to best proceed?

Dream: I would like to have one org file which contains everything
(documentation, code, other relevant files) and if I export or
tangle the file, I have the package ready.

Well, that functionality is essentially present with code blocks
and tangling, except the documentation part.


Hi Erik,

Would you mind expanding on that -- what are we missing for the
documentation part?



Dan, by except for the documentation part, I meant generating
.Rd files (the LaTeX-like syntax) automatically from some org-syntax
that does *not* depend on code blocks.  I.e., it would be cool to
specify syntax like I have above for documentation.  Using org-mode
headlines for each section like Description, Usage, Arguments, etc.

Just like exporting to LaTeX generates sections, some process would
use these headlines to generate the .Rd sections.

That way, you don't have to use the .Rd syntax yourself.  No big deal,
just a convenience feature.  I don't know how you'd specify to org-mode
that a particular subtree was to generate .Rd syntax, and I don't know
if it would be on export or tangling.

An alternative is simply just to use code blocks of type Rd within
org-mode and then tangle to .Rd files.  That's what I currently do.

Hope that explains it,
Erik



Dan


___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] Re: [babel] Writing R-packages the org way?

2010-10-07 Thread Dan Davison
Erik Iverson er...@ccbr.umn.edu writes:

 Dan Davison wrote:
 Erik Iverson er...@ccbr.umn.edu writes:

 Rainer M Krug wrote:
 Hi

 I am about to write an R package, and as I am an org-mode and
 org-babel user, I would (obviously) like to use org-mode for that.

 Is there a recommended way of writing an R package in org-babel, or
 do I have effectively wrap the R code for the documentation
 etc. into source blocks in babel?
 That's what I do.  I've looked into converting an org-file to
 Roxygen or Rd markup, but never got very far.  My idea at the time
 was to do something like:

 * function1
 ** Help
 *** Title
 this is function 1 title
 *** Description
 function1 does this...
 *** Usage
 function1(arg1, arg2, ...)
 *** Arguments
 arg1: the first argument
 *** Examples
 function1(arg1 = x, arg2 = y)
 **Definition
 begin_src R :tangle R/package.R
 function1 - function(arg1, arg2) {

 }


 Any suggestions how to best proceed?

 Dream: I would like to have one org file which contains everything
 (documentation, code, other relevant files) and if I export or
 tangle the file, I have the package ready.
 Well, that functionality is essentially present with code blocks
 and tangling, except the documentation part.

 Hi Erik,

 Would you mind expanding on that -- what are we missing for the
 documentation part?


 Dan, by except for the documentation part, I meant generating
 .Rd files (the LaTeX-like syntax) automatically from some org-syntax
 that does *not* depend on code blocks.  I.e., it would be cool to
 specify syntax like I have above for documentation.  Using org-mode
 headlines for each section like Description, Usage, Arguments, etc.

 Just like exporting to LaTeX generates sections, some process would
 use these headlines to generate the .Rd sections.

 That way, you don't have to use the .Rd syntax yourself.  No big deal,
 just a convenience feature.  I don't know how you'd specify to org-mode
 that a particular subtree was to generate .Rd syntax, and I don't know
 if it would be on export or tangling.

 An alternative is simply just to use code blocks of type Rd within
 org-mode and then tangle to .Rd files.  That's what I currently do.

 Hope that explains it,

Yes perfectly, thanks. I had only thought of the solution you mention
involving writing Rd explicitly; I hadn't thought of Rd as an export
target.

Well, anyone who wants to put Bastien's new export machinery to the
test, I'll have a texinfo and an Rd backend please.

:)

Dan

 Erik  Dan
 ___
 Emacs-orgmode mailing list
 Please use `Reply All' to send replies to the list.
 Emacs-orgmode@gnu.org
 http://lists.gnu.org/mailman/listinfo/emacs-orgmode

___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] Re: [babel] Writing R-packages the org way?

2010-10-07 Thread Rainer M Krug
On Thu, Oct 7, 2010 at 5:12 PM, Erik Iverson er...@ccbr.umn.edu wrote:


 Dan Davison wrote:

 Erik Iverson er...@ccbr.umn.edu writes:

  Rainer M Krug wrote:

 Hi

 I am about to write an R package, and as I am an org-mode and
 org-babel user, I would (obviously) like to use org-mode for that.

 Is there a recommended way of writing an R package in org-babel, or
 do I have effectively wrap the R code for the documentation
 etc. into source blocks in babel?

 That's what I do.  I've looked into converting an org-file to
 Roxygen or Rd markup, but never got very far.  My idea at the time
 was to do something like:

 * function1
 ** Help
 *** Title
this is function 1 title
 *** Description
function1 does this...
 *** Usage
function1(arg1, arg2, ...)
 *** Arguments
arg1: the first argument
 *** Examples
function1(arg1 = x, arg2 = y)
 **Definition
begin_src R :tangle R/package.R
function1 - function(arg1, arg2) {

}


I like the idea of a kind of template, which takes the function name as a
parameter and expands it to the above described structure, but also
including one section for tests.
That would definitely be a starting point from which one could look into the
problem of the .Rd files. As I am not an emacs / elisp expert, how could
that be done (the template)?




  Any suggestions how to best proceed?

 Dream: I would like to have one org file which contains everything
 (documentation, code, other relevant files) and if I export or
 tangle the file, I have the package ready.

 Well, that functionality is essentially present with code blocks
 and tangling, except the documentation part.


Exactly - and that is the part I would like to have.



 Hi Erik,

 Would you mind expanding on that -- what are we missing for the
 documentation part?


 Dan, by except for the documentation part, I meant generating
 .Rd files (the LaTeX-like syntax) automatically from some org-syntax
 that does *not* depend on code blocks.  I.e., it would be cool to
 specify syntax like I have above for documentation.  Using org-mode
 headlines for each section like Description, Usage, Arguments, etc.

 Just like exporting to LaTeX generates sections, some process would
 use these headlines to generate the .Rd sections.

 That way, you don't have to use the .Rd syntax yourself.  No big deal,
 just a convenience feature.  I don't know how you'd specify to org-mode
 that a particular subtree was to generate .Rd syntax, and I don't know
 if it would be on export or tangling.

 An alternative is simply just to use code blocks of type Rd within
 org-mode and then tangle to .Rd files.  That's what I currently do.

 Hope that explains it,
 Erik


  Dan




-- 
NEW GERMAN FAX NUMBER!!!

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

Centre of Excellence for Invasion Biology
Natural Sciences Building
Office Suite 2039
Stellenbosch University
Main Campus, Merriman Avenue
Stellenbosch
South Africa

Cell:   +27 - (0)83 9479 042
Fax:+27 - (0)86 516 2782
Fax:+49 - (0)321 2125 2244
email:  rai...@krugs.de

Skype:  RMkrug
Google: r.m.k...@gmail.com
___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] Re: [babel] Writing R-packages the org way?

2010-10-07 Thread Rainer M Krug
On Thu, Oct 7, 2010 at 5:59 PM, Dan Davison davi...@stats.ox.ac.uk wrote:

 Erik Iverson er...@ccbr.umn.edu writes:

  Dan Davison wrote:
  Erik Iverson er...@ccbr.umn.edu writes:
 
  Rainer M Krug wrote:
  Hi
 
  I am about to write an R package, and as I am an org-mode and
  org-babel user, I would (obviously) like to use org-mode for that.
 
  Is there a recommended way of writing an R package in org-babel, or
  do I have effectively wrap the R code for the documentation
  etc. into source blocks in babel?
  That's what I do.  I've looked into converting an org-file to
  Roxygen or Rd markup, but never got very far.  My idea at the time
  was to do something like:
 
  * function1
  ** Help
  *** Title
  this is function 1 title
  *** Description
  function1 does this...
  *** Usage
  function1(arg1, arg2, ...)
  *** Arguments
  arg1: the first argument
  *** Examples
  function1(arg1 = x, arg2 = y)
  **Definition
  begin_src R :tangle R/package.R
  function1 - function(arg1, arg2) {
 
  }
 
 
  Any suggestions how to best proceed?
 
  Dream: I would like to have one org file which contains everything
  (documentation, code, other relevant files) and if I export or
  tangle the file, I have the package ready.
  Well, that functionality is essentially present with code blocks
  and tangling, except the documentation part.
 
  Hi Erik,
 
  Would you mind expanding on that -- what are we missing for the
  documentation part?
 
 
  Dan, by except for the documentation part, I meant generating
  .Rd files (the LaTeX-like syntax) automatically from some org-syntax
  that does *not* depend on code blocks.  I.e., it would be cool to
  specify syntax like I have above for documentation.  Using org-mode
  headlines for each section like Description, Usage, Arguments, etc.
 
  Just like exporting to LaTeX generates sections, some process would
  use these headlines to generate the .Rd sections.
 
  That way, you don't have to use the .Rd syntax yourself.  No big deal,
  just a convenience feature.  I don't know how you'd specify to org-mode
  that a particular subtree was to generate .Rd syntax, and I don't know
  if it would be on export or tangling.
 
  An alternative is simply just to use code blocks of type Rd within
  org-mode and then tangle to .Rd files.  That's what I currently do.
 
  Hope that explains it,

 Yes perfectly, thanks. I had only thought of the solution you mention
 involving writing Rd explicitly; I hadn't thought of Rd as an export
 target.


I would not say that an Rd export target would be the solution, as only
parts of the document have to exported to .Rd format, and others (the code)
has to be tangled --- well, I guess one could do it in a two step process:
first exporting to .Rd based on the headers, and then tangling the code
blocks (which were not exported) into the same structure.



 Well, anyone who wants to put Bastien's new export machinery to the
 test, I'll have a texinfo and an Rd backend please.


Agreed.



 :)

 Dan

  Erik  Dan
  ___
  Emacs-orgmode mailing list
  Please use `Reply All' to send replies to the list.
  Emacs-orgmode@gnu.org
  http://lists.gnu.org/mailman/listinfo/emacs-orgmode




-- 
NEW GERMAN FAX NUMBER!!!

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

Centre of Excellence for Invasion Biology
Natural Sciences Building
Office Suite 2039
Stellenbosch University
Main Campus, Merriman Avenue
Stellenbosch
South Africa

Cell:   +27 - (0)83 9479 042
Fax:+27 - (0)86 516 2782
Fax:+49 - (0)321 2125 2244
email:  rai...@krugs.de

Skype:  RMkrug
Google: r.m.k...@gmail.com
___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] Re: Bibtex and latex export

2010-10-07 Thread Eric S Fraga
On Thu, 07 Oct 2010 10:43:21 +0200, Sébastien Vauban 
wxhgmqzgw...@spammotel.com wrote:
 
 Hi Eric,
 
 Eric S Fraga wrote:
  As far as I know, there is nothing out of the ordinary with my paths etc
  (please note that the /.../ above was an edit on my part to hide a rather
  long path). Any hints as to what I can do to explore this would be most
  helpful. How can I get a trace on what texi2dvi is doing? (sh -v
  /usr/bin/texi2dvi?)
 
 I tried:
 
 #+begin_src emacs-lisp
 (setq org-latex-to-pdf-process '(sh -v -x texi2dvi -p -b -c -V %f))
 #+end_src
 
 and only see the following in *Messages*:

You can see the full output in the special buffer org creates: 
: *Org PDF LaTeX Output*
All the output from the actual commands, such as the following, is
placed in this buffer.  Very useful for when there are problems with
the latex.

,
| This is pdfTeX, Version 3.1415926-1.40.10 (TeX Live 2009/Debian)
|  restricted \write18 enabled.
| entering extended mode
| (/home/ucecesf/s/teaching/cape/lectures/matlab.tex
| LaTeX2e 2009/09/24
| Babel v3.8l and hyphenation patterns for english, usenglishmax, dumylang, 
noh
| yphenation, loaded.
| (/usr/share/texmf/tex/latex/beamer/base/beamer.cls
| (/usr/share/texmf/tex/latex/beamer/base/beamerbasercs.sty)
`

This is different from the messages generated by the elisp code which
appear in *Messages*.
-- 
Eric S Fraga
GnuPG: 8F5C 279D 3907 E14A 5C29  570D C891 93D8 FFFC F67D
___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] Re: Bibtex and latex export

2010-10-07 Thread Achim Gratz
Eric S Fraga ucec...@ucl.ac.uk writes:
 I think I will do so.  The thing is that the check is very much for
 DOS file names so I don't actually care what that part of the regex is
 doing!

Since texi2dvi is not fixing a locale this is clearly a bug that you
should report.  It should use character classes instead.  Why your
version of egrep complains about the range expression is not clear to me
(it may be locale dependent behaviour, but not syntactically an invalid
range expression), but you could check LC_COLLATE if z gets sorted
before A.  I have an older version of egrep that will simply ignore
the range in this case and never match, but it certainly doesn't throw
an error.  Maybe this was changed to weed out bad regex's... :-)

 but this may have unexpected side effects?  I'm not sure if any of the
 latex suite use the locale...

I'd be wary of that, too.  If anything you might precede just the call to
egrep by LC_ALL=C.


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

Wavetables for the Waldorf Blofeld:
http://Synth.Stromeko.net/Downloads.html#BlofeldUserWavetables


___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] [BUG] latex export of verbatim environments

2010-10-07 Thread Dan Davison


 #+results: is-converted-to-listings
 #+begin_example
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 #+end_example

 gets translated (in LaTeX) to:

 #+begin_src latex
 \begin{lstlisting}
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 autoload
 \end{lstlisting}
 #+end_src

 ** Short output

 ... while

 #+srcname: is-converted-to-verbatim
 #+begin_src sh :results output :exports both
 grep autoload ~/Downloads/emacs/site-lisp/org-mode/lisp/ob.el | cut -d # 
 -f 4 | head -n 3
 #+end_src

 #+results: is-converted-to-verbatim
 : autoload
 : autoload
 : autoload

 gets translated (in LaTeX) to:

 #+begin_src latex
 \begin{verbatim}
  autoload
  autoload
  autoload
 \end{verbatim}
 #+end_src

 with a leading space (that you don't see when running the command in the
 shell).

 2. What's the determining factor for switching between =verbatim= and
=lstlisting= environments?

 I'm no expert on latex export. But if the colon form and the block form are
 equivalent in Org,

 OK... In a way, you confirm my point of view, considering that both are
 equivalent in Org...


 then perhaps it is a bug that they have non-equivalent latex export?

 Exactly what I'm thinking...


 I didn't realise that begin_example resulted in a lstlisting environment
 when using listings with Org.

 My only custom (AFAIK) is:

 ;; tell org to use listings (instead of verbatim) for source code
 (setq org-export-latex-listings t)

 ;; if you want fontified source code, then you must include the
 ;; `listings' package
 (add-to-list 'org-export-latex-packages-alist '( listings) t)

 ;; if you want colored source code, then you need to include the
 ;; `xcolor' package
 (add-to-list 'org-export-latex-packages-alist '( xcolor) t)


 3. Why is there a leading space in the =verbatim= environment?

 I guess it is due to the space after the colon in the Org buffer.

 I find it nice (not to say necessary) to have a space after the colon in the
 Org buffer.

 But, when exporting, as both have been added as a prefix in front of every
 result line, both should be removed, ensuring no extra space in the LaTeX
 output...

OK, I think the conclusion of this that

1. It does not reveal a bug in babel.
2. There may be a bug in the listings export code in that it fails to
   recognise colons as a verbatim environment
3. There may be a second bug in the vanilla latex export code in that it
   should remove the space which follows the protective colon.

Dan


 Thanks for your answer.

 Best regards,
   Seb


___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] Re: [Babel] Handling of errors when using Ledger

2010-10-07 Thread Dan Davison


Sébastien Vauban wxhgmqzgwmuf-genee64ty+gs+fvcfc7...@public.gmane.org
writes:
[...]
 Let's imagine I thought (which was the case at some point) I needed to enclose
 the parameters between quotes:

 #+srcname: quoted-params
 #+begin_src ledger :cmdline reg unknown :noweb yes :session
 data
 #+end_src

 #+results: quoted-params

 Nothing is returned. In fact, I would expect an error to be thrown, the same
[...]
 I don't know if this is a common problem (to Org-Babel) or only to the Ledger
 part of it, but I think *we* should somehow improve the handling of errors.

Hi Seb,

Babel has a standard mechanism for evaluating shell commands and
displaying errors if any. It is the function `org-babel-eval' in
ob-eval.el. The problem is that ob-ledger is not using this
mechanism. Would you be interested in fixing this? Basically what is
required is to re-implement `org-babel-execute:ledger' using
`org-babel-eval'. (There are plenty of examples in the other langauges
to follow.) Please don't worry if you are too busy though.

 - Maybe displaying a =#+results-err= block which would be what's shown on
   =/dev/stderr=, when not void?

I've vaguely wondered about this sort of thing in the past. The thing is
that that's getting close to the idea of proper exception handling in
Org-babel. That would certainly be interesting, and I'm sure we would
welcome well thought-through proposals on the topic. It would need to
deal with errors occurring in a block anywhere in the `call tree'
(e.g. what happens when block A is evaluated and A references blocks B
and C, and B references D and an error occurs in D)

 - And having a way to display the error code would be a plus.

That will happen automatically when ledger is converted to use
`org-babel-eval'.

Dan


 Best regards,
   Seb


___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] Re: [Org-Babel] Export environments for shell results?

2010-10-07 Thread Dan Davison


 Could I ask you to make the source blocks reproducible in the future, so
 that we can execute them without having to alter file paths etc?)

 Sure. I'll do.

 Here, I could have used another file that I can expect to be always at a fixed
 place (like grepping in ~/.emacs or some such).

 Generally speaking, you'd want me to pass the path as an Org :var parameter?
 Or using default environment vars from the system?

If possible, avoid using system paths at all. The behaviour you describe
can be replicated with something like

#+begin_src sh :results output
  for i in `seq 1 4`; do
  echo autoload
  done
#+end_src

#+results:
: autoload
: autoload
: autoload
: autoload

Dan


___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] Bug: wl: links only work with wl running [7.01trans]

2010-10-07 Thread David Abrahams


Remember to cover the basics, that is, what you expected to happen and
what in fact did happen.  You don't know how to make a good report?  See

 http://orgmode.org/manual/Feedback.html#Feedback

Your bug report will be posted to the Org-mode mailing list.


Today I tried to follow an org link and got this:
org-id-open: Cannot find entry with ID 
201010060532.amj65...@mr17.lnh.mail.rcn.net|references:201010060532.amj65...@mr17.lnh.mail.rcn.net/%[Gmail]/All
 mail#201010060532.amj65...@mr17.lnh.mail.rcn.net
It turned out that it wouldn't work until after I invoked `M-x wl'
explicitly.  I usually have it running so normally wouldn't notice,
but this seems like a bug anyway.

Emacs  : GNU Emacs 23.2.1 (x86_64-apple-darwin, NS apple-appkit-1038.29)
 of 2010-05-08 on black.local
Package: Org-mode version 7.01trans

current state:
==
(setq
 org-agenda-deadline-leaders '(D:  D%d: )
 org-clock-in-switch-to-state STARTED
 org-agenda-skip-scheduled-if-deadline-is-shown t
 org-export-latex-after-initial-vars-hook '(org-beamer-after-initial-vars)
 org-todo-keyword-faces '((TODO :foreground medium blue :weight bold)
  (APPT :foreground medium blue :weight bold)
  (NOTE :foreground brown :weight bold)
  (STARTED :foreground dark orange :weight bold)
  (WAITING :foreground red :weight bold)
  (DELEGATED :foreground dark violet :weight bold)
  (DEFERRED :foreground dark blue :weight bold)
  (SOMEDAY :foreground dark blue :weight bold)
  (PROJECT :height 1.5 :weight bold :foreground 
black))
 org-agenda-custom-commands '((E Errands (next 3 days) tags
   
ErrandTODO\DONE\TODO\CANCELLED\STYLE\habit\SCHEDULED\+3d\
   ((org-agenda-overriding-header Errands (next 3 
days))

 )
   )
  (A Priority #A tasks agenda 
   ((org-agenda-ndays 1)
(org-agenda-overriding-header Today's priority 
#A tasks: )
(org-agenda-skip-function
 (quote (org-agenda-skip-entry-if (quote 
notregexp) \\=.*\\[#A\\]))
 )
)
   )
  (B Priority #A and #B tasks agenda 
   ((org-agenda-ndays 1)
(org-agenda-overriding-header Today's priority 
#A and #B tasks: )
(org-agenda-skip-function
 (quote (org-agenda-skip-entry-if (quote 
regexp) \\=.*\\[#C\\])))
)
   )
  (w Waiting/delegated tasks tags
   TODO=\WAITING\|TODO=\DELEGATED\
   ((org-agenda-overriding-header 
Waiting/delegated tasks:)
(org-agenda-sorting-strategy
 (quote (todo-state-up priority-down 
category-up)))
)
   )
  (u Unscheduled tasks tags
   
TODO\\TODO\DONE\TODO\CANCELLED\TODO\NOTE\CATEGORY{CEG\\|ABC\\|Bizcard\\|Adagio\\|EVAprint\\|\\IT\\}
   ((org-agenda-overriding-header Unscheduled 
tasks: )


  
(org-agenda-skip-function

   

   
(quote








 

Re: [Orgmode] Re: Bibtex and latex export

2010-10-07 Thread Eric S Fraga
On Thu, 07 Oct 2010 10:37:52 -0400, Nick Dokos nicholas.do...@hp.com wrote:
 
 Eric S Fraga ucec...@ucl.ac.uk wrote:
 
   ... I would change the texi2dvi script to use [A-Za-z]
   and submit a bug report to texinfo.
  
  I think I will do so.  The thing is that the check is very much for
  DOS file names so I don't actually care what that part of the regex is
  doing!
  
 
 M$ will get you one way or another :-)
 
 BTW, if you do
 
  echo /foo | egrep '^(/|[A-z]:/)'
 
 do you get the bad range end error message? If so, then your egrep
 is indeed stricter than mine.

I do indeed:

: egrep: Invalid range end.

Very strange.

   LC_ALL=C texi2dvi ...
  
  but this may have unexpected side effects?  I'm not sure if any of the
  latex suite use the locale...
 
 Yeah, perhaps...

Interestingly, it *is* a locale issue:

: $ echo /foo | LC_ALL=C egrep '^(/|[A-z]:/)'
: /foo

-- 
Eric S Fraga
GnuPG: 8F5C 279D 3907 E14A 5C29  570D C891 93D8 FFFC F67D
___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] Re: Bibtex and latex export

2010-10-07 Thread Nick Dokos
Eric S Fraga ucec...@ucl.ac.uk wrote:

   echo /foo | egrep '^(/|[A-z]:/)'
  
  do you get the bad range end error message? If so, then your egrep
  is indeed stricter than mine.
 
 I do indeed:
 
 : egrep: Invalid range end.
 
 Very strange.
 
LC_ALL=C texi2dvi ...
   
   but this may have unexpected side effects?  I'm not sure if any of the
   latex suite use the locale...
  
  Yeah, perhaps...
 
 Interestingly, it *is* a locale issue:
 
 : $ echo /foo | LC_ALL=C egrep '^(/|[A-z]:/)'
 : /foo
 

Yup: the egrep man page says

,
| Within a bracket expression, a range expression consists of two
| characters separated by a hyphen.  It matches any single character that
| sorts between the two characters, inclusive, using the locale’s
| collating sequence and character set.  For example, in the default C
| locale, [a-d] is equivalent to [abcd].  Many locales sort characters in
| dictionary order, and in these locales [a-d] is typically not equivalent
| to [abcd]; it might be equivalent to [aBbCcDd], for example.  To obtain
| the traditional interpretation of bracket expressions, you can use the C
| locale by setting the LC_ALL environment variable to the value C.
`

So as Achim pointed out, unless texi2dvi explicitly specifies the locale
for egrep, that regexp is busted. Even [A-Za-z] is busted in the absence
of a locale: it would have to be something like [:alpha:], although I'm
not sure what DOS allows/requires as a drive prefix. And even in the C
locale, [A-z] allows non-letters which, I'm pretty sure, cannot be used
as drive prefixes.

Nick


___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] Re: Tracking time with MobileOrg

2010-10-07 Thread Jeff Kowalczyk
Richard Moreland rlm at ncogni.to writes:
 - If you click on the clocking icon at the bottom, a list of recently
 clocked tasks will be shown, with the active one being highlighted.
 You can stop the running clock, or start the clock on any of your recent
 items.

The UI ideas sound great.

I would think that a one-touch action for clock in/out of the active task would
be helpful. I'm not completely familiar with the iOS UI conventions, but would a
'long-touch' of the button you mention be a good mechanism to clock in/out of
the active task? A tap would bring up the list of tasks, as you describe.

Also, I think allowing editing of the clock-in/out times (using the iOS
date-time widgets, presumably) would be necessary, if only for accuracy. Many
tasks might start or stop when the device can't be used at that particular
moment. If you can't adjust the clock in/out until you get back to Org Mode,
you'll have to leave yourself a note to do so later.

Thanks, these are exciting developments, I'm glad I asked.

Jeff


___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] [BUG] define just, preamble and postamble placement

2010-10-07 Thread Łukasz Stelmach
Hello.

The docstrings for org-export-html-(pre|post)amble say

(Pre|Post)amble, to be inserted just (after|befor) /?body.

This means that they should go before and after (respectively) div
id=content and its /div. Am I right?

-- 
Miłego dnia,
Łukasz Stelmach


___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] [BUG] define just, preamble and postamble placement

2010-10-07 Thread Nick Dokos
Łukasz Stelmach lukasz.stelm...@iem.pw.edu.pl wrote:


 The docstrings for org-export-html-(pre|post)amble say
 
 (Pre|Post)amble, to be inserted just (after|befor) /?body.
 
 This means that they should go before and after (respectively) div
 id=content and its /div. Am I right?
 

Warning: I'm not an expert. I think the reason that they are inside the
div id=content /div is so that they can get whatever style
the CSS gives this div. If they were outside, then you would have to
modify the CSS to get at them (maybe by defining a body style).

Does it matter? Is the placement inside the div causing you
difficulties? The preamble still comes before any real content
and similarly for the postamble.

Nick

___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] How to use capture to start relative timer? And some other capture issues...

2010-10-07 Thread Alan E. Davis
Org Capture is better than remember in almost all respects.  I have made
some notes on confusing differences, and other issues, for later.  Today,
I'll be more specific about something I'd like to do: it seems to me that
the capture interface would be useful for starting a relative timer,
immediately putting one into the buffer to start entering notes from the
get-go.

I thought about using the notion of a function to open the file and start
the timer; however, I haven't gotten my head around the idea of using a
function as a target for capture.  Are there any example functions around
for study?

Another issue, maybe a difference from org-remember, catches me off guard
almost every time I use capture: the subtle, or maybe not-so-subtle
difference that since one is already in the file---and with the relevant
parameter, the file is not even narrowed---is it even possible to capture to
a file, and leave that file open normally, and not as a capture buffer?
Probably I am missing something here...

I like alot the arrangement of the initial capture screen, with multiple key
entrypoints to culusters of functions: I use it for several template
groups.  Is it possible to sort the templates in the *Org Select* capture
menu buffer, by key strokes in alphabetical order?  I know if I did not use
the customize interface to do this, it was easy to sort them in the .emacs
file.   WIth the ease of entry from Capture directly, though, the customize
approach is really convenient.  I do notice I cannot enter line breaks into
the Template section of a customize entry, though.

Thank you for this tool.  I use it all the time.

Alan Davis
___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] Re: [babel] Writing R-packages the org way?

2010-10-07 Thread Charles C. Berry

On Thu, 7 Oct 2010, Dan Davison wrote:


Rainer M Krug r.m.k...@gmail.com writes:


On Thu, Oct 7, 2010 at 5:12 PM, Erik Iverson er...@ccbr.umn.edu wrote:

Dan Davison wrote:

Erik Iverson er...@ccbr.umn.edu writes:
 Rainer M Krug wrote:



Hi

I am about to write an R package, and as I am an org-mode and
org-babel user, I would (obviously) like to use org-mode for that.

Is there a recommended way of writing an R package in org-babel, or
do I have effectively wrap the R code for the documentation
etc. into source blocks in babel?


That's what I do.  I've looked into converting an org-file to
Roxygen or Rd markup, but never got very far.  My idea at the time
was to do something like:

* function1
** Help
*** Title
   this is function 1 title
*** Description
   function1 does this...
*** Usage
   function1(arg1, arg2, ...)
*** Arguments
   arg1: the first argument
*** Examples
   function1(arg1 = x, arg2 = y)
**Definition
   begin_src R :tangle R/package.R
   function1 - function(arg1, arg2) {

   }



I like the idea of a kind of template, which takes the function name as a
parameter and expands it to the above described structure, but also
including one section for tests.
That would definitely be a starting point from which one could look into the
problem of the .Rd files. As I am not an emacs / elisp expert, how could
that be done (the template)?


Something like this?

--8---cut here---start-8---
#+function: R-pkg-template(function_name)
#+begin_src sh :results output org
cat  EOF
* $function_name
** Help
*** Title
   this is $function_name title
*** Description
   $function_name does this...
*** Usage
   $function_name(arg1, arg2, ...)
*** Arguments
   arg1: the first argument
*** Examples
   $function_name(arg1 = x, arg2 = y)
** Definition
   begin_src R :tangle R/package.R
   $function_name - function(arg1, arg2) {

   },



EOF
#+end_src
--8---cut here---end---8---



I'm late to this party, but thought I might add a few bits. I think
keeping package maintenance and development in emacs makes perfect
sense, but I am less certain about using a single org file.

ESS already has Rd-mode, which has helpful functions like

Rd-mode-insert-skeleton
and
Rd-preview-help

Rather than store the Rd markup or something that gets translated to
it (BTW, see http://developer.r-project.org/parseRd.pdf) in a src
block, I'd make a skeleton package directory and just store links to
the man/*.Rd files within my *.org file and visit them from there.

In the *.org file I'd put src blocks to run R CMD check and R CMD
INSTALL like this:

#+begin_src sh :results outout
   R_ARCH=/x86_64
   export R_ARCH
   R CMD check  makeSitesDF/  | sed 's/^/ /'
 #+end_src

for example which helps me keep track of my progress and keeps me from
accumulating junk in a terminal window. R src blocks can be used to
run test code or to develop and try out a function before moving it to
R/*.R. I've done just enough of this kind of stuff to feel that
starting with an org file and a package directory skeleton that is
slowly populated works for me as a way to get off the ground with new
packages.

However, my $0.02 is that a lot of functionality would need to be
added to make a single org file serve as an all purpose package
development and maintenance environment.

If you do decide to go all in for a 'one org file makes one package'
approach, you might try to get Rd language support added, so you can
edit Rd directly in an Org Src buffer in Rd-mode. And get
org-babel-Rd-evaluate to run Rd-preview-help or call Rd2HTML or
whatnot.

HTH,

Chuck


Then, to insert a template, you can use

#+call: R-pkg-template(function_name=do.something) :results output org raw

which should give something like this:

--8---cut here---start-8---
#+results: R-pkg-template(function_name=do.something)
* do.something
** Help
*** Title
   this is do.something title
*** Description
   do.something does this...
*** Usage
   do.something(arg1, arg2, ...)
*** Arguments
   arg1: the first argument
*** Examples
   do.something(arg1 = x, arg2 = y)
** Definition
   begin_src R :tangle R/package.R
   do.something - function(arg1, arg2) {

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

While playing about you may want to get rid of the raw directive so
that the results will automatically be replaced on repeated evaluations.

Dan








 Any suggestions how to best proceed?


Dream: I would like to have one org file which contains everything
(documentation, code, other relevant files) and if I export or
tangle the file, I have the package ready.


Well, that functionality is essentially present with code blocks
and tangling, except the documentation part.




Exactly - and that is the part I would like to have.





Hi Erik,

Would you mind expanding on that -- what are we missing for the
documentation part?



Dan, by except for the 

[Orgmode] Re: [BUG] define just, preamble and postamble placement

2010-10-07 Thread Łukasz Stelmach
Nick Dokos nicholas.do...@hp.com writes:

 Łukasz Stelmach lukasz.stelm...@iem.pw.edu.pl wrote:


 The docstrings for org-export-html-(pre|post)amble say
 
 (Pre|Post)amble, to be inserted just (after|befor) /?body.
 
 This means that they should go before and after (respectively) div
 id=content and its /div. Am I right?
 

 Warning: I'm not an expert. I think the reason that they are inside the
 div id=content /div is so that they can get whatever style
 the CSS gives this div. If they were outside, then you would have to
 modify the CSS to get at them (maybe by defining a body style).

This is feasible and quite common.

 Does it matter? Is the placement inside the div causing you
 difficulties? The preamble still comes before any real content
 and similarly for the postamble.

|---+-|
| Preamble|
|---+-|
|   | |
| Content   | TOC |
|   | |
|---+-|
| Postamble   |
|---+-|

I'd like to have a layout like the above one, with (pre|post)ambles of
full width (or at least as wide a the content + TOC). With the present
layout preamble and postamble are siblings to TOC and the text and I
can't get the desired layout.

-- 
Miłego dnia,
Łukasz Stelmach


___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode