Re: [O] Bug: ob-ref.el table indexing broken [7.8.11 (release_7.8.11-515-g5f1fc2.dirty]

2012-08-16 Thread Bastien
Hi Ivars,

Ivars Finvers ifinv...@shaw.ca writes:

 After updating my org-mode setup to 7.8.11 I noticed that row and column
 indexing no longer worked when accessing table data in a code block call. 

Fixed in git, thanks a lot for reporting this,

-- 
 Bastien



Re: [O] [ANN] Editable HTML export of Org-mode files

2012-08-16 Thread Eric Schulte
Ista Zahn istaz...@gmail.com writes:

 Hi Eric,

 Sounds really cool, I'd love to try it out. But when I run (ert
 org-ehtml) I get errors like

 Selector: org-ehtml
 Passed: 0
 Failed: 5 (5 unexpected)
 Total:  5/6

 Started at:   2012-08-15 22:00:20-0400
 Finished.
 Finished at:  2012-08-15 22:00:50-0400

 FFQFFF

 F org-ehtml-elnode-serve-all-editable
 (void-function cl-flet)

 F org-ehtml-elnode-serve-complex
 (void-function cl-flet)

 Q org-ehtml-elnode-serve-simple
 (quit)

 F org-ehtml-export-file
 (void-variable org-export-with-LaTeX-fragments)

 F org-ehtml-post-request
 (error Shell command in progress)

 F org-ehtml-simple-export
 (void-variable org-export-with-LaTeX-fragments)

 This is with the git version of org and emacs 24.1.1

 Any ideas what I might have missed?

 Thanks,
 Ista


Ah, thanks for sharing this output, it looks like I wasn't careful
enough about ensuring that cl-lib was loaded.  I've added a number of
require statements which should fix the error you pointed out above.

Please grab the latest from git, and let me know if these problems
persist or any new issues assert themselves.

Thanks,

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



Re: [O] [ANN] Editable HTML export of Org-mode files

2012-08-16 Thread Eric Schulte
Eric Abrahamsen e...@ericabrahamsen.net writes:

 On Thu, Aug 16 2012, Eric Schulte wrote:

 Every time I edited a block and clicked save, it just deleted the
 whole block. I got these errors in ~/.elnodelogs/elnode-error:


 I'm not sure what could be causing this problem.  Did the test suite run
 successfully for you?

 I've now added a POST test to the test suite.  So if your problem
 persists you should now see a failing test, and conversely if you are
 now passing the test suite this problem should be eliminated.

 So yes, I did run the tests the first time, and you're right that,
 without the post test, they went just fine. The documents were also
 altered on-disk (ie, the chunks really were deleted).

Interesting.

 I updated org-ehtml to get the new tests, and the post test failed
 thusly:

 --8---cut here---start-8---
 F org-ehtml-post-request
 (ert-test-failed
  ((should
(string-match ifoo/i html))
   :form
   (string-match ifoo/i
   #(\npemfoo/em\n/p 0 17
 (fontified t front-sticky
(field inhibit-line-move-field-capture)
rear-nonsticky t field output 
 inhibit-line-move-field-capture t)
 17 21
 (fontified t front-sticky
(field inhibit-line-move-field-capture)
rear-nonsticky t field output 
 inhibit-line-move-field-capture t)))
   :value nil))
 --8---cut here---end---8---

 This is still with my regular emacs environment.


Even thought this test is failing, it does show that your elnode server
is returning the HTML in response to your POST requests.  It looks like
it only fails because your Emacs exports *foo* as emfoo/em instead
of as ifoo/i.


 Then I restarted emacs -Q and used your batch.el file. I'm still getting
 the same problem, unfortunately: the editable blocks disappear when I
 hit save. I realized I don't actually know whether this is supposed to
 edit the simple.org or simple.html files:

Edits are applied to the simple.org file itself.  The simple.html file
will not be updated until you refresh the page through your web browser.

 anyway, the text disappears from the org file, but not from the html
 file. Here's the output of *Messages*:

[...]

Nothing here looks odd.


 And the elnode error file:

[...]

The elnode error output don't generally contain anything interesting.
Instead of listing errors it just lists routine access.

I've just pushed up some changes to the git repository which add new
require statements.  Hopefully the errors above were caused by some
required functions not being loaded at run time.  If the newest from git
doesn't work fix these problems, please try running

  emacs -Q -l batch.el

with this updated version of batch.el, and let me know what is printed
in the *Messages* buffer in the line which starts as params:.



batch.el
Description: application/emacs-lisp

Thanks,

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


Re: [O] Launch org-mode and it asks for a ftp password

2012-08-16 Thread Bastien
Hi Humberto,

Humberto Henrique humbhe...@gmail.com writes:

 I don't know what's going on, but when I launch org-mode in one of my
 machines in home it thinks I am at work. 
 If I launch org-mode by M-x org-mode, it prompts with a ftp password
 for my machine at work.
 My .emacs config is synced via dropbox on these machines.
 Where is the option to disable this behavior.

Shooting in the dark: check your `org-agenda-files' in the .emacs.el, 
to see if the path is correct for both machines.

-- 
 Bastien



Re: [O] how do you I export holidays into an iCal file

2012-08-16 Thread Bastien
Hi Enda,

Enda enda...@yahoo.com writes:

 How do you I export this into an iCal file (C-c C-e i) (only events
 get exported):

 * New Year's Day
 %%(diary-anniversary 1 1)

You can't.  Patch welcome,

-- 
 Bastien



Re: [O] [ANN] Editable HTML export of Org-mode files

2012-08-16 Thread Eric Abrahamsen
On Thu, Aug 16 2012, Eric Schulte wrote:

 Eric Abrahamsen e...@ericabrahamsen.net writes:

 On Thu, Aug 16 2012, Eric Schulte wrote:

 Every time I edited a block and clicked save, it just deleted the
 whole block. I got these errors in ~/.elnodelogs/elnode-error:


 I'm not sure what could be causing this problem.  Did the test suite run
 successfully for you?

 I've now added a POST test to the test suite.  So if your problem
 persists you should now see a failing test, and conversely if you are
 now passing the test suite this problem should be eliminated.

 So yes, I did run the tests the first time, and you're right that,
 without the post test, they went just fine. The documents were also
 altered on-disk (ie, the chunks really were deleted).

 Interesting.

[...]

 Even thought this test is failing, it does show that your elnode server
 is returning the HTML in response to your POST requests.  It looks like
 it only fails because your Emacs exports *foo* as emfoo/em instead
 of as ifoo/i.


 Then I restarted emacs -Q and used your batch.el file. I'm still getting
 the same problem, unfortunately: the editable blocks disappear when I
 hit save. I realized I don't actually know whether this is supposed to
 edit the simple.org or simple.html files:


[...]

 I've just pushed up some changes to the git repository which add new
 require statements.  Hopefully the errors above were caused by some
 required functions not being loaded at run time.  If the newest from git
 doesn't work fix these problems, please try running

   emacs -Q -l batch.el

 with this updated version of batch.el, and let me know what is printed
 in the *Messages* buffer in the line which starts as params:.

The same test failed in the same way, so I loaded up the new batch.el
file, and here's the params line:

params:((path . /simple.org) (end . 577) (beg . 156) (org
. ))

Hope that's enlightening!

E

-- 
GNU Emacs 24.1.50.1 (i686-pc-linux-gnu, GTK+ Version 2.24.11)
 of 2012-08-14 on pellet
7.8.11




Re: [O] org-read-date-prefer-future should prefer next week if the given time is before now

2012-08-16 Thread Bastien
Bastien b...@gnu.org writes:

 Tom adatgyu...@gmail.com writes:

 It is a consistency bug then. If thu 8am works in other cases
 then it should not be the user's job to know which format to
 use to achieve to desired result. Org should treat both
 forms in the same way.

 Please try the attached patch and report other inconsistencies.

I've now applied this patch.

-- 
 Bastien



Re: [O] [PATCH v2 00/11] Takjuggler exporter improvements

2012-08-16 Thread Bastien
Hi Yann,

Yann Hodique yann.hodi...@gmail.com writes:

 here is a new version of the patch series.

Thanks.

 Changes are:

 - fixed commit messages format

Thanks for this effort -- not nitpicking, but there is room left for
small improvements.

- The summary line should be org-taskjuggler.el: Sentence (note the
  .el after org-taskjuggler).

- The ChangeLog entries should be sentences, starting with an uppercase
  letter and ending with a full stop.

- It should be filled with C-x f 72 (or 70) then M-q.

- Interactive functions = commands
  custom variables = options
  
  This makes the entries shorter and tells immediatly what it is about.

All this because those entries are later on automatically parsed to get
added to Emacs.  I review them manually, but fixing lots of entries
manually take a lot of time.

I'm having a branch with your changes -- I'll apply it when you confirm
you received the FSF papers.

Thanks!

-- 
 Bastien



[O] Offline until sunday eve -- please heavily test current HEAD

2012-08-16 Thread Bastien
Hi all,

I will be offline until sunday eve.

Please heavily test the current HEAD of the git repository.
If you have bugs that you didn't send to the list, please do
it now.

Thanks,

-- 
 Bastien




Re: [O] new tag query parser (re)introduction

2012-08-16 Thread Bastien
Hi Christopher,

Christopher Genovese genov...@cmu.edu writes:

 At Bastien's urging, I'm (re)posting about my new tag query parser
 implementation in what I hope are clearer, more digestible, and more
 actionable pieces. 

Thanks a *lot* for the effort you did in shewing this again!

All this looks very promising.  Releasing Org 7.9 is still the
highest priority, but I'll take time to review this carefully.

Maybe in the meantime others will chime in too.

Thanks again,

-- 
 Bastien



Re: [O] [GSoC] Org Merge Driver Update

2012-08-16 Thread Andrew Young
Hi,
On Wed, Aug 15, 2012 at 1:04 PM, Eric Schulte eric.schu...@gmx.com wrote:
 I'm very excited to start using this merge driver.  I've put together an
 Arch Linux User Repository (aur) package, which can be used by Arch
 Linux users to install the org-merge-driver with pacman.  It is
 available at [1],

Thank you so much for doing this! I'm also an Arch Linux user, and am
now using your package as well!

 if others find it useful and if Andrew doesn't object
 I'd be happy to push it into the official aur database.  It is very
 simple and installs directly from git.


Yes, of course I don't mind.  This would be _awesome_.

I just installed OMD through your package. Pretty exciting for
me! It took me a little bit to realize the linked file was not
corrupted ;), but HTML to the new package.

Regarding the gnulib dependency:

I have included the Gnulib sources which my project depends on
directly into the git repository. Because of this, gnulib shouldn't be
nessecary to build. I've done this for two main reasons:

1. I thought that would make the dependencies easier on everyone else
   to build and install.

2. I believe I've uncovered a bug in one of the sources I'm using, and
   so for the time being I'm using a slightly edited version.

I'm really not sure what the standard is for using GnuLib in a
project. I think that distributing Gnulib dependencies directly with a
project may be typical, given that it is used at the source level. (If
anyone has any opinion on this, please share)

For the time being, it may be best to leave Gnulib out as dependency,
until I find out what to do. Re-importing Gnulib modules may
reintroduce the problem I was having.

 I spent some time testing this locally and I've run into what appears to
 be an error.  Namely when merging a tree with multiple new sub-headings
 the merge completes successfully, but the subheadings from the OTHER
 branch are deleted by the merge.  Here [2] is a tarball of the entire
 git directory after the failed merge.  Please let me know if there is
 any other debug information I can provide.


Thank you for letting me know, and your detailed example.  This should
be fixed now, along with some other issues.

 Thanks,

 Footnotes:
 [1]  http://cs.unm.edu/~eschulte/data/org-merge-driver-20120815-1.src.tar.gz

 [2]  http://cs.unm.edu/~eschulte/data/fruit-test.tar.bz2

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

Thanks again for doing all this, it's really appreciated!

Sincerely,
Andrew Young



Re: [O] Activate/deactivate export of inlinetasks with #+OPTIONS

2012-08-16 Thread Nicolas Goaziou
Hello,

Bastien b...@gnu.org writes:

 (defcustom org-export-with-inlinetasks t
   Non-nil means include INLINETASKS keywords in export.
 When nil, remove all these keywords from the export.
   :group 'org-export-general
   :type 'boolean)

 +1 for having this for the new exporter.

 Thanks for the idea and the code!

I agree, this is a good idea. I've added it in org-export.el.


Regards,

-- 
Nicolas Goaziou



Re: [O] Activate/deactivate export of inlinetasks with #+OPTIONS

2012-08-16 Thread Bastien
Nicolas Goaziou n.goaz...@gmail.com writes:

 Bastien b...@gnu.org writes:

 (defcustom org-export-with-inlinetasks t
   Non-nil means include INLINETASKS keywords in export.
 When nil, remove all these keywords from the export.
   :group 'org-export-general
   :type 'boolean)

 +1 for having this for the new exporter.

 Thanks for the idea and the code!

 I agree, this is a good idea. I've added it in org-export.el.

Thanks!

-- 
 Bastien



[O] Bug: org-clock-display does not work with a heading ending in a link [7.8.11 (release_7.8.11-504-gd2200b @ /home/ryan/lib/site-lisp/org/)]

2012-08-16 Thread Ryan Kaskel
Consider the following subtrees:

* [[http://example.com/][My Link]]
  CLOCK: [2012-08-16 Thu 09:41]--[2012-08-16 Thu 09:56] =  0:15

* Not a link
  CLOCK: [2012-08-16 Thu 09:41]--[2012-08-16 Thu 09:56] =  0:15

Running org-clock-display displays summary statistics only for the
subtree that doesn't end in a link

(tested under emacs24 -Q -l ~/org/minimal-org.el)

Emacs  : GNU Emacs 24.1.1 (x86_64-pc-linux-gnu, GTK+ Version 2.24.10)
 of 2012-07-17 on lawrencium, modified by Debian
Package: Org-mode version 7.8.11 (release_7.8.11-504-gd2200b @
/home/ryan/lib/site-lisp/org/)



Re: [O] Launch org-mode and it asks for a ftp password

2012-08-16 Thread Humberto Henrique
Yes, the problem was the org-agenda-files. I don't understand though
because it is setted to files in the dropbox folder, so it should work in
all machines. The path to dropbox is setted in each machine.

2012/8/16 Bastien b...@altern.org

 Hi Humberto,

 Humberto Henrique humbhe...@gmail.com writes:

  I don't know what's going on, but when I launch org-mode in one of my
  machines in home it thinks I am at work.
  If I launch org-mode by M-x org-mode, it prompts with a ftp password
  for my machine at work.
  My .emacs config is synced via dropbox on these machines.
  Where is the option to disable this behavior.

 Shooting in the dark: check your `org-agenda-files' in the .emacs.el,
 to see if the path is correct for both machines.

 --
  Bastien




-- 


:.Humberto Pinheiro.:


[O] Hiding specific TODO-keywords in Shift-Tab-expansion in org-mode buffer

2012-08-16 Thread Arthur Andersen
Hello,

I have a TODO keyword called `SOMEDAY`.
When I use Shift-Tab, is there an easy way to add one level, to have a
rotation like OVERVIEW, CONTENTS without SOMEDAY tasks, CONTENS, VIEW ALL?

Greetings, Arthur


Re: [O] Feature that org mode needs most

2012-08-16 Thread Steinar Bang
 Bastien b...@gnu.org:

 is this known, and has been fixed later than the above commit?  If so, I
 can pull, and try again.

 It should be fixed now, please confirm.

I can confirm it works.  Ie. that it adjusts the end time of the
previously clocked item correctly.

My current latest commit after the pull, is
 952d722dcddb275d84ad6dd356bee2fd5c8027c8

(The previously clocked item and it's :CLOCK: drawer was opened.  I don't
know if that was intentional, or not...?)

Thanks!




Re: [O] [ANN] Editable HTML export of Org-mode files

2012-08-16 Thread Eric Schulte
Eric Abrahamsen e...@ericabrahamsen.net writes:

 On Thu, Aug 16 2012, Eric Schulte wrote:

 Eric Abrahamsen e...@ericabrahamsen.net writes:

 On Thu, Aug 16 2012, Eric Schulte wrote:

 Every time I edited a block and clicked save, it just deleted the
 whole block. I got these errors in ~/.elnodelogs/elnode-error:


 I'm not sure what could be causing this problem.  Did the test suite run
 successfully for you?

 I've now added a POST test to the test suite.  So if your problem
 persists you should now see a failing test, and conversely if you are
 now passing the test suite this problem should be eliminated.

 So yes, I did run the tests the first time, and you're right that,
 without the post test, they went just fine. The documents were also
 altered on-disk (ie, the chunks really were deleted).

 Interesting.

 [...]

 Even thought this test is failing, it does show that your elnode server
 is returning the HTML in response to your POST requests.  It looks like
 it only fails because your Emacs exports *foo* as emfoo/em instead
 of as ifoo/i.


 Then I restarted emacs -Q and used your batch.el file. I'm still getting
 the same problem, unfortunately: the editable blocks disappear when I
 hit save. I realized I don't actually know whether this is supposed to
 edit the simple.org or simple.html files:


 [...]

 I've just pushed up some changes to the git repository which add new
 require statements.  Hopefully the errors above were caused by some
 required functions not being loaded at run time.  If the newest from git
 doesn't work fix these problems, please try running

   emacs -Q -l batch.el

 with this updated version of batch.el, and let me know what is printed
 in the *Messages* buffer in the line which starts as params:.

 The same test failed in the same way,

Fair enough, this must be a legitimate difference in our HTML export,
I'll make the test appropriately more permissive.

 so I loaded up the new batch.el file, and here's the params line:

 params:((path . /simple.org) (end . 577) (beg . 156) (org
 . ))

 Hope that's enlightening!


Yes, very enlightening.  It means that the server-side and Emacs Lisp
side are working as expected.  However, for some reason, when you hit
[SAVE] the information submitted by your browser includes an empty text
field (this is the org pair above).

This must be a JavaScript issue related to some difference between
browsers.  Can I ask, what browser you are using?  I've done all of my
testing with browsers in the Firefox family (Firefox and conkeror).

Thanks!


 E

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




[O] Question about org-habit and agenda views

2012-08-16 Thread Thomas Moyer
I have a set of habits that I do Monday through Friday (weekdays only) and
the best suggestion I have found for this is to have 5 individual TODOs
(one for each day). This seems to work well for the most part, but I have
found one minor annoyance that I can't find a solution for.

If I don't do one of the habits on Monday, that entry will appear as
overdue until the next week on Monday when it comes around again. Is there
a way to hide overdue habits? I don't want to mark it as DONE, since it
wasn't even when it was late.

As an example of what I current have, here is an excerpt for one habit:

** Notes
*** TODO (M) Refile notes
SCHEDULED: 2012-08-20 Mon ++1w
:PROPERTIES:
:STYLE: habit
:END:
*** TODO (T) Refile notes
SCHEDULED: 2012-08-21 Tue ++1w
:PROPERTIES:
:STYLE: habit
:END:
*** TODO (W) Refile notes
SCHEDULED: 2012-08-15 Wed ++1w
:PROPERTIES:
:STYLE: habit
:END:
*** TODO (R) Refile notes
SCHEDULED: 2012-08-16 Thu ++1w
:PROPERTIES:
:STYLE: habit
:END:
*** TODO (F) Refile notes
SCHEDULED: 2012-08-17 Fri ++1w
:PROPERTIES:
:STYLE: habit
:END:

So if I miss Monday, when I open my agenda on Tuesday, I currently see two
entries for Refile notes. Ideally, I would like to only see the one for
Tuesday, and then when the following Monday rolls around, I should see the
Monday entry again, with the consistency graph showing that I missed last
Monday.

Thanks for the help!

-Tom

--
Thomas Moyer
tommo...@gmail.com


Re: [O] [ANN] Editable HTML export of Org-mode files

2012-08-16 Thread Eric Abrahamsen
On Thu, Aug 16 2012, Eric Schulte wrote:

 Eric Abrahamsen e...@ericabrahamsen.net writes:

 On Thu, Aug 16 2012, Eric Schulte wrote:

 Eric Abrahamsen e...@ericabrahamsen.net writes:

 On Thu, Aug 16 2012, Eric Schulte wrote:

 Every time I edited a block and clicked save, it just deleted the
 whole block. I got these errors in ~/.elnodelogs/elnode-error:


 I'm not sure what could be causing this problem.  Did the test suite run
 successfully for you?

 I've now added a POST test to the test suite.  So if your problem
 persists you should now see a failing test, and conversely if you are
 now passing the test suite this problem should be eliminated.

 So yes, I did run the tests the first time, and you're right that,
 without the post test, they went just fine. The documents were also
 altered on-disk (ie, the chunks really were deleted).

 Interesting.

 [...]

 Even thought this test is failing, it does show that your elnode server
 is returning the HTML in response to your POST requests.  It looks like
 it only fails because your Emacs exports *foo* as emfoo/em instead
 of as ifoo/i.


 Then I restarted emacs -Q and used your batch.el file. I'm still getting
 the same problem, unfortunately: the editable blocks disappear when I
 hit save. I realized I don't actually know whether this is supposed to
 edit the simple.org or simple.html files:


 [...]

 I've just pushed up some changes to the git repository which add new
 require statements.  Hopefully the errors above were caused by some
 required functions not being loaded at run time.  If the newest from git
 doesn't work fix these problems, please try running

   emacs -Q -l batch.el

 with this updated version of batch.el, and let me know what is printed
 in the *Messages* buffer in the line which starts as params:.

 The same test failed in the same way,

 Fair enough, this must be a legitimate difference in our HTML export,
 I'll make the test appropriately more permissive.

 so I loaded up the new batch.el file, and here's the params line:

 params:((path . /simple.org) (end . 577) (beg . 156) (org
 . ))

 Hope that's enlightening!


 Yes, very enlightening.  It means that the server-side and Emacs Lisp
 side are working as expected.  However, for some reason, when you hit
 [SAVE] the information submitted by your browser includes an empty text
 field (this is the org pair above).

 This must be a JavaScript issue related to some difference between
 browsers.  Can I ask, what browser you are using?  I've done all of my
 testing with browsers in the Firefox family (Firefox and conkeror).

I'm using the version of Chrome provided by Arch linux, it tells me
Version 21.0.1180.79 (151411). I just tried the test server in Firefox,
and it worked perfectly.

Much as I like Chrome, I've occasionally seen it make websites fail in
ways you wouldn't think a browser should be capable of.


-- 
GNU Emacs 24.1.50.1 (i686-pc-linux-gnu, GTK+ Version 2.24.11) of
 2012-08-14 on pellet 7.8.11




Re: [O] [GSoC] Org Merge Driver Update

2012-08-16 Thread Eric Schulte
Andrew Young younga...@gmail.com writes:

 Hi,
 On Wed, Aug 15, 2012 at 1:04 PM, Eric Schulte eric.schu...@gmx.com wrote:
 I'm very excited to start using this merge driver.  I've put together an
 Arch Linux User Repository (aur) package, which can be used by Arch
 Linux users to install the org-merge-driver with pacman.  It is
 available at [1],

 Thank you so much for doing this! I'm also an Arch Linux user, and am
 now using your package as well!

 if others find it useful and if Andrew doesn't object
 I'd be happy to push it into the official aur database.  It is very
 simple and installs directly from git.


 Yes, of course I don't mind.  This would be _awesome_.

 I just installed OMD through your package. Pretty exciting for
 me! It took me a little bit to realize the linked file was not
 corrupted ;), but HTML to the new package.

 Regarding the gnulib dependency:

 I have included the Gnulib sources which my project depends on
 directly into the git repository. Because of this, gnulib shouldn't be
 nessecary to build. I've done this for two main reasons:

 1. I thought that would make the dependencies easier on everyone else
to build and install.

 2. I believe I've uncovered a bug in one of the sources I'm using, and
so for the time being I'm using a slightly edited version.

 I'm really not sure what the standard is for using GnuLib in a
 project. I think that distributing Gnulib dependencies directly with a
 project may be typical, given that it is used at the source level. (If
 anyone has any opinion on this, please share)


I don't know about this personally, but from the gnulib site [1], this
sounds like the intended method of use.


 For the time being, it may be best to leave Gnulib out as dependency,
 until I find out what to do. Re-importing Gnulib modules may
 reintroduce the problem I was having.


I'll remove 'gnulib' from the dependencies and remove the libtool
portion of the build sequence.


 I spent some time testing this locally and I've run into what appears to
 be an error.  Namely when merging a tree with multiple new sub-headings
 the merge completes successfully, but the subheadings from the OTHER
 branch are deleted by the merge.  Here [2] is a tarball of the entire
 git directory after the failed merge.  Please let me know if there is
 any other debug information I can provide.


 Thank you for letting me know, and your detailed example.  This should
 be fixed now, along with some other issues.


Yes, I can confirm that this now works for me.


 Thanks,

 Footnotes:
 [1]  http://cs.unm.edu/~eschulte/data/org-merge-driver-20120815-1.src.tar.gz

 [2]  http://cs.unm.edu/~eschulte/data/fruit-test.tar.bz2

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

 Thanks again for doing all this, it's really appreciated!


My pleasure, I've now submitted this package to the AUR database [2].

Cheers,


 Sincerely,
 Andrew Young



Footnotes: 
[1]  http://www.gnu.org/software/gnulib/ (end of third paragraph)

[2]  https://aur.archlinux.org/packages.php?ID=62052

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



Re: [O] Question about org-habit and agenda views

2012-08-16 Thread Jonathan Leech-Pepin
Hello Thomas,

On Thu, Aug 16, 2012 at 10:28 AM, Thomas Moyer tommo...@gmail.com wrote:
 I have a set of habits that I do Monday through Friday (weekdays only) and
 the best suggestion I have found for this is to have 5 individual TODOs (one
 for each day). This seems to work well for the most part, but I have found
 one minor annoyance that I can't find a solution for.

 If I don't do one of the habits on Monday, that entry will appear as overdue
 until the next week on Monday when it comes around again. Is there a way to
 hide overdue habits? I don't want to mark it as DONE, since it wasn't even
 when it was late.


Couldn't you create a single habit that uses a .+1d/3d repeater?  It
would still show up on the weekend however it would not be listed as
overdue at that time.

On a slightly related note to the developers:  Is there any way that a
=skip-days= marker be added in Org?  This would allow for simpler
repeating tasks/habigs that are not to be done on weekends.

 As an example of what I current have, here is an excerpt for one habit:

 ** Notes
 *** TODO (M) Refile notes
 SCHEDULED: 2012-08-20 Mon ++1w
 :PROPERTIES:
 :STYLE: habit
 :END:
 *** TODO (T) Refile notes
 SCHEDULED: 2012-08-21 Tue ++1w
 :PROPERTIES:
 :STYLE: habit
 :END:
 *** TODO (W) Refile notes
 SCHEDULED: 2012-08-15 Wed ++1w
 :PROPERTIES:
 :STYLE: habit
 :END:
 *** TODO (R) Refile notes
 SCHEDULED: 2012-08-16 Thu ++1w
 :PROPERTIES:
 :STYLE: habit
 :END:
 *** TODO (F) Refile notes
 SCHEDULED: 2012-08-17 Fri ++1w
 :PROPERTIES:
 :STYLE: habit
 :END:

 So if I miss Monday, when I open my agenda on Tuesday, I currently see two
 entries for Refile notes. Ideally, I would like to only see the one for
 Tuesday, and then when the following Monday rolls around, I should see the
 Monday entry again, with the consistency graph showing that I missed last
 Monday.

 Thanks for the help!

 -Tom

 --
 Thomas Moyer
 tommo...@gmail.com


Regards,

--
Jon



Re: [O] [ANN] Editable HTML export of Org-mode files

2012-08-16 Thread Eric Schulte

 This must be a JavaScript issue related to some difference between
browsers.  Can I ask, what browser you are using?  I've done all of my
testing with browsers in the Firefox family (Firefox and conkeror).

 I'm using the version of Chrome provided by Arch linux, it tells me
 Version 21.0.1180.79 (151411). I just tried the test server in Firefox,
 and it worked perfectly.

 Much as I like Chrome, I've occasionally seen it make websites fail in
 ways you wouldn't think a browser should be capable of.

Good to know thanks.  I'll make a note of this and take a look at it
when next I have some free time.  My Java Script is not strong, so maybe
there is a more inter-operable way to write this file.  If anyone has
Java Script and JQuery experience and wants to take a look the problem
is around line 14 of src/org-ehtml-client.js.

Thanks,

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



Re: [O] [ANN] Editable HTML export of Org-mode files

2012-08-16 Thread Ista Zahn
On Thu, Aug 16, 2012 at 2:31 AM, Eric Schulte eric.schu...@gmx.com wrote:
 Ista Zahn istaz...@gmail.com writes:

 Hi Eric,

 Sounds really cool, I'd love to try it out. But when I run (ert
 org-ehtml) I get errors like

 Selector: org-ehtml
 Passed: 0
 Failed: 5 (5 unexpected)
 Total:  5/6

 Started at:   2012-08-15 22:00:20-0400
 Finished.
 Finished at:  2012-08-15 22:00:50-0400

 FFQFFF

 F org-ehtml-elnode-serve-all-editable
 (void-function cl-flet)

 F org-ehtml-elnode-serve-complex
 (void-function cl-flet)

 Q org-ehtml-elnode-serve-simple
 (quit)

 F org-ehtml-export-file
 (void-variable org-export-with-LaTeX-fragments)

 F org-ehtml-post-request
 (error Shell command in progress)

 F org-ehtml-simple-export
 (void-variable org-export-with-LaTeX-fragments)

 This is with the git version of org and emacs 24.1.1

 Any ideas what I might have missed?

 Thanks,
 Ista


 Ah, thanks for sharing this output, it looks like I wasn't careful
 enough about ensuring that cl-lib was loaded.  I've added a number of
 require statements which should fix the error you pointed out above.

 Please grab the latest from git, and let me know if these problems
 persist or any new issues assert themselves.

With the current git version I now get File error: Cannot open load
file, cl-lib on start up.

find / -name cl-lib.el does not produce any results on my machine, nor
have I been able to find it in elpa/marmalade etc. Google search
suggests it is built in with emacs, but I'm pretty sure I don't have
it...

Best,
Ista


 Thanks,

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



Re: [O] [ANN] Editable HTML export of Org-mode files

2012-08-16 Thread Eric Schulte
Ista Zahn istaz...@gmail.com writes:

 On Thu, Aug 16, 2012 at 2:31 AM, Eric Schulte eric.schu...@gmx.com wrote:
 Ista Zahn istaz...@gmail.com writes:

 Hi Eric,

 Sounds really cool, I'd love to try it out. But when I run (ert
 org-ehtml) I get errors like

 Selector: org-ehtml
 Passed: 0
 Failed: 5 (5 unexpected)
 Total:  5/6

 Started at:   2012-08-15 22:00:20-0400
 Finished.
 Finished at:  2012-08-15 22:00:50-0400

 FFQFFF

 F org-ehtml-elnode-serve-all-editable
 (void-function cl-flet)

 F org-ehtml-elnode-serve-complex
 (void-function cl-flet)

 Q org-ehtml-elnode-serve-simple
 (quit)

 F org-ehtml-export-file
 (void-variable org-export-with-LaTeX-fragments)

 F org-ehtml-post-request
 (error Shell command in progress)

 F org-ehtml-simple-export
 (void-variable org-export-with-LaTeX-fragments)

 This is with the git version of org and emacs 24.1.1

 Any ideas what I might have missed?

 Thanks,
 Ista


 Ah, thanks for sharing this output, it looks like I wasn't careful
 enough about ensuring that cl-lib was loaded.  I've added a number of
 require statements which should fix the error you pointed out above.

 Please grab the latest from git, and let me know if these problems
 persist or any new issues assert themselves.

 With the current git version I now get File error: Cannot open load
 file, cl-lib on start up.

 find / -name cl-lib.el does not produce any results on my machine, nor
 have I been able to find it in elpa/marmalade etc. Google search
 suggests it is built in with emacs, but I'm pretty sure I don't have
 it...


Ugh, this is more headache related to the renaming of all cl-* functions
between the released version of Emacs 24 and the development head of
Emacs (which I'm using).  I've just pushed up a change after which all
tests are passing on both the development head and the released version
of Emacs 24.

Thanks for your help in running this down.

Best,


 Best,
 Ista


 Thanks,

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


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



[O] How to stop Org mode from assuming non-Latin characters after [[link]] as part of the link?

2012-08-16 Thread Betty
If I don't put a space after a URL, Org always assumes that all
characters after the link are part of the link. For example, if I
write
[[http://example.com]]asdf
Org will think the URL is http://example.com]]asdf; while it should
be http://example.com;.

In English there is usually a space after each word (including links)
anyway, so that might not be a big issue. But what about non-Latin
languages?

For instance, in Chinese, we don't use spaces to delimit words, and I
really don't want to deteriorate the Chinese language by adding extra
spaces just to make the links work properly. The result is, If I put a
URL in and don't add an extra space after it, Org will think all the
(Chinese) characters I enter after the URL is part of the link, until
the end of paragraph where I press RET.

Well, I know that ] is a valid URL character, which makes things a
bit tricky. But it is very rare that a URL should contain both ]]
and non-Latin characters immediately following the ]]. It is a safer
bet to assume the URL is just the part before ]]. On the rare
occasions when the URL does contain ]] followed by non-Latin
characters, I'm willing to take the risk of breaking it.

In sum, I want Org to take only stuff inside the [[]] brackets as
the URL, nothing after. Is there a place where I can configure this?

Thank you for reading this and for any help you might provide.

(English is not my native tongue. I hope I have make myself clear.)



Re: [O] [ANN] Editable HTML export of Org-mode files

2012-08-16 Thread Achim Gratz
Eric Schulte writes:
 Ugh, this is more headache related to the renaming of all cl-* functions
 between the released version of Emacs 24 and the development head of
 Emacs (which I'm using).  I've just pushed up a change after which all
 tests are passing on both the development head and the released version
 of Emacs 24.

Note that there's yet a new wrinkle with the upcoming release of the
24.2 version (which hasn't made the change yet), so 24.1.50 and
24.2.50 and later have new-style cl libraries...


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

SD adaptation for Waldorf microQ V2.22R2:
http://Synth.Stromeko.net/Downloads.html#WaldorfSDada




Re: [O] full parser implementation for tag queries (parentheses, fast heading match, and more)

2012-08-16 Thread Christopher Genovese
Hi Samuel,

  Thanks for your note.  Just FYI, the earlier parser code in this thread
has
been superseded by the code in the post new tag query parser [3/5].

   The sexp input is a nice idea, and it would be very easy I think.
The function org-make-tags-matcher now takes a query string
but could easily be modified to operate on a form as well.

I've included some code below that basically does the job. It defines a
function
`mtrans' that transforms a sexp representation into a matcher.  It can
certainly be
better optimized (and fully tested), but I think it would do just what you
want
if inserted in org-make-tags-matcher. (Note: The car of the matcher is the
query string,
for reasons that aren't entirely clear. Because this is dropped anyway in
practice,
I don't bother making it accurate in this code. As such, I'll just give the
cdr in the examples below.)

A few examples follow to give the idea and show the results. It seems
to handle
all the cases nicely. In the sexp representation, strings stand for exact
string matches
and  both [string] and (re string) stand for regex matches, with
symbols
for properties and standard boolean and comparison ops in the form.
The keyword :todo-only acts like /! in the query strings, and = and  also
allow arbitrary lisp code for the property comparison with equal (as long
as the
form does not start with or, and, not, or re but then it can be shielded
with (identity ...)).

I then append the code, which is also attached. I see no problems
with adding this to org-make-tags-matcher and would be interested in other
opinions.

Best,

  Christopher

;;; Examples

(mtrans foo) ; corresponds to query string  foo
  = (member foo tags-list)

(mtrans [^f])   ; or (mtrans '(re ^f))  corresponds to query string
{^f}
  =  (progn
(setq org-cached-props nil)
(org-match-any-p ^f tags-list))

(mtrans '(and foo (not bar) (re ^u.*v)))  ; query string
foo-bar+{^u.*v}
  = (progn
   (setq org-cached-props nil)
   (and
(member foo tags-list)
(not (member bar tags-list))
(org-match-any-p ^u.*v tags-list)))

(mtrans '(or (and xyz (= TODO [^T]) [u\\{2,4\\}] (= LEVEL 3))
 ( APROP foo)
 (and (= BPROP 4) ( HEADING ignore
  ; query string
xyz+TODO={^T}+{u\\{{2,4\\}}}+LEVEL=3 | APROP  \foo\ | BPROP=4HEADING
 \ignore\
  = (progn
   (setq org-cached-props nil)
   (or
(and
 (member xyz tags-list)
 (org-string-match= (or todo ) ^T)
 (org-match-any-p u\\{2,4\\} tags-list)
 (= level 3))
(org-string (or (org-cached-entry-get nil APROP) ) foo)
(and
 (= (org-cached-entry-get nil BPROP) 4)
 (org-string (or heading ) ignore

(mtrans '(or (and foo (not bar) [^u.*v] ( LEVEL 2))
 (= APROP foo)
 (and (= BPROP [/.*/]) ( BPROP /ignore/))
 ( TODO TODO)
 ( SCHEDULED 2008-11-12)))
  ; query string foo-bar+{^u.*v}+LEVEL2 | APROP=\foo\|
BPROP={/.*/}  BPROP  /ignore/ | TODO\TODO\ | SCHEDULED 
\2008-11-12\
  = (progn
   (setq org-cached-props nil)
   (or
(and
 (member foo tags-list)
 (not (member bar tags-list))
 (org-match-any-p ^u.*v tags-list)
 ( level 2))
(string= (or (org-cached-entry-get nil APROP) ) foo)
(and
 (org-string-match= (or (org-cached-entry-get nil BPROP) )
/.*/)
 (org-string (or (org-cached-entry-get nil BPROP) )
/ignore/))
(org-string (or todo ) TODO)
(org-time (or (org-cached-entry-get nil SCHEDULED) )
1226466000.0)))

(mtrans '(and :todo-only
  (or (and (not [^abc]) [ex] (= A_PROP foo))
  (= B_PROP 1.2e10)
  (and ( D_PROP 2008-12-24 18:30) (= FOO (call other
lisp code here))
   ; except for FOO part which has no analogue, query string
-{^abc}+{ex}A_PROP=\foo\ | B_PROP  1.2e10 | DROP  \2008-12-24
18:30\  FOO = ...
  = (progn
   (setq org-cached-props nil)
   (and
(member todo org-not-done-keywords)
(or
 (and
  (not (org-match-any-p ^abc tags-list))
  (org-match-any-p ex tags-list)
  (string= (or (org-cached-entry-get nil A_PROP) ) foo))
 (= (org-cached-entry-get nil B_PROP) 120.0)
 (and
  (org-time (or (org-cached-entry-get nil D_PROP) )
1230094800.0)
  (equal (org-cached-entry-get nil FOO) (call other lisp code
here))


;;; The Code

(eval-when-compile (require 'cl))

(defun mtrans (matcher-sexp)
  Create a tag/todo matcher from a sexp representation.
In the sexp representation, components are transformed as follows:

  + A literal string becomes an exact tag match.
  + A [string] or (re string) becomes a tag regex match
  + (or item...), (and item...), (not item)
act as boolean operators, and processing continues on the item's
  + (op lhs rhs) is a property comparison, 

Re: [O] [PATCH v2 00/11] Takjuggler exporter improvements

2012-08-16 Thread Yann Hodique
 Bastien == Bastien  b...@altern.org writes:

 Thanks for this effort -- not nitpicking, but there is room left for
 small improvements.

Sure, no problem. I will do that right away. Actually the last series
was a bit messy anyway, with my old 4/10 showing up again (which brought
confusion to patchwork).

Thanks,

Yann.

-- 
There is no escape--we pay for the violence of our ancestors. 

  -- from The Collected Sayings of Muad'Dib by the Princess Irulan



[O] [PATCH v3 00/11] Taskjuggler exporter improvements

2012-08-16 Thread Yann Hodique
Hi,

here is a new version of the patch series.
Changes are:

- fixed commit messages format

Yann Hodique (11):
  org-taskjuggler.el: Make task and resource properties customizable
  org-taskjuggler.el: Properly install local variables at export time
  org-taskjuggler.el: Make use of org properties
  org-taskjuggler.el: Fix milestone definition
  org-taskjuggler.el: Introduce a global header, for early macros
  org-taskjuggler.el: Use project end date, if specified
  org-taskjuggler.el: Make project umbrella task optional
  org-taskjuggler.el: Disambiguate headline, as it's a valid attribute
  org-taskjuggler.el: Allow reports definition from within the org file
  org-taskjuggler.el: Update doc to reflect latest changes
  org-taskjuggler.el: Make taskjuggler compatible with org-publish

 doc/org.texi|  48 -
 lisp/org-publish.el |   6 ++
 lisp/org-taskjuggler.el | 180 ++--
 3 files changed, 180 insertions(+), 54 deletions(-)

-- 
1.7.11.4




[O] [PATCH v3 03/11] org-taskjuggler.el: Make use of org properties

2012-08-16 Thread Yann Hodique
* org-taskjuggler.el (org-taskjuggler-date): Introduce new function to
produce a taskjuggler-compatible date.
(org-taskjuggler-components): Make use of SCHEDULED/DEADLINE properties.

Infer start and end date from SCHEDULED/DEADLINE information.
---
 lisp/org-taskjuggler.el | 12 ++--
 1 file changed, 10 insertions(+), 2 deletions(-)

diff --git a/lisp/org-taskjuggler.el b/lisp/org-taskjuggler.el
index 529cda0..93f0cc7 100644
--- a/lisp/org-taskjuggler.el
+++ b/lisp/org-taskjuggler.el
@@ -138,8 +138,6 @@
 ;;   :END:
 ;;
  * TODO
-;;   - Use SCHEDULED and DEADLINE information (not just start and end
-;; properties).
 ;;   - Look at org-file-properties, org-global-properties and
 ;; org-global-properties-fixed
 ;;   - What about property inheritance and org-property-inherit-p?
@@ -385,6 +383,10 @@ with the TaskJuggler GUI.
   (save-excursion
 (and (org-up-heading-safe) (org-entry-get (point) ORDERED
 
+(defun org-taskjuggler-date (date)
+  (let ((time (parse-time-string date)))
+(format %d-%02d-%02d (nth 5 time) (nth 4 time) (nth 3 time
+
 (defun org-taskjuggler-components ()
   Return an alist containing all the pertinent information for
 the current node such as the headline, the level, todo state
@@ -396,6 +398,12 @@ information, all the properties, etc.
  (replace-regexp-in-string
   \ \\\ (nth 4 components) t t)) ; quote double quotes in 
headlines
 (parent-ordered (org-taskjuggler-parent-is-ordered-p)))
+(let ((scheduled (assoc SCHEDULED props))
+ (deadline (assoc DEADLINE props)))
+  (when scheduled
+   (push (cons start (org-taskjuggler-date (cdr scheduled))) props))
+  (when deadline
+   (push (cons end (org-taskjuggler-date (cdr deadline))) props)))
 (push (cons level level) props)
 (push (cons headline headline) props)
 (push (cons parent-ordered parent-ordered) props)))
-- 
1.7.11.4




[O] [PATCH v3 07/11] org-taskjuggler.el: Make project umbrella task optional

2012-08-16 Thread Yann Hodique
* org-taskjuggler.el (org-export-taskjuggler-keep-project-as-task): Add
new option.
(org-export-as-taskjuggler): Optionally drop the topmost task
(project).
(org-taskjuggler-assign-task-ids): Adapt path computation by optionally
dropping the topmost component (project).

Introduce `org-export-taskjuggler-keep-project-as-task' as a flag to
toggle the behavior. Keep old behavior as default.
---
 lisp/org-taskjuggler.el | 23 ---
 1 file changed, 20 insertions(+), 3 deletions(-)

diff --git a/lisp/org-taskjuggler.el b/lisp/org-taskjuggler.el
index 7376302..3c97e03 100644
--- a/lisp/org-taskjuggler.el
+++ b/lisp/org-taskjuggler.el
@@ -264,6 +264,14 @@ but before any resource and task declarations.
   the corresponding resource.
   :group 'org-export-taskjuggler)
 
+(defcustom org-export-taskjuggler-keep-project-as-task t
+  Whether to keep the project headline as an umbrella task for
+  all declared tasks. Setting this to nil will allow maintaining
+  completely separated task buckets, while still sharing the same
+  resources pool.
+  :group 'org-export-taskjuggler
+  :type 'boolean)
+
 ;;; Hooks
 
 (defvar org-export-taskjuggler-final-hook nil
@@ -350,7 +358,10 @@ defined in `org-export-taskjuggler-default-reports'.
 
   (org-clone-local-variables old-buffer ^org-)
   (insert org-export-taskjuggler-default-global-header)
-  (org-taskjuggler-open-project (car tasks))
+  (org-taskjuggler-open-project
+   (if org-export-taskjuggler-keep-project-as-task
+  (car tasks)
+(pop tasks)))
   (insert org-export-taskjuggler-default-global-properties)
   (insert \n)
   (dolist (resource resources)
@@ -365,7 +376,9 @@ defined in `org-export-taskjuggler-default-reports'.
  (org-taskjuggler-close-maybe level)
  (org-taskjuggler-open-task task)
  (setq org-export-taskjuggler-old-level level)))
-  (org-taskjuggler-close-maybe 1)
+  (org-taskjuggler-close-maybe
+   (if org-export-taskjuggler-keep-project-as-task
+  1 2))
   (org-taskjuggler-insert-reports)
   (save-buffer)
   (or (org-export-push-to-kill-ring TaskJuggler)
@@ -446,7 +459,11 @@ a path to the current task.
  (push unique-id (car unique-ids))
  (setcar path unique-id)))
(push (cons unique-id unique-id) task)
-   (push (cons path (mapconcat 'identity (reverse path) .)) task)
+   (push (cons path
+   (mapconcat 'identity
+  (if org-export-taskjuggler-keep-project-as-task
+  (reverse path)
+(cdr (reverse path))) .)) task)
(setq previous-level level)
(setq resolved-tasks (append resolved-tasks (list task)))
 
-- 
1.7.11.4




[O] [PATCH v3 04/11] org-taskjuggler.el: Fix milestone definition

2012-08-16 Thread Yann Hodique
* org-taskjuggler.el (org-taskjuggler-open-task): Task with end-only is
also a milestone (deadline), task with length is not.
---
 lisp/org-taskjuggler.el | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/lisp/org-taskjuggler.el b/lisp/org-taskjuggler.el
index 93f0cc7..a18cdf8 100644
--- a/lisp/org-taskjuggler.el
+++ b/lisp/org-taskjuggler.el
@@ -689,8 +689,10 @@ org-mode priority string.
 (milestone (or (cdr (assoc milestone task))
(and (assoc leaf-node task)
 (not (or effort
+ (cdr (assoc length task))
  (cdr (assoc duration task))
- (cdr (assoc end task))
+ (and (cdr (assoc start task))
+  (cdr (assoc end task)))
  (cdr (assoc period task)))
 (attributes org-export-taskjuggler-valid-task-attributes))
 (insert
-- 
1.7.11.4




[O] [PATCH v3 01/11] org-taskjuggler.el: Make task and resource properties customizable

2012-08-16 Thread Yann Hodique
* org-taskjuggler.el (org-export-taskjuggler-valid-task-attributes): Add
new option.
(org-export-taskjuggler-valid-resource-attributes): Add new custom
option.
---
 lisp/org-taskjuggler.el | 26 --
 1 file changed, 20 insertions(+), 6 deletions(-)

diff --git a/lisp/org-taskjuggler.el b/lisp/org-taskjuggler.el
index aa645d2..7d9d203 100644
--- a/lisp/org-taskjuggler.el
+++ b/lisp/org-taskjuggler.el
@@ -240,6 +240,24 @@ but before any resource and task declarations.
   :version 24.1
   :type '(string :tag Preamble))
 
+(defcustom org-export-taskjuggler-valid-task-attributes
+  '(account start note duration endbuffer endcredit end
+   flags journalentry length limits maxend maxstart minend
+   minstart period reference responsible scheduling
+   startbuffer startcredit statusnote)
+  Valid attributes for Taskjuggler tasks. If one of these
+  appears as a property for a headline, it will be exported with
+  the corresponding task.
+  :group 'org-export-taskjuggler)
+
+(defcustom org-export-taskjuggler-valid-resource-attributes
+  '(limits vacation shift booking efficiency journalentry rate
+  workinghours flags)
+  Valid attributes for Taskjuggler resources. If one of these
+  appears as a property for a headline, it will be exported with
+  the corresponding resource.
+  :group 'org-export-taskjuggler)
+
 ;;; Hooks
 
 (defvar org-export-taskjuggler-final-hook nil
@@ -614,7 +632,7 @@ is defined it will calculate a unique id for the resource 
using
 (cdr (assoc ID resource))
 (cdr (assoc unique-id resource)
(headline (cdr (assoc headline resource)))
-   (attributes '(limits vacation shift booking efficiency journalentry 
rate)))
+   (attributes org-export-taskjuggler-valid-resource-attributes))
 (insert
  (concat
   resource  id  \ headline \ {\n 
@@ -655,11 +673,7 @@ org-mode priority string.
  (cdr (assoc duration task))
  (cdr (assoc end task))
  (cdr (assoc period task)))
-(attributes
- '(account start note duration endbuffer endcredit end
-   flags journalentry length maxend maxstart minend
-   minstart period reference responsible scheduling
-   startbuffer startcredit statusnote)))
+(attributes org-export-taskjuggler-valid-task-attributes))
 (insert
  (concat
   task  unique-id  \ headline \ {\n
-- 
1.7.11.4




[O] [PATCH v3 08/11] org-taskjuggler.el: Disambiguate headline, as it's a valid attribute

2012-08-16 Thread Yann Hodique
---
 lisp/org-taskjuggler.el | 12 ++--
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/lisp/org-taskjuggler.el b/lisp/org-taskjuggler.el
index 3c97e03..33b111d 100644
--- a/lisp/org-taskjuggler.el
+++ b/lisp/org-taskjuggler.el
@@ -329,7 +329,7 @@ defined in `org-export-taskjuggler-default-reports'.
 (unless resources
   (setq resources
`(((resource_id . ,(user-login-name))
-  (headline . ,user-full-name)
+  (HEADLINE . ,user-full-name)
   (level . 1)
 ;; add a default allocation to the first task if none was given
 (unless (assoc allocate (car tasks))
@@ -427,7 +427,7 @@ information, all the properties, etc.
   (when deadline
(push (cons end (org-taskjuggler-date (cdr deadline))) props)))
 (push (cons level level) props)
-(push (cons headline headline) props)
+(push (cons HEADLINE headline) props)
 (push (cons parent-ordered parent-ordered) props)))
 
 (defun org-taskjuggler-assign-task-ids (tasks)
@@ -601,7 +601,7 @@ The id is derived from the headline and made unique against
 UNIQUE-IDS. If the (downcased) first token of the headline is not
 unique try to add more (downcased) tokens of the headline or
 finally add more underscore characters (\_\).
-  (let* ((headline (cdr (assoc headline item)))
+  (let* ((headline (cdr (assoc HEADLINE item)))
 (parts (split-string headline))
 (id (org-taskjuggler-clean-id (downcase (pop parts)
; try to add more parts of the headline 
to make it unique
@@ -627,7 +627,7 @@ attributes from the PROJECT alist are inserted.  If no end 
date is
 specified it is calculated
 `org-export-taskjuggler-default-project-duration' days from now.
   (let* ((unique-id (cdr (assoc unique-id project)))
-(headline (cdr (assoc headline project)))
+(headline (cdr (assoc HEADLINE project)))
 (version (cdr (assoc version project)))
 (start (cdr (assoc start project)))
 (end (cdr (assoc end project
@@ -678,7 +678,7 @@ is defined it will calculate a unique id for the resource 
using
 (or (cdr (assoc resource_id resource))
 (cdr (assoc ID resource))
 (cdr (assoc unique-id resource)
-   (headline (cdr (assoc headline resource)))
+   (headline (cdr (assoc HEADLINE resource)))
(attributes org-export-taskjuggler-valid-resource-attributes))
 (insert
  (concat
@@ -703,7 +703,7 @@ org-mode priority string.
 
 (defun org-taskjuggler-open-task (task)
   (let* ((unique-id (cdr (assoc unique-id task)))
-(headline (cdr (assoc headline task)))
+(headline (cdr (assoc HEADLINE task)))
 (effort (org-taskjuggler-clean-effort (cdr (assoc org-effort-property 
task
 (depends (cdr (assoc depends task)))
 (allocate (cdr (assoc allocate task)))
-- 
1.7.11.4




[O] [PATCH v3 06/11] org-taskjuggler.el: Use project end date, if specified

2012-08-16 Thread Yann Hodique
* org-taskjuggler.el (org-taskjuggler-open-project): Use START - END as
an alternative to START +Xd.
---
 lisp/org-taskjuggler.el | 6 --
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/lisp/org-taskjuggler.el b/lisp/org-taskjuggler.el
index c997da7..7376302 100644
--- a/lisp/org-taskjuggler.el
+++ b/lisp/org-taskjuggler.el
@@ -615,9 +615,11 @@ specified it is calculated
 (start (cdr (assoc start project)))
 (end (cdr (assoc end project
 (insert
- (format project %s \%s\ \%s\ %s +%sd {\n }\n
+ (format project %s \%s\ \%s\ %s %s {\n }\n
 unique-id headline version start
-org-export-taskjuggler-default-project-duration
+ (or (and end (format - %s end))
+ (format +%sd
+ org-export-taskjuggler-default-project-duration))
 
 (defun org-taskjuggler-filter-and-join (items)
   Filter all nil elements from ITEMS and join the remaining ones
-- 
1.7.11.4




[O] [PATCH v3 09/11] org-taskjuggler.el: Allow reports definition from within the org file

2012-08-16 Thread Yann Hodique
* org-taskjuggler.el (org-export-taskjuggler-report-tag): Add
new option.
(org-export-taskjuggler-valid-report-attributes): Add new option.
(org-export-as-taskjuggler): Compute reports.
(org-taskjuggler-open-report): Generate report from org item.
(org-taskjuggler-insert-reports): Insert default reports only if no
explicit one is defined.
---
 lisp/org-taskjuggler.el | 42 +-
 1 file changed, 37 insertions(+), 5 deletions(-)

diff --git a/lisp/org-taskjuggler.el b/lisp/org-taskjuggler.el
index 33b111d..49c24ff 100644
--- a/lisp/org-taskjuggler.el
+++ b/lisp/org-taskjuggler.el
@@ -181,6 +181,13 @@ resources for the project.
   :version 24.1
   :type 'string)
 
+(defcustom org-export-taskjuggler-report-tag taskjuggler_report
+  Tag, property or todo used to find the tree containing all the
+reports for the project.
+  :group 'org-export-taskjuggler
+  :version 24.1
+  :type 'string)
+
 (defcustom org-export-taskjuggler-target-version 2.4
   Which version of TaskJuggler the exporter is targeting.
   :group 'org-export-taskjuggler
@@ -264,6 +271,14 @@ but before any resource and task declarations.
   the corresponding resource.
   :group 'org-export-taskjuggler)
 
+(defcustom org-export-taskjuggler-valid-report-attributes
+  '(headline columns definitions timeformat hideresource hidetask
+loadunit sorttasks formats period)
+  Valid attributes for Taskjuggler reports. If one of these
+  appears as a property for a headline, it will be exported with
+  the corresponding report.
+  :group 'org-export-taskjuggler)
+
 (defcustom org-export-taskjuggler-keep-project-as-task t
   Whether to keep the project headline as an umbrella task for
   all declared tasks. Setting this to nil will allow maintaining
@@ -314,6 +329,10 @@ defined in `org-export-taskjuggler-default-reports'.
   (org-map-entries
'org-taskjuggler-components
org-export-taskjuggler-resource-tag nil 'archive 'comment)))
+(reports
+ (org-map-entries
+  'org-taskjuggler-components
+  org-export-taskjuggler-report-tag nil 'archive 'comment))
 (filename (expand-file-name
(concat
 (file-name-sans-extension
@@ -379,7 +398,7 @@ defined in `org-export-taskjuggler-default-reports'.
   (org-taskjuggler-close-maybe
(if org-export-taskjuggler-keep-project-as-task
   1 2))
-  (org-taskjuggler-insert-reports)
+  (org-taskjuggler-insert-reports reports)
   (save-buffer)
   (or (org-export-push-to-kill-ring TaskJuggler)
  (message Exporting... done))
@@ -741,6 +760,16 @@ org-mode priority string.
   (org-taskjuggler-get-attributes task attributes)
   \n
 
+(defun org-taskjuggler-open-report (report)
+  (let* ((kind (or (cdr (assoc report-kind report)) taskreport))
+(headline (cdr (assoc HEADLINE report)))
+(attributes org-export-taskjuggler-valid-report-attributes))
+(insert
+ (concat
+  kind  \ headline \ {\n
+  (org-taskjuggler-get-attributes report attributes)
+  \n}\n
+
 (defun org-taskjuggler-close-maybe (level)
   (while ( org-export-taskjuggler-old-level level)
 (insert }\n)
@@ -748,10 +777,13 @@ org-mode priority string.
   (when (= org-export-taskjuggler-old-level level)
 (insert }\n)))
 
-(defun org-taskjuggler-insert-reports ()
-  (let (report)
-(dolist (report org-export-taskjuggler-default-reports)
-  (insert report \n
+(defun org-taskjuggler-insert-reports (reports)
+  (if reports
+  (dolist (report (cdr reports))
+   (org-taskjuggler-open-report report))
+(let (report)
+  (dolist (report org-export-taskjuggler-default-reports)
+   (insert report \n)
 
 (provide 'org-taskjuggler)
 
-- 
1.7.11.4




[O] [PATCH v3 11/11] org-taskjuggler.el: Make taskjuggler compatible with org-publish

2012-08-16 Thread Yann Hodique
* lisp/org-publish.el (org-publish-org-to-taskjuggler): New function to
publish taskjuggler projects.
* lisp/org-taskjuggler.el (org-export-as-taskjuggler): Adapt signature
to reflect standard interface, in particular allow export to buffer.
---
 lisp/org-publish.el |  6 ++
 lisp/org-taskjuggler.el | 33 +++--
 2 files changed, 29 insertions(+), 10 deletions(-)

diff --git a/lisp/org-publish.el b/lisp/org-publish.el
index ed2db3a..e78e2d4 100644
--- a/lisp/org-publish.el
+++ b/lisp/org-publish.el
@@ -649,6 +649,12 @@ See `org-publish-org-to' to the list of arguments.
   (org-publish-with-aux-preprocess-maybe
(org-publish-org-to utf8 plist filename pub-dir)))
 
+(defun org-publish-org-to-taskjuggler (plist filename pub-dir)
+  Publish an org file to TaskJuggler.
+See `org-publish-org-to' to the list of arguments.
+  (org-publish-with-aux-preprocess-maybe
+   (org-publish-org-to taskjuggler plist filename pub-dir)))
+
 (defun org-publish-attachment (plist filename pub-dir)
   Publish a file with no transformation of any kind.
 See `org-publish-org-to' to the list of arguments.
diff --git a/lisp/org-taskjuggler.el b/lisp/org-taskjuggler.el
index 49c24ff..1733fe8 100644
--- a/lisp/org-taskjuggler.el
+++ b/lisp/org-taskjuggler.el
@@ -298,7 +298,8 @@ but before any resource and task declarations.
 (defvar org-export-taskjuggler-old-level)
 
 ;;;###autoload
-(defun org-export-as-taskjuggler ()
+(defun org-export-as-taskjuggler (optional arg hidden ext-plist
+   to-buffer body-only pub-dir)
   Export parts of the current buffer as a TaskJuggler file.
 The exporter looks for a tree with tag, property or todo that
 matches `org-export-taskjuggler-project-tag' and takes this as
@@ -310,11 +311,12 @@ resources for the project.  If no resources are 
specified, a
 default resource is created and allocated to the project.  Also
 the taskjuggler project will be created with default reports as
 defined in `org-export-taskjuggler-default-reports'.
-  (interactive)
+  (interactive P)
 
   (message Exporting...)
   (setq-default org-done-keywords org-done-keywords)
   (let* ((opt-plist (org-combine-plists (org-default-export-plist)
+   ext-plist
 (org-infile-export-plist)))
 (org-export-opt-plist opt-plist)
  (tasks
@@ -333,12 +335,20 @@ defined in `org-export-taskjuggler-default-reports'.
  (org-map-entries
   'org-taskjuggler-components
   org-export-taskjuggler-report-tag nil 'archive 'comment))
-(filename (expand-file-name
-   (concat
-(file-name-sans-extension
- (file-name-nondirectory buffer-file-name))
-org-export-taskjuggler-extension)))
-(buffer (find-file-noselect filename))
+(filename (if to-buffer
+  nil
+(concat (file-name-as-directory
+ (or pub-dir
+ (org-export-directory :tj opt-plist)))
+(file-name-sans-extension
+ (file-name-nondirectory buffer-file-name))
+org-export-taskjuggler-extension)))
+(buffer (if to-buffer
+(cond
+ ((eq to-buffer 'string)
+  (get-buffer-create *Org Taskjuggler Export*))
+ (t (get-buffer-create to-buffer)))
+  (find-file-noselect filename)))
 (old-buffer (current-buffer))
 (org-export-taskjuggler-old-level 0)
 task resource)
@@ -399,10 +409,13 @@ defined in `org-export-taskjuggler-default-reports'.
(if org-export-taskjuggler-keep-project-as-task
   1 2))
   (org-taskjuggler-insert-reports reports)
-  (save-buffer)
+  (or to-buffer (save-buffer))
   (or (org-export-push-to-kill-ring TaskJuggler)
  (message Exporting... done))
-  (current-buffer
+  (if (eq to-buffer 'string)
+ (prog1 (buffer-substring (point-min) (point-max))
+   (kill-buffer (current-buffer)))
+   (current-buffer)
 
 ;;;###autoload
 (defun org-export-as-taskjuggler-and-open ()
-- 
1.7.11.4




Re: [O] Offline until sunday eve -- please heavily test current HEAD

2012-08-16 Thread Achim Gratz
Bastien writes:
 Please heavily test the current HEAD of the git repository.
 If you have bugs that you didn't send to the list, please do
 it now.

I get these test fails with Emacs 24.1, 24.2-rc (but not on 24.1.50 or
24.2.50, although the latter activates only 214 instead of 371 tests,
which seems to require a separate investigation since the setup is the
same otherwise):

Test ob-exp/exports-both condition:
(void-function my-map)
   FAILED   17/371  ob-exp/exports-both

Test test-org-babel/multi-line-header-arguments condition:
(void-function my-map)
   FAILED  156/371  test-org-babel/multi-line-header-arguments

Test test-org-babel/multi-line-header-arguments backtrace:
  (my-map (quote list) (function list) numbers letters)
  (let ((numbers (quote (1 2 3 4 5 6 7))) (letters (quote (a b c d e f
  (progn (let ((numbers (quote (1 2 3 4 5 6 7))) (letters (quote (a b 
  eval((progn (let ((numbers (quote (1 2 3 4 5 6 7))) (letters (quote 
  ((lambda (result) (if (or (member scalar (cdr (assoc :result-param
  (progn ((lambda (result) (if (or (member scalar (cdr (assoc :resul
  (unwind-protect (progn ((lambda (result) (if (or (member scalar (c
  (let ((wconfig (current-window-configuration))) (unwind-protect (pro
  (save-window-excursion ((lambda (result) (if (or (member scalar (c
  org-babel-execute:emacs-lisp((require 'cl)\n(defalias 'my-map (if (
  funcall(org-babel-execute:emacs-lisp (require 'cl)\n(defalias 'my-m
  ((lambda (result) (if (and (eq (cdr (assoc :result-type params)) (qu
  (setq result ((lambda (result) (if (and (eq (cdr (assoc :result-type
  (if (and (not arg) new-hash (equal new-hash old-hash)) (save-excursi
  (let ((call-process-region (lambda (rest args) (apply (quote org-ba
  (unwind-protect (let ((call-process-region (lambda (rest args) (app
  (let* ((lang (nth 0 info)) (params (if params (org-babel-process-par
  (progn (let* ((lang (nth 0 info)) (params (if params (org-babel-proc
  (if (org-babel-confirm-evaluate (let ((i info)) (setf (nth 2 i) (org
  (when (org-babel-confirm-evaluate (let ((i info)) (setf (nth 2 i) (o
  (let ((info (or info (org-babel-get-src-block-info (when (org-ba
  org-babel-execute-src-block()
  (let ((results (org-babel-execute-src-block))) (should (equal (quote
  (progn (org-babel-next-src-block) (let ((results (org-babel-execute-
  (setq G16529 (progn (org-babel-next-src-block) (let ((results (org-b
  (let ((kill-buffer-query-functions nil) G16529) (with-temp-file /tm
  (org-test-with-temp-text-in-file \n\n#+headers: :var letters='(a b 

With Emacs 23.3, I get this test error:

Test test-ob-sh/session condition:
(error Marker does not point anywhere)
   FAILED  112/211  test-ob-sh/session

Test test-ob-sh/session backtrace:
  (cl-block-wrapper (catch (quote --cl-block-nil--) (let* ((i 6) (fram
  (block nil (let* ((i 6) (frame nil) (--cl-var-- nil)) (while (progn 
  (loop for i from 6 for frame = (backtrace-frame i) while frame colle
  ert--record-backtrace()
  (let* ((condition (first more-debugger-args)) (type (case (car condi
  (cond ((member* first-debugger-arg (quote (lambda debug t exit nil))
  (case first-debugger-arg ((lambda debug t exit nil) (apply (ert--tes
  (ecase first-debugger-arg ((lambda debug t exit nil) (apply (ert--te
  (let* ((more-debugger-args debugger-args) (first-debugger-arg (if mo
  (progn (let* ((more-debugger-args debugger-args) (first-debugger-arg
  (destructuring-bind (first-debugger-arg rest more-debugger-args) de
  ert--run-test-debugger([cl-struct-ert--test-execution-info [cl-struc
  (lambda (G99254 rest debugger-args) (ert--run-test-debugger (symbol
  apply((lambda (G99254 rest debugger-args) (ert--run-test-debugger (
  (lambda (rest --cl-rest--) (apply (lambda (G99254 rest debugger-ar
  ansi-color-apply-on-region(#marker in no buffer #marker at 16 in 
  ansi-color-process-output()
  run-hook-with-args(ansi-color-process-output )
  comint-send-input(nil t)

These look like further fallout from the cl-flet excision...  The fails
happen in the same way when I run the tests on bytecode produced with
another Emacs version or even uncompiled, so I don't think the bytecode
is to blame.


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

Wavetables for the Terratec KOMPLEXER:
http://Synth.Stromeko.net/Downloads.html#KomplexerWaves




[O] [PATCH v3 05/11] org-taskjuggler.el: Introduce a global header, for early macros

2012-08-16 Thread Yann Hodique
* org-taskjuggler.el (org-export-taskjuggler-default-global-header): Add
new option.
(org-export-as-taskjuggler): Insert global header before anything else.
---
 lisp/org-taskjuggler.el | 19 ++-
 1 file changed, 14 insertions(+), 5 deletions(-)

diff --git a/lisp/org-taskjuggler.el b/lisp/org-taskjuggler.el
index a18cdf8..c997da7 100644
--- a/lisp/org-taskjuggler.el
+++ b/lisp/org-taskjuggler.el
@@ -221,6 +221,14 @@ with `org-export-taskjuggler-project-tag'
   :version 24.1
   :type '(repeat (string :tag Report)))
 
+(defcustom org-export-taskjuggler-default-global-header
+  
+  Default global header for the project. This goes before
+project declaration, and might be useful for early macros
+  :group 'org-export-taskjuggler
+  :version 24.1
+  :type '(string :tag Preamble))
+
 (defcustom org-export-taskjuggler-default-global-properties
   shift s40 \Part time shift\ {
   workinghours wed, thu, fri off
@@ -332,11 +340,6 @@ defined in `org-export-taskjuggler-default-reports'.
(setcar tasks (push (cons version version) task
 (with-current-buffer buffer
   (erase-buffer)
-  (org-clone-local-variables old-buffer ^org-)
-  (org-taskjuggler-open-project (car tasks))
-  (insert org-export-taskjuggler-default-global-properties)
-  (insert \n)
-  (dolist (resource resources)
   (org-install-letbind)
   ;; create local variables for all options, to make sure all called
   ;; functions get the correct information
@@ -345,6 +348,12 @@ defined in `org-export-taskjuggler-default-reports'.
(plist-get opt-plist (car x
 org-export-plist-vars)
 
+  (org-clone-local-variables old-buffer ^org-)
+  (insert org-export-taskjuggler-default-global-header)
+  (org-taskjuggler-open-project (car tasks))
+  (insert org-export-taskjuggler-default-global-properties)
+  (insert \n)
+  (dolist (resource resources)
(let ((level (cdr (assoc level resource
  (org-taskjuggler-close-maybe level)
  (org-taskjuggler-open-resource resource)
-- 
1.7.11.4




[O] [patch] change indentation logic for edit-src

2012-08-16 Thread Ken Williams
Following on a message from a few days ago, I've prepared a patch (attached) 
that alters the behavior of 'org-edit-src-exit' so that it no longer adds an 
extra 2 spaces of indentation each time a source block (or a table.el table) is 
edited.  Previously a workaround was to set 'org-src-preserve-indentation', but 
without that set, you'd get the undesirable behavior.

There's probably some stuff wrong with this approach - let me know.  I'm new to 
both elisp programming and the org-mode code.

I also created a little utility function 'org-prefixify', not sure whether 
that's kosher or not.  One change that would be nice to make to it is to avoid 
prefixing the final line if it's blank, but I couldn't get that to work.  Also 
- could that essentially be replaced by a call to string-insert-rectangle?

--
Ken Williams, Senior Research Scientist
WindLogics
http://windlogics.com



CONFIDENTIALITY NOTICE: This e-mail message is for the sole use of the intended 
recipient(s) and may contain confidential and privileged information. Any 
unauthorized review, use, disclosure or distribution of any kind is strictly 
prohibited. If you are not the intended recipient, please contact the sender 
via reply e-mail and destroy all copies of the original message. Thank you.
From d80b7726402a39b4c8a630a86614b0ba9d7eca6a Mon Sep 17 00:00:00 2001
From: Ken Williams ken.willi...@windlogics.com
Date: Thu, 16 Aug 2012 13:26:44 -0500
Subject: [PATCH] Change the edit-src-save code so that it either preserves
 original formatting, or imposes its new indentation, but
 not both.

---
 lisp/org-src.el |   22 +++---
 1 files changed, 11 insertions(+), 11 deletions(-)

diff --git a/lisp/org-src.el b/lisp/org-src.el
index c110f32..61b800f 100644
--- a/lisp/org-src.el
+++ b/lisp/org-src.el
@@ -601,11 +601,9 @@ the language, a switch telling if the content should be in 
a single line.
 (buffer (current-buffer))
 (single (org-bound-and-true-p org-edit-src-force-single-line))
 (macro (eq single 'macro-definition))
-(total-nindent (+ (or org-edit-src-block-indentation 0)
-  org-edit-src-content-indentation))
 (preserve-indentation org-src-preserve-indentation)
 (allow-write-back-p (org-bound-and-true-p 
org-edit-src-allow-write-back-p))
-(delta 0) code line col indent)
+(delta 0) code line col indent total-nindent)
 (when allow-write-back-p
   (unless preserve-indentation (untabify (point-min) (point-max)))
   (if org-src-strip-leading-and-trailing-blank-lines
@@ -640,14 +638,10 @@ the language, a switch telling if the content should be 
in a single line.
   (when (org-bound-and-true-p org-edit-src-picture)
(setq preserve-indentation nil)
(untabify (point-min) (point-max))
-   (goto-char (point-min))
-   (while (re-search-forward ^ nil t)
- (replace-match : )))
-  (unless (or single preserve-indentation (= total-nindent 0))
-   (setq indent (make-string total-nindent ?\ ))
-   (goto-char (point-min))
-   (while (re-search-forward ^ nil t)
- (replace-match indent)))
+   (org-prefixify : ))
+  (setq total-nindent (if preserve-indentation (or 
org-edit-src-block-indentation 0)
+   org-edit-src-content-indentation ))
+  (org-prefixify (make-string total-nindent ?\ ))
   (if (org-bound-and-true-p org-edit-src-picture)
  (setq total-nindent (+ total-nindent 2)))
   (setq code (buffer-string))
@@ -692,6 +686,12 @@ the language, a switch telling if the content should be in 
a single line.
  (message (or msg 
 (def-edebug-spec org-src-in-org-buffer (body))
 
+(defun org-prefixify (s)
+  (unless (string=  s)
+(goto-char (point-min))
+(while (re-search-forward ^ nil t)
+  (replace-match s
+
 (defun org-edit-src-save ()
   Save parent buffer with current state source-code buffer.
   (interactive)
-- 
1.7.9



[O] [PATCH v3 02/11] org-taskjuggler.el: Properly install local variables at export time

2012-08-16 Thread Yann Hodique
* org-taskjuggler.el (org-export-as-taskjuggler): Compute opt-plist, use
`org-install-letbind'.
---
 lisp/org-taskjuggler.el | 13 -
 1 file changed, 12 insertions(+), 1 deletion(-)

diff --git a/lisp/org-taskjuggler.el b/lisp/org-taskjuggler.el
index 7d9d203..529cda0 100644
--- a/lisp/org-taskjuggler.el
+++ b/lisp/org-taskjuggler.el
@@ -285,7 +285,10 @@ defined in `org-export-taskjuggler-default-reports'.
 
   (message Exporting...)
   (setq-default org-done-keywords org-done-keywords)
-  (let* ((tasks
+  (let* ((opt-plist (org-combine-plists (org-default-export-plist)
+(org-infile-export-plist)))
+(org-export-opt-plist opt-plist)
+ (tasks
  (org-taskjuggler-resolve-dependencies
   (org-taskjuggler-assign-task-ids
(org-taskjuggler-compute-task-leafiness
@@ -336,6 +339,14 @@ defined in `org-export-taskjuggler-default-reports'.
   (insert org-export-taskjuggler-default-global-properties)
   (insert \n)
   (dolist (resource resources)
+  (org-install-letbind)
+  ;; create local variables for all options, to make sure all called
+  ;; functions get the correct information
+  (mapc (lambda (x)
+  (set (make-local-variable (nth 2 x))
+   (plist-get opt-plist (car x
+org-export-plist-vars)
+
(let ((level (cdr (assoc level resource
  (org-taskjuggler-close-maybe level)
  (org-taskjuggler-open-resource resource)
-- 
1.7.11.4




[O] [PATCH v3 10/11] org-taskjuggler.el: Update doc to reflect latest changes

2012-08-16 Thread Yann Hodique
---
 doc/org.texi | 48 ++--
 1 file changed, 30 insertions(+), 18 deletions(-)

diff --git a/doc/org.texi b/doc/org.texi
index 3fdb4ac..0f8b0d9 100644
--- a/doc/org.texi
+++ b/doc/org.texi
@@ -11898,9 +11898,9 @@ nodes of a document or strictly follow the order of the 
nodes in the
 document.
 
 Instead the TaskJuggler exporter looks for a tree that defines the tasks and
-a optionally tree that defines the resources for this project.  It then
-creates a TaskJuggler file based on these trees and the attributes defined in
-all the nodes.
+optionally trees that define the resources and reports for this project.
+It then creates a TaskJuggler file based on these trees and the attributes
+defined in all the nodes.
 
 @subsection TaskJuggler export commands
 
@@ -11909,7 +11909,8 @@ all the nodes.
 Export as a TaskJuggler file.
 
 @orgcmd{C-c C-e J,org-export-as-taskjuggler-and-open}
-Export as a TaskJuggler file and then open the file with TaskJugglerUI.
+Export as a TaskJuggler file and then open the file with TaskJugglerUI (only
+for TaskJugglerUI 2.x).
 @end table
 
 @subsection Tasks
@@ -11947,15 +11948,17 @@ time.
 
 @subsection Export of properties
 
-The exporter also takes TODO state information into consideration, i.e.@: if a
-task is marked as done it will have the corresponding attribute in
-TaskJuggler (@samp{complete 100}).  Also it will export any property on a task
-resource or resource node which is known to TaskJuggler, such as
-@samp{limits}, @samp{vacation}, @samp{shift}, @samp{booking},
-@samp{efficiency}, @samp{journalentry}, @samp{rate} for resources or
-@samp{account}, @samp{start}, @samp{note}, @samp{duration}, @samp{end},
-@samp{journalentry}, @samp{milestone}, @samp{reference}, @samp{responsible},
-@samp{scheduling}, etc for tasks.
+The exporter also takes TODO state information into consideration, i.e.@: if
+a task is marked as done it will have the corresponding attribute in
+TaskJuggler (@samp{complete 100}).  Scheduling information is also taken into
+account to set start/end dates for tasks.
+
+The exporter will also export any property on a task resource or resource
+node which is known to TaskJuggler, such as @samp{limits}, @samp{vacation},
+@samp{shift}, @samp{booking}, @samp{efficiency}, @samp{journalentry},
+@samp{rate} for resources or @samp{account}, @samp{start}, @samp{note},
+@samp{duration}, @samp{end}, @samp{journalentry}, @samp{milestone},
+@samp{reference}, @samp{responsible}, @samp{scheduling}, etc for tasks.
 
 @subsection Dependencies
 
@@ -12001,11 +12004,20 @@ examples should illustrate this:
 @vindex org-export-taskjuggler-default-reports
 TaskJuggler can produce many kinds of reports (e.g.@: gantt chart, resource
 allocation, etc).  The user defines what kind of reports should be generated
-for a project in the TaskJuggler file.  The exporter will automatically insert
-some default reports in the file.  These defaults are defined in
-@code{org-export-taskjuggler-default-reports}.  They can be modified using
-customize along with a number of other options.  For a more complete list, see
-@kbd{M-x customize-group @key{RET} org-export-taskjuggler @key{RET}}.
+for a project in the TaskJuggler file.  By default, the exporter will
+automatically insert some pre-set reports in the file.  These defaults are
+defined in @code{org-export-taskjuggler-default-reports}.  They can be
+modified using customize along with a number of other options.  For a more
+complete list, see @kbd{M-x customize-group @key{RET} org-export-taskjuggler
+@key{RET}}.
+
+Alternately, the user can tag a tree with
+@code{org-export-taskjuggler-report-tag}, and define reports in sub-nodes,
+similarly to what is done with tasks or resources.  The properties used for
+report generation are defined in
+@code{org-export-taskjuggler-valid-report-attributes}. In addition, a special
+property named @samp{report-kind} is used to define the kind of report one
+wants to generate (by default, a @samp{taskreport}).
 
 For more information and examples see the Org-taskjuggler tutorial at
 @uref{http://orgmode.org/worg/org-tutorials/org-taskjuggler.html}.
-- 
1.7.11.4




[O] How to use texi2dvi for export to LaTeX?

2012-08-16 Thread Marius Hofert
Hi,

I found http://orgmode.org/worg/org-dependencies.html and proceeded as described
there to set up texi2dvi for LaTeX export. I don't have the egrep bug mentioned,
so all I had to do was:

1) put this in ~/.emacs:
   (setq org-latex-to-pdf-process texi2dvi -p %f); use texi2dvi; see
   http://orgmode.org/worg/org-dependencies.html
2) put this in ~/.profile:
   PDFLATEX=pdflatex --shell-escape
   export PDFLATEX

texi2dvi is installed on my system (Ubuntu 12.04; Emacs 24; MacBook Air 4,1) and
works. However, if I export an org-mode file via 'C-c C-e p' to LaTeX, I obtain
an error. *Messages* shows:

,
| call-interactively: Wrong type argument: listp, texi2dvi -p %f
`

Why?

Something I'm wondering: Doesn't %f stand for the base file name with ending
.ps? Shouldn't it be texi2dvi -p %t? Trying this led to the same error, though.

Cheers,

Marius





Re: [O] [ANN] Editable HTML export of Org-mode files

2012-08-16 Thread Ista Zahn
On Thu, Aug 16, 2012 at 12:36 PM, Eric Schulte eric.schu...@gmx.com wrote:
 Ista Zahn istaz...@gmail.com writes:

 On Thu, Aug 16, 2012 at 2:31 AM, Eric Schulte eric.schu...@gmx.com wrote:
 Ista Zahn istaz...@gmail.com writes:

 Hi Eric,

 Sounds really cool, I'd love to try it out. But when I run (ert
 org-ehtml) I get errors like

 Selector: org-ehtml
 Passed: 0
 Failed: 5 (5 unexpected)
 Total:  5/6

 Started at:   2012-08-15 22:00:20-0400
 Finished.
 Finished at:  2012-08-15 22:00:50-0400

 FFQFFF

 F org-ehtml-elnode-serve-all-editable
 (void-function cl-flet)

 F org-ehtml-elnode-serve-complex
 (void-function cl-flet)

 Q org-ehtml-elnode-serve-simple
 (quit)

 F org-ehtml-export-file
 (void-variable org-export-with-LaTeX-fragments)

 F org-ehtml-post-request
 (error Shell command in progress)

 F org-ehtml-simple-export
 (void-variable org-export-with-LaTeX-fragments)

 This is with the git version of org and emacs 24.1.1

 Any ideas what I might have missed?

 Thanks,
 Ista


 Ah, thanks for sharing this output, it looks like I wasn't careful
 enough about ensuring that cl-lib was loaded.  I've added a number of
 require statements which should fix the error you pointed out above.

 Please grab the latest from git, and let me know if these problems
 persist or any new issues assert themselves.

 With the current git version I now get File error: Cannot open load
 file, cl-lib on start up.

 find / -name cl-lib.el does not produce any results on my machine, nor
 have I been able to find it in elpa/marmalade etc. Google search
 suggests it is built in with emacs, but I'm pretty sure I don't have
 it...


 Ugh, this is more headache related to the renaming of all cl-* functions
 between the released version of Emacs 24 and the development head of
 Emacs (which I'm using).  I've just pushed up a change after which all
 tests are passing on both the development head and the released version
 of Emacs 24.

 Thanks for your help in running this down.


All is working as expected, and as expected it's really cool. Thank you!

Now if I could just edit babel source blocks and have the results
blocks update on the fly I would be in R workshop presenter heaven.
Any chance of this sort of thing down the road?


 Best,


 Best,
 Ista


 Thanks,

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


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



Re: [O] [ANN] Editable HTML export of Org-mode files

2012-08-16 Thread Eric Schulte


 All is working as expected, and as expected it's really cool. Thank you!


Great, happy its working.


 Now if I could just edit babel source blocks and have the results
 blocks update on the fly I would be in R workshop presenter heaven.
 Any chance of this sort of thing down the road?


Yea, I haven't implemented an edit interface for code blocks yet.  As
you suggest I think that they could benefit from a customized edit
interface, luckily Nicolas' org-export makes element-specific exports
easy to implement.

I'm not sure what sort of interaction would be best...
- would a [RUN] button be useful
- should just the body of the code block be editable, or everything
- should code block results have a re-run button

No solution has jumped out yet, so I'm just wanting till something seems
obvious.  If you have more specific ideas I'd love to hear them.  I
think something like Python's notebooks should be fairly easy to
implement.

Cheers,



 Best,


 Best,
 Ista


 Thanks,

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


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


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



Re: [O] [ANN] Editable HTML export of Org-mode files

2012-08-16 Thread Eric Schulte
Achim Gratz strom...@nexgo.de writes:

 Eric Schulte writes:
 Ugh, this is more headache related to the renaming of all cl-* functions
 between the released version of Emacs 24 and the development head of
 Emacs (which I'm using).  I've just pushed up a change after which all
 tests are passing on both the development head and the released version
 of Emacs 24.

 Note that there's yet a new wrinkle with the upcoming release of the
 24.2 version (which hasn't made the change yet), so 24.1.50 and
 24.2.50 and later have new-style cl libraries...


Ah, good to know thanks.  I guess I should catch up on my emacs-dev
reading.

Cheers,



 Regards,
 Achim.

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



Re: [O] How to use texi2dvi for export to LaTeX?

2012-08-16 Thread Achim Gratz
Marius Hofert writes:
 I found http://orgmode.org/worg/org-dependencies.html and proceeded as 
 described
 there to set up texi2dvi for LaTeX export. I don't have the egrep bug 
 mentioned,
 so all I had to do was:

 1) put this in ~/.emacs:
(setq org-latex-to-pdf-process texi2dvi -p %f); use texi2dvi; see
http://orgmode.org/worg/org-dependencies.html

This is missing a `'(…)´ around the string.  But you should rather use
customize to change that variable, which should be a list of strings
(just on in your case).  Org-latex needs to have been loaded before the
variable can be customized, however.

 2) put this in ~/.profile:
PDFLATEX=pdflatex --shell-escape
export PDFLATEX

You might not want to do this either.  The canonical way to set the
environment for a single command is to define it right there with the
invocation of the command.

 (setq org-latex-to-pdf-process PDFLATEX=\pdflatex --shell-escape\ texi2dvi 
-p %f)

Or if your system still had the locale bug even

 (setq org-latex-to-pdf-process LC_ALL=C PDFLATEX=\pdflatex --shell-escape\ 
texi2dvi -p %f)


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

Wavetables for the Terratec KOMPLEXER:
http://Synth.Stromeko.net/Downloads.html#KomplexerWaves




Re: [O] How to use texi2dvi for export to LaTeX?

2012-08-16 Thread Nick Dokos
Achim Gratz strom...@nexgo.de wrote:

 Marius Hofert writes:
  I found http://orgmode.org/worg/org-dependencies.html and proceeded as 
  described
  there to set up texi2dvi for LaTeX export. I don't have the egrep bug 
  mentioned,
  so all I had to do was:
 
  1) put this in ~/.emacs:
 (setq org-latex-to-pdf-process texi2dvi -p %f); use texi2dvi; see
 http://orgmode.org/worg/org-dependencies.html
 
 This is missing a `'(…)´ around the string.  But you should rather use
 customize to change that variable, which should be a list of strings
 (just on in your case).  Org-latex needs to have been loaded before the
 variable can be customized, however.
 

I fixed that on worg.

  2) put this in ~/.profile:
 PDFLATEX=pdflatex --shell-escape
 export PDFLATEX
 
 You might not want to do this either.  The canonical way to set the
 environment for a single command is to define it right there with the
 invocation of the command.
 
  (setq org-latex-to-pdf-process PDFLATEX=\pdflatex --shell-escape\ 
 texi2dvi -p %f)
 
 Or if your system still had the locale bug even
 
  (setq org-latex-to-pdf-process LC_ALL=C PDFLATEX=\pdflatex 
 --shell-escape\ texi2dvi -p %f)
 

I added this comment to worg as well, but note that the setqs need the '(...) 
treatment.

Nick

 
 Regards,
 Achim.
 -- 
 +[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]+
 
 Wavetables for the Terratec KOMPLEXER:
 http://Synth.Stromeko.net/Downloads.html#KomplexerWaves
 
 



Re: [O] [ANN] Editable HTML export of Org-mode files

2012-08-16 Thread Ista Zahn
On Thu, Aug 16, 2012 at 4:11 PM, Eric Schulte eric.schu...@gmx.com wrote:


 All is working as expected, and as expected it's really cool. Thank you!


 Great, happy its working.


 Now if I could just edit babel source blocks and have the results
 blocks update on the fly I would be in R workshop presenter heaven.
 Any chance of this sort of thing down the road?


 Yea, I haven't implemented an edit interface for code blocks yet.  As
 you suggest I think that they could benefit from a customized edit
 interface, luckily Nicolas' org-export makes element-specific exports
 easy to implement.

 I'm not sure what sort of interaction would be best...
 - would a [RUN] button be useful
 - should just the body of the code block be editable, or everything
 - should code block results have a re-run button

Personally I would like to see it work pretty much the same as other
editable elements, except that it would re-run the code and update the
results block. So you could just

1) click to edit the source block
2) make changes to the code
3) click save

and any results block would be updated to the result of your changes in step 2.


Best,
Ista

 No solution has jumped out yet, so I'm just wanting till something seems
 obvious.  If you have more specific ideas I'd love to hear them.  I
 think something like Python's notebooks should be fairly easy to
 implement.

 Cheers,



 Best,


 Best,
 Ista


 Thanks,

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


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


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



Re: [O] How to use texi2dvi for export to LaTeX?

2012-08-16 Thread Achim Gratz
Nick Dokos writes:
 I fixed that on worg.

Thanks.

 I added this comment to worg as well, but note that the setqs need the '(...) 
 treatment.

Too much copy and paste... again it should be customized, not setq'd
anyway.


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

Samples for the Waldorf Blofeld:
http://Synth.Stromeko.net/Downloads.html#BlofeldSamplesExtra




Re: [O] [babel, ess] How can I make S-RET to be multi-session friendly?

2012-08-16 Thread Mikhail Titov
Bastien b...@gnu.org writes:

 I would say that after applying changes to my-ess-eval and to
 org-babel-edit-prep:R as suggested by Andrew, it looks like everything
 is working right for me.

 I'v been bold and I pushed the change Andrew suggested.

 Thanks for reporting this and for testing around -- and thanks
 to Andrew for the exploration and the fix! 

Though not related to Org, I noticed that ess-make-buffer-current calls
(update-ess-process-name-list) thus making a call for it in my-ess-eval,
probably, somewhat redundant, right?

Another thing that somewhat bugs me is that if R process quits (or
probably dies as well) when editing source code block in a separate
buffer, the subsequent S-RET will silently execute a line in a wrong
buffer/process. If there are no buffers with R process, it will create
the default *R* named buffer. It might be exotic but I think it is an
issue.

Does it mean that there is a bug in ess-make-buffer-current function
somewhere? Something, probably, re-associates a buffer to another
process, does it?

I think it might be relevant that code editing buffer local variable
ess-local-process-name is non-nil when associated process quits. This
results in first ess-make-buffer-current in my-ess-eval silently
launching *R*.

I'm not sure if it is too much to fix. Perhaps hitting C-c ' twice to
re-start editing is a reasonable workaround.

Eric Schulte eric.schu...@gmx.com writes:

 You can find the name of the original org-mode buffer by running the
 following snippet of elisp within the edit buffer.

 ;; -*- emacs-lisp -*-
 (marker-buffer org-edit-src-beg-marker)

 The `org-src-in-org-buffer' macro may be used from an edit buffer to run
 elisp inside the code block, in the org-mode buffer of the edit buffer.
 e.g., the following 

 ;; -*- emacs-lisp -*-
 (org-src-in-org-buffer (message --%S (org-babel-get-src-block-info)))

Where is org-src-in-org-buffer macro defined. Searching all dot el files
in org folder does not show anything neither does C-h f show anything
similar.

-- 
Mikhail



Re: [O] auto-push to mobile (but only when editing org buffer)

2012-08-16 Thread Ken Mankoff
Hi Marcel,

On Wed, Aug 15, 2012 at 12:33 AM, Marcel van der Boom mar...@hsdev.com wrote:
 Perhaps you will find https://gist.github.com/3111823 interesting. It
 contains a bit of code to do the org-mobile-push asynchronously (and
 notify me about it when done). This makes the push work in the
 background, in my case it can take quite a while, and not interfere
 with normal usage.


That is a very useful snippet. Thank you for sharing.

   -k.



[O] Load Custom Agenda at emacs launch

2012-08-16 Thread Ken Mankoff
Hi,

I find the first thing I do after launching emacs is to load my custom
agenda, bound to C-c a c.

Is there a way I can launch this from the command-line? I know I can
run 'emacs -eval (foo)', but I haven't been able to determine the
function that loads my custom agenda. Does such a function exist, or
is there a way to specific the keystrokes from the command line?

Thanks,

  -k.



Re: [O] Load Custom Agenda at emacs launch

2012-08-16 Thread Nick Dokos
Ken Mankoff mank...@gmail.com wrote:

 Hi,
 
 I find the first thing I do after launching emacs is to load my custom
 agenda, bound to C-c a c.
 
 Is there a way I can launch this from the command-line? I know I can
 run 'emacs -eval (foo)', but I haven't been able to determine the
 function that loads my custom agenda. Does such a function exist, or
 is there a way to specific the keystrokes from the command line?
 

Untested:

emacs --eval '(org-agenda nil c nil)'

or add

(org-agenda nil c nil)

at the bottom of your .emacs file.

Nick







Re: [O] How to use texi2dvi for export to LaTeX?

2012-08-16 Thread Marius Hofert
Thanks for helping, Achim and Nick, exactly what I was looking for. 

Cheers,

Marius



Re: [O] Load Custom Agenda at emacs launch

2012-08-16 Thread Eric Abrahamsen
On Fri, Aug 17 2012, Ken Mankoff wrote:

 Hi,

 I find the first thing I do after launching emacs is to load my custom
 agenda, bound to C-c a c.

 Is there a way I can launch this from the command-line? I know I can
 run 'emacs -eval (foo)', but I haven't been able to determine the
 function that loads my custom agenda. Does such a function exist, or
 is there a way to specific the keystrokes from the command line?

Hi Ken,

If you look at the docstring for `org-agenda', you'll see you can call
it with the prefix arg as the first argument, and the selector key as
the second. Assuming you don't need a prefix argument, this should work
for you:

(org-agenda nil c)

Put that at the bottom of your init file (or run it as an after-init
hook), and it will be the first thing you see when you start emacs.

-- 
GNU Emacs 24.1.50.1 (i686-pc-linux-gnu, GTK+ Version 2.24.11)
 of 2012-08-14 on pellet
7.8.11




[O] org-mobile and journaling

2012-08-16 Thread Richard Riley

I have a journal file defined in my capture templates like this

  (j journal entry (file+datetree
  journal.org)

Is there any way I can somehow get org-mobile to refile to this on
org-mobile-pull? Id like my captures to turn up in my agenda journal by
default.

Or failing that have refile refile from a standard refile.org to journal
in the correct datetree location? As it is if I refile from refile.org
to my journal.org it's not reformatted and placed correctly in the
datetree format : instead its placed as a top level item with the wrong
kind of date stamp to appear in the journal.

One problem as I see it is that captures on the iPhone only feature a
date and thats on the second line of the capture put into your refile
after the org pull. This doesnt have the necesary time granularity.

I'd be interested in a prvate email with anyone using org-mobile a lot
to share experiences and maybe hand hold a little.




Re: [O] Load Custom Agenda at emacs launch

2012-08-16 Thread Ken Mankoff
Hi Eric,

On Thu, Aug 16, 2012 at 3:50 PM, Eric Abrahamsen
e...@ericabrahamsen.net wrote:
 On Fri, Aug 17 2012, Ken Mankoff wrote:

 Hi,

 I find the first thing I do after launching emacs is to load my custom
 agenda, bound to C-c a c.

 Is there a way I can launch this from the command-line? I know I can
 run 'emacs -eval (foo)', but I haven't been able to determine the
 function that loads my custom agenda. Does such a function exist, or
 is there a way to specific the keystrokes from the command line?

 Hi Ken,

 If you look at the docstring for `org-agenda', you'll see you can call
 it with the prefix arg as the first argument, and the selector key as
 the second. Assuming you don't need a prefix argument, this should work
 for you:

 (org-agenda nil c)

 Put that at the bottom of your init file (or run it as an after-init
 hook), and it will be the first thing you see when you start emacs.


That works fairly well. I'm doing the CLI --eval version because I
often launch emacs w/o wanting to enter org mode. But I get a screen
with 90% org and 10% *scratch* buffer... Again, some searching and
trying to call the kill-buffer function, and I haven't figured it
out. Any hints on how to get full-terminal agenda mode? Sorry if these
are newbie questions.

   -k.



Re: [O] Load Custom Agenda at emacs launch

2012-08-16 Thread Nick Dokos
Ken Mankoff mank...@gmail.com wrote:

 Hi Eric,
 
 On Thu, Aug 16, 2012 at 3:50 PM, Eric Abrahamsen
 e...@ericabrahamsen.net wrote:
  On Fri, Aug 17 2012, Ken Mankoff wrote:
 
  Hi,
 
  I find the first thing I do after launching emacs is to load my custom
  agenda, bound to C-c a c.
 
  Is there a way I can launch this from the command-line? I know I can
  run 'emacs -eval (foo)', but I haven't been able to determine the
  function that loads my custom agenda. Does such a function exist, or
  is there a way to specific the keystrokes from the command line?
 
  Hi Ken,
 
  If you look at the docstring for `org-agenda', you'll see you can call
  it with the prefix arg as the first argument, and the selector key as
  the second. Assuming you don't need a prefix argument, this should work
  for you:
 
  (org-agenda nil c)
 
  Put that at the bottom of your init file (or run it as an after-init
  hook), and it will be the first thing you see when you start emacs.
 
 
 That works fairly well. I'm doing the CLI --eval version because I
 often launch emacs w/o wanting to enter org mode. But I get a screen
 with 90% org and 10% *scratch* buffer... Again, some searching and
 trying to call the kill-buffer function, and I haven't figured it
 out. Any hints on how to get full-terminal agenda mode? Sorry if these
 are newbie questions.
 

Try

emacs -q -l /path/to/minimal/org.el\
   --eval '(progn (setq org-agenda-window-setup (quote current-window)) 
(org-agenda nil c nil))'

Nick



[O] SageTeX in export

2012-08-16 Thread mailinglists
Hi,

Some background for the interested:

Sage (http://www.sagemath.org/) is a free open source mathematics
system. It essentially takes a number of well known open source math
packages (Pari/GP, Maxima, etc) and provides it all to you under one
interface, all glued together with Python. 

I highly recommend it. There was even a post here a few days ago
regarding including Sage into Org-Babel.

I want to talk about SageTeX. It's a package that allows you to call
Sage code from within your LaTeX document. You insert a Sage command
(e.g. plotting some data) and it returns the result - either an image or
relevant LaTeX code. Kind of like literate programming.

Here's how it works. If your document is file.tex and it uses the
SageTeX package, you run pdflatex on the .tex file. This will then
produce a sage script called file.sagetex.sage. You then manually run
this sage script using Sage. Then you run pdflatex again and it will
include the results from your sage script into the document.

I'm finding myself embedding Sage code into a document I'm writing which
is meant for a LaTeX export. My problem is that Org mode's LaTeX export
can't handle the steps in my previous paragraph. I'm sure it's trivial
to do via some hook, but I'm no good at Elisp.

All I need is a way for the export to:

1. After running pdflatex, check if there is a file called
   org_file_name.sagetex.sage.
2. If it's present, run sage on it, and then rerun pdflatex.
3. If it's not, nothing more is left to do.

I'd really appreciate if someone could tell me how to enable this with
Org mode's export.

Thanks!


 

 




Re: [O] Load Custom Agenda at emacs launch

2012-08-16 Thread Ken Mankoff
On Thu, Aug 16, 2012 at 8:25 PM, Nick Dokos nicholas.do...@hp.com wrote:

 Try

 emacs -q -l /path/to/minimal/org.el\
--eval '(progn (setq org-agenda-window-setup (quote current-window)) 
 (org-agenda nil c nil))'

 Nick

Works perfectly! Thank you.

  -k.