[O] [bug] in org-table.el: setq: Symbol's value as variable is void: repl

2014-07-30 Thread Thomas Holst
Hi list,

after a recent update I get the following error when I try to
recalculate formulas in a table:

  setq: Symbol's value as variable is void: repl

Searching for 'repl' in the lisp directory reveales only one hit in
org-table.el. repl was intoduced in commit:

  d4799eb * | org-table.el (org-table-eval-formula): Better error
  throwing

Reverting this commit fixed the problem for me. My lisp is not prfound
enough to provide a patch.

GNU Emacs 24.3.1 (i386-mingw-nt6.1.7601) of 2013-03-17 on MARVIN
Org-mode version 8.3beta (release_8.3beta-134-gcb51b4 @
   c:/daten/users/DE_hts2fe/git-emacs/org-mode/lisp/)
on Win7

Thanks for looking into this.
-- 
Bis neulich ...
  Thomas



[O] org-latex filters

2014-07-30 Thread Shiyuan
Hi,
I try to understand what the filter system is for and why the
transcoders itself doesn't suffice. So I take an example and want to see
how the filters are used in real exporter.  I look at ox-latex.el and try
to make sense of the filters

1. There are only two filters are used:

 :filters-alist '((:filter-options . org-latex-math-block-options-filter)
   (:filter-parse-tree . org-latex-math-block-tree-filter))

The purpose of org-latex-math-block-options-filter seems to be converting
whatever in the property list of :author, :date, :title  to strings of
latex commands(please correct me if I am wrong).  But what is the purpose
of org-latex-math-block-tree-filter? The org-latex--wrap-latex-math-block
is quite sophisticate and I don't get what it's doing.

-
(defun org-latex-math-block-options-filter (info backend)
  (dolist (prop '(:author :date :title) info)
(plist-put info prop
   (org-latex--wrap-latex-math-block (plist-get info prop) info

(defun org-latex-math-block-tree-filter (tree backend info)
  (org-latex--wrap-latex-math-block tree info))


2. For the filters of the form :filter-TYPE, there is also a transcoder for
processing the same TYPE. For example, for bold, there are :filter-bold,
but bold is also processed in the transcoder specified in the transcoder
alist when the backend is defined(by org-export-define-backend). When shall
we use a transcode and when shall we use a filter?

Thank you.

Shiyuan


Re: [O] Regex Speedup for org-refresh-category-properties.

2014-07-30 Thread Achim Gratz
Malcolm Purvis malcolm at purvis.id.au writes:
 Thanks.  Things are just as fast with this regexp.

Thanks for the confirmation.



Regards,
Achim.





Re: [O] Setup Org-mode to write diary.

2014-07-30 Thread numbch...@gmail.com
This org-capture looks a way, I want to try it.
But need a more advanced way, because a single file for write diary is
really not a good idea. I will be slow. (I think)
Maybe add a logic in the org-capture template.

I'm trying this way.

[stardiviner]   Hack this world!  GPG key ID: 47C32433
IRC(freeenode): stardiviner Twitter:  @numbchild
Key fingerprint = 9BAA 92BC CDDD B9EF 3B36  CB99 B8C4 B8E5 47C3 2433
Blog: http://nagatopain-blog.logdown.com/


On Mon, Jul 28, 2014 at 4:53 PM, Charles Philip Chan cpc...@bell.net
wrote:

 stardiviner numbch...@gmail.com writes:

  I want to know how to configure Org-mode to write diary with a easy way.
  I hope someone can provide his way.
 
  Here is what I think what Org-mode write diary should have.
 
  - [ ] *open/create* a buffer to write current day's diary quickly.

 Set up a capture template using a date tree. For example, this is taken
 directly from section 9.1.3 of the org-mode manual:

 ,
 | (j Journal entry (file+datetree ~/org/journal.org)
 |  * %?\nEntered on %U\n  %i\n  %a)
 `

  - [ ] *navigate* diary entry like viewing day entries in Calendar.

 Use the imenu menu or just fold and unfold the outline.

  - [ ] *manage* diary files with some kind of style like (date, folder,
  etc).  - [ ] *search* diary content.

 Add the file to the variable org-agenda-text-search-extra-files and/or
 set up a custom agenda view to search the file.

 Charles

 --
 ...Deep Hack Mode--that mysterious and frightening state of
 consciousness where Mortal Users fear to tread.
 (By Matt Welsh)



Re: [O] [bug] in org-table.el: setq: Symbol's value as variable is void: repl

2014-07-30 Thread Bastien
Hi Thomas,

Thomas Holst thomas.ho...@de.bosch.com writes:

 after a recent update I get the following error when I try to
 recalculate formulas in a table:

   setq: Symbol's value as variable is void: repl

This was a code typo I made, it is now fixed, please pull again
and test.

-- 
 Bastien



Re: [O] broken links in org-html publishing

2014-07-30 Thread Bastien
Hi Matt,

Matt Lundin m...@imapmail.org writes:

 The attached patch fixes the issue.

Applied, thanks,

-- 
 Bastien



[O] Release Org 8.2.7c

2014-07-30 Thread Bastien
Hi all,

I released Org 8.2.7c.

  http://orgmode.org/org-8.2.7c.tar.gz
  http://orgmode.org/org-8.2.7c.zip

Thanks to you all for contributing to this bugfix release!

I will be off for three weeks now.

-- 
 Bastien




[O] org-table Row Count Formula

2014-07-30 Thread Esben Stien
I'm trying to figure out how to get the number of rows in an org-table,
but I can't find this in the documentation. 

Anyone have an idea?

-- 
Esben Stien is b0ef@e s  a 
 http://www. s tn m
  irc://irc.  b  -  i  .   e/%23contact
   sip:b0ef@   e e 
   jid:b0ef@n n



Re: [O] org-table Row Count Formula

2014-07-30 Thread Eric Abrahamsen
Esben Stien b...@esben-stien.name writes:

 I'm trying to figure out how to get the number of rows in an org-table,
 but I can't find this in the documentation. 

 Anyone have an idea?

The vcount function will count the number of elements in a vector, so
you could probably pass a range reference, like @1..@ (first row to
last row) to vcount. I think empty rows would be omitted, though.




Re: [O] org-table Row Count Formula

2014-07-30 Thread Thorsten Jolitz
Esben Stien b...@esben-stien.name writes:

 I'm trying to figure out how to get the number of rows in an org-table,
 but I can't find this in the documentation. 

 Anyone have an idea?

As always, there might be some Org function for this, but otherwise here
is a starting point:

#+begin_src emacs-lisp
  (defun tj/count-tbl-rows (optional tbl-as-lisp)
Return number of tbl rows for tbl at point.
(interactive)
(let ((rows (if tbl-as-lisp
(length tbl-as-lisp)
  (length (org-table-to-lisp)
  (message Table has %d Rows rows)
  rows))
#+end_src

#+results:
: tj/count-tbl-rows

#+NAME: nice-tbl
| pretty | impressive | table |
| pretty | impressive | table |
| pretty | impressive | table |
| pretty | impressive | table |
| pretty | impressive | table |
| pretty | impressive | table |

#+header: :var data=nice-tbl
#+begin_src emacs-lisp 
(tj/count-tbl-rows data)
#+end_src

#+results:
: 6

-- 
cheers,
Thorsten




Re: [O] [RFC] Add commmand for wrapping sexp/region in src-blocks to Org?

2014-07-30 Thread Alan Schmitt
Hi Thorsten,

On 2014-07-29 17:36, Thorsten Jolitz tjol...@gmail.com writes:

 I often missed the following command for wrapping existing content into
 src-blocks in the past, besides knowing about
 `org-babel-demarcate-block' and easy template insertion. Would it make
 sense to add it to Org-mode?

I find this most useful and have added it in my configuration. It would
make sense to add it to org-mode.

Thanks,

Alan

-- 
OpenPGP Key ID : 040D0A3B4ED2E5C7


pgpEIGf6qrEVe.pgp
Description: PGP signature


Re: [O] remapping C-c ' to another key

2014-07-30 Thread Alan Schmitt
On 2014-07-29 19:23, Thorsten Jolitz tjol...@gmail.com writes:

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

 Hello,

 I'm trying to remap ~C-c '~ to ~menu '~ and I'm having some
 trouble. More specifically, I'm able to initiate the editing part using
 a global binding to `org-edit-special', but I don't know how to bind the
 same key to `org-edit-src-exit' when I'm editing a source block. As
 I suspect I will also need to change the binding for other special edit
 buffers, I'm wondering if there is a way to do it all at once.

 you are in org-mode when you call `org-edit-special', thus you could do

 ,
 | (org-defkey org-mode-map KEY `org-edit-special)
 `


 then you are in some major-mode with minor-mode 'org-src-mode' active,
 thus

 ,
 | (org-defkey org-src-mode-map KEY `org-edit-src-exit)
 `

 should work (completely untested though ...)

It works great, thanks a lot.

A followup question: why use ` and not ' before the function name?

Alan

-- 
OpenPGP Key ID : 040D0A3B4ED2E5C7


pgpiZ9klVS0qT.pgp
Description: PGP signature


Re: [O] remapping C-c ' to another key

2014-07-30 Thread Thorsten Jolitz
Alan Schmitt alan.schm...@polytechnique.org writes:

Hi Alan, 

 On 2014-07-29 19:23, Thorsten Jolitz tjol...@gmail.com writes:

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

 Hello,

 I'm trying to remap ~C-c '~ to ~menu '~ and I'm having some
 trouble. More specifically, I'm able to initiate the editing part using
 a global binding to `org-edit-special', but I don't know how to bind the
 same key to `org-edit-src-exit' when I'm editing a source block. As
 I suspect I will also need to change the binding for other special edit
 buffers, I'm wondering if there is a way to do it all at once.

 you are in org-mode when you call `org-edit-special', thus you could do

 ,
 | (org-defkey org-mode-map KEY `org-edit-special)
 `


 then you are in some major-mode with minor-mode 'org-src-mode' active,
 thus

 ,
 | (org-defkey org-src-mode-map KEY `org-edit-src-exit)
 `

 should work (completely untested though ...)

 It works great, thanks a lot.

 A followup question: why use ` and not ' before the function name?

Should be a normal quote ', this is just a typo!
Although it does not hurt in this case, but anyway ...

-- 
cheers,
Thorsten




Re: [O] What happened to clocktable in pdf export?

2014-07-30 Thread Buddy Butterfly

Hi Nicolas,

updated via elpa and got the nice table back again in pdf.
Also in ASCII and HTML export it is nicely indented now.

A drawback, though is that the \_ in the emacs editing is now
gone! The lines now look like

\emsp\emsp\emsp Task2

Which is also not very nice. The editing style \_ was quite nice,
though, not for export. Is there a way to make the \emsp invisible
within Emacs?

Also, any Idea how to get the column separator lines also in ASCII export?
PDF works because of the extra header line. HTML and ASCII I do not know.

Cheers,
Matt



Am 25.07.2014 um 13:16 schrieb Nicolas Goaziou:
 Buddy Butterfly buddy.butter...@web.de writes:

 How can I easily fix it in my Ubuntu dist? I am running the standard
 repo version from Ubuntu 14.04. Any .el or something like that?
 Since it is fixed in maint, you can update Org from ELPA. It will be
 updated in a few hours.

 Just a small one. As now the line for the clocktable becomes longer,
 is there a method to break up the clocktable header into multiple
 lines?
 Not yet, but ultimately :header property should probably be moved
 to #+HEADER: keyword above the dynamic block, much like source blocks:

   #+header: #+attr_latex: :align l|r|r|r :environment longtable
   #+header: :fontsize \footnotesize
   #+BEGIN: clocktable :maxlevel 7 :scope tree3 :indent t
   ...

 Though, there's no standard syntax to include a newline there, e.g.,

   #+header: #+attr_latex: :align l|r|r|r :environment longtable
   #+header: :fontsize \footnotesize\n#+caption: Some caption
   #+BEGIN: clocktable :maxlevel 7 :scope tree3 :indent t
   ...


 Regards,





[O] tikz and html

2014-07-30 Thread Joseph Vidal-Rosset
Hello,

Exporting images created with tikz to html.files seems a complicated task.

This file is corrected exported into pdf:

#+OPTIONS: LaTeX:verbatim
#+OPTIONS:  tex:imagemagick
#+LaTeX_CLASS: article
#+LaTeX_CLASS_OPTIONS: [koma,a4paper,11pt]
#+LaTeX_CLASS_OPTIONS: [times]
#+LaTeX_HEADER: \usepackage{tikz}
#+LANGUAGE: en
#+OPTIONS: ':t
#+OPTIONS: tex:t


* Tikz test
Here's a tree, exported to both html and pdf.

#+begin_src latex
  \usetikzlibrary{trees}
  \begin{tikzpicture}
\node [circle, draw, fill=red!20] at (0,0) {1}
child { node [circle, draw, fill=blue!30] {2}
  child { node [circle, draw, fill=green!30] {3} }
  child { node [circle, draw, fill=yellow!30] {4} }};
  \end{tikzpicture}
#+end_src

But I do not succeed to export it into a html file.

Your help is welcome.

Best wishes

Jo.


Re: [O] [bug] in org-table.el: setq: Symbol's value as variable is void: repl

2014-07-30 Thread Thomas Holst
Hi Bastien,

 Thomas Holst thomas.ho...@de.bosch.com writes:
 
 after a recent update I get the following error when I try to
 recalculate formulas in a table:

   setq: Symbol's value as variable is void: repl
 
 This was a code typo I made, it is now fixed, please pull again
 and test.

after a pull right now everything works as expected. Thanks for the
quick fix.

-- 
Bis neulich ...
  Thomas



[O] allow multiline #+BIND

2014-07-30 Thread Vladimir Alexiev
It would be nice to allow multiline BINDs. I'd much rather write this than put 
it all on one line:

#+BIND: va/org-dot-preamble digraph g {
#+BIND:   rankdir=LR nodesep=0.2 ranksep=0.1 arrowsize=0.2
#+BIND:   node [fontname=courier fontsize=8 margin='0.02,0.01' shape=circle 
width=0.1 height=0.1 label='']
#+BIND:   edge [fontname=courier fontsize=8 labelfontname=courier 
labelfontsize=8]

The usual continuation syntax of backslash before the EOL can be used.
Or else, a new keyword #+BIND1: for each continuation line.

The function to fix is ox.el::org-export--list-bound-variables




Re: [O] tikz and html

2014-07-30 Thread Nicolas Berthier
You wrote:

 Hello,

 Exporting images created with tikz to html.files seems a complicated
 task.

 This file is corrected exported into pdf:

 #+OPTIONS: LaTeX:verbatim
 #+OPTIONS:  tex:imagemagick
 #+LaTeX_CLASS: article
 #+LaTeX_CLASS_OPTIONS: [koma,a4paper,11pt]
 #+LaTeX_CLASS_OPTIONS: [times]
 #+LaTeX_HEADER: \usepackage{tikz}
 #+LANGUAGE: en
 #+OPTIONS: ':t
 #+OPTIONS: tex:t


 * Tikz test
 Here's a tree, exported to both html and pdf.

 #+begin_src latex
   \usetikzlibrary{trees}
   \begin{tikzpicture}
     \node [circle, draw, fill=red!20] at (0,0) {1}
     child { node [circle, draw, fill=blue!30] {2}
   child { node [circle, draw, fill=green!30] {3} }
   child { node [circle, draw, fill=yellow!30] {4} }};
   \end{tikzpicture}
 #+end_src

 But I do not succeed to export it into a html file.

 Your help is welcome.

Hello,

You can see this answer on stackoverflow[fn:1].

Regards,

[fn:1] http://stackoverflow.com/a/24452992/1524082

-- 
Nicolas BerthierFSF Member #7975



Re: [O] tikz and html

2014-07-30 Thread Joseph Vidal-Rosset
2014-07-30 13:44 GMT+02:00 Nicolas Berthier nbe...@member.fsf.org:

 Hello,

 You can see this answer on stackoverflow[fn:1].

 Regards,

 [fn:1] http://stackoverflow.com/a/24452992/1524082



Many thanks for this reference. It works  !

Jo.


Re: [O] Installing Org 8

2014-07-30 Thread SabreWolfy
I've wasted an entire day trying to upgrade to Org 8 under OS X :(

I'm using a modified version of Emacs, with ESS pre-installed. I've also
downloaded the latest 24.3.1 Emacs for OS X and tried with that.

In both cases, I am able to install Org 8 (20140730 now) via ELPA. It
installs to a local directory. However, when I restart Emacs and enter
'org-version', I am shown:

Org-mode version 7.9.3f (release_7.9.3f-17-g7524ef @
/Users/macbookair/.emacs.d/elpa/org-20140730/)

It looks like the pre-installed version is taking precedence, but it is
showing the folder of the new version.

I tried deleting the pre-installed version of Org from the /Applications/...
folder, but then Emacs generates an error on start-up about not being able
to locate the org-latex file.

I did manage to install both the latest Org and ESS into the latest Emacs
24.3.1, but then Emacs was not able to open Bazaar VC files -- it could not
find the 'bzr' file (Bazaar is, of course, installed; the ESS-modified Emacs
can open Bazaar VC files).

As it stands now, I'm back to using the ESS-modified version of Emacs (as it
has ESS and bzr working) and have Org 8 installed via ELPA, but not working.

*Sigh*




Re: [O] Installing Org 8

2014-07-30 Thread Jorge A. Alfaro-Murillo
Try putting (package-initialize) as the first line of your .emacs, 
that should do the trick. 


Best,

Jorge.




Re: [O] Bug: [PATCH] Make org-narrow-to-subtree usable out of Org mode [8.2.7b (release_8.2.7b-6-g07d470 @ /home/youngfrog/sourcetrees/org-mode/lisp/)]

2014-07-30 Thread Nicolas Richard
Hello Bastien,

Bastien b...@gnu.org writes:
 I think it's fine to bind `org-narrow-to-subtree' in narrow-map.
 It's basically to enjoy the `C-x n prefix', which is natural here.

I agree, but it is not compatible with keeping it only for org-mode
buffers while using something else for some other modes, which is what
you suggest next :

 I applied your patch, but a good continuation would be to have
 C-h n s bound to `outline-narrow-to-subtree' in outline-mode and
 to `org-narrow-to-subtree' in org-mode, instead of just relying
 on one single function.

 This requires simplifying `org-narrow-to-subtree' and creating
 `outline-narrow-to-subtree' in emacs.

 What do you think?

I think backporting narrow-to-subtree to outline is a very good move.
(Other things would be cool in outline, e.g. why does it not have
outline-cycle ? But that's a longer story, I guess.)

Another possibility : wouldn't it make sense to hijack narrow-to-defun
for this ? In fact, it used to be that way, but then it was changed in
76fa979225a2a31f7be6d366c48750d4f7abe458 (and then reverted, and then
the revert was reverted, and I have no idea why).

Looking more closely, the current behaviour is partly buggy, e.g. with a
file like :

* one
** two
** three
* four

When point is on the second line and C-M-e is used, we end up on the
first line ! I see two reasons for this or similar failures :
- One is a bug in org-forward-heading-same-level (I provide a patch
below).
- The other is because org-backward-element doesn't fully satisfy the
beginning-of-defun usual protocol since it sometimes signals an error.

Here's a test for catching the bug in org-forward-heading-same-level:
(org-test-with-temp-text \
* one
* two

   (goto-line 2)
   (org-forward-heading-same-level -1)
   (should (bobp)))

And here's the patch for org-forward-heading-same-level.

Modified   lisp/org.el
diff --git a/lisp/org.el b/lisp/org.el
index 0e15710..741c9b5 100644
--- a/lisp/org.el
+++ b/lisp/org.el
@@ -23328,9 +2,10 @@ non-nil it will also look at invisible ones.
're-search-forward))
   (count (if arg (abs arg) 1))
   (result (point)))
-  (while (and (prog1 ( count 0)
-   (forward-char (if (and arg ( arg 0)) -1 1)))
-  (funcall f org-outline-regexp-bol nil 'move))
+  (while (and ( count 0)
+ (progn
+   (forward-char (if (and arg ( arg 0)) -1 1))
+   (funcall f org-outline-regexp-bol nil 'move)))
 (let ((l (- (match-end 0) (match-beginning 0) 1)))
   (cond (( l level) (setq count 0))
 ((and (= l level)

Want a git-format-patch one ?

Also, here's a test where I don't know what should happen (currently
signals a user-error) :

(org-test-with-temp-text \
one
* two

   (goto-line 2)
   (org-backward-element)
   (should t))


-- 
Nico.



Re: [O] Bug: [PATCH] Make org-narrow-to-subtree usable out of Org mode [8.2.7b (release_8.2.7b-6-g07d470 @ /home/youngfrog/sourcetrees/org-mode/lisp/)]

2014-07-30 Thread Thorsten Jolitz
Nicolas Richard theonewiththeevill...@yahoo.fr writes:

 I think backporting narrow-to-subtree to outline is a very good move.
 (Other things would be cool in outline, e.g. why does it not have
 outline-cycle ? But that's a longer story, I guess.)

It does via outline-magic.el (now maintained by me:
https://github.com/tj64/outline-magic), and the short story is (my
interpretation!) that outline-magic.el was the first step of Carsten
Dominik towards Org-mode, thus it adds many org-style features to
outline-mode. He later abandoned it in favor of Org-mode and asked me to
take over maintainance when I showed interest in it.

It is fully integrated (and partly improved and expanded) in outshine.el
now, so if you want Org-like behaviour for outline-(minor)-mode you
should really use outshine rather than outline-magic.

 outline with outshine outshines outline 

-- 
cheers,
Thorsten




[O] Where is the git master branch?

2014-07-30 Thread Sharon Kimble

If git clone git://orgmode.org/org-mode.git gets the development
branch of org-mode, what is the git command to get the master branch
please? I've been looking on http://orgmode.org/ but can't see any
reference for it.

Thanks
Sharon.
-- 
A taste of linux = http://www.sharons.org.uk
my git repo = https://bitbucket.org/boudiccas/dots
TGmeds = http://www.tgmeds.org.uk
Debian testing, fluxbox 1.3.5, emacs 24.3.92.1


signature.asc
Description: PGP signature


Re: [O] Bug: [PATCH] Make org-narrow-to-subtree usable out of Org mode [8.2.7b (release_8.2.7b-6-g07d470 @ /home/youngfrog/sourcetrees/org-mode/lisp/)]

2014-07-30 Thread Nicolas Richard
Thorsten Jolitz tjol...@gmail.com writes:

 Nicolas Richard theonewiththeevill...@yahoo.fr writes:

 I think backporting narrow-to-subtree to outline is a very good move.
 (Other things would be cool in outline, e.g. why does it not have
 outline-cycle ? But that's a longer story, I guess.)

 It does via outline-magic.el (now maintained by me:
 https://github.com/tj64/outline-magic), and the short story is (my

 It is fully integrated (and partly improved and expanded) in outshine.el

Thanks for the URL. The description looks great but why not patch
outline.el instead of making it an external library ? Is there an
incompatibility ?

-- 
Nico.



Re: [O] Where is the git master branch?

2014-07-30 Thread Nicolas Richard
Sharon Kimble boudic...@skimble.plus.com writes:
 If git clone git://orgmode.org/org-mode.git gets the development
 branch of org-mode, what is the git command to get the master branch
 please? I've been looking on http://orgmode.org/ but can't see any
 reference for it.

The 'master' branch is the development/unstable branch. The stable
branch is called 'maint'.

-- 
Nico.



Re: [O] bug in lisp code blocks

2014-07-30 Thread Mark Scala
Thanks, Bastien, for helping me report this bug more effectively.
This email summarizes all the information I have about this bug and
how to reproduce it. The problem is that a comment which appears as
the _last_ line of a (common) lisp code block causes an error when
that block is evaluated with C-c C-c. Here's how to reproduce it:

1. You will need to have SBCL and Slime
   installed. Your distribution of linux probably has a good enough
   SBCL (I'm using 1.2.0 in Arch linux). The easiest way to get the
   latest version of Slime is with Quicklisp, which you can find here
   (together with instructions to install):
   http://www.quicklisp.org/beta/.

   Once you have Quicklisp installed and loaded, installing Slime is a
   matter of calling (ql:quickload swank) at the sbcl repl.

  Note: I am also able to reproduce the bug using clisp:
-  GNU CLISP 2.49 (2010-07-07) (built on
var-lib-archbuild-extra-x86_64-barthalion)

2. Start emacs with the following as the entire init.el (of course,
   you'll probably have to modify the paths).

#+BEGIN_SRC emacs-lisp

(add-to-list 'load-path (expand-file-name ~/opt/org-mode/lisp))
(require
'org)

(org-babel-do-load-languages

  'org-babel-load-languages

  '((lisp . t)))

  (setq inferior-lisp-program /usr/bin/sbcl)

(add-to-list 'load-path
~/quicklisp/dists/quicklisp/software/slime-2.8)
  (require 'slime)
#+END_SRC
Note: I've also just reproduced the bug using the version of org-mode
that ships with Emacs 24:

   - Org-mode version 7.9.3f (release_7.9.3f-17-g7524ef @
/usr/share/emacs/24.3/lisp/org/)

3. Finally, create a new org file and insert this block:

#+BEGIN_SRC lisp :results output

(format t Hello world.)
  ;; comment after, causes crash when block is evaluated with C-c C-c
#+END_SRC

If you now evaluate the block with C-c C-c, you should get an EOF
error. Here is a piece of the debugger report:

#+BEGIN_QUOTE
end of file on #SB-IMPL::STRING-INPUT-STREAM {1003F862D3}
   [Condition of type END-OF-FILE]
#+END_QUOTE
It appears that the bug is caused by a comment string that is the last
element of the block. Comments elsewhere do not cause this error.

Here are the versions strings of the software I'm running:

  - GNU Emacs 24.3.1 (x86_64-unknown-linux-gnu, GTK+ Version 3.12.2)
of 2014-06-11 on var-lib-archbuild-staging-x86_64-jgc
  - Org-mode version 8.3beta (release_8.3beta-51-g02f2d5 @
/home/mark/opt/org-mode/lisp/)
  - SBCL 1.2.0

On Tue, Jul 29, 2014 at 9:13 AM, Bastien b...@gnu.org wrote:
 Hi Mark,

 you forgot to CC the list -- please do so, so that anyone can help
 fixing the problem.

 All this new information is important.  A complete recipe would take
 the user from a bare emacs -Q to an emacs with a sbcl connection and
 slime, and explain the steps for launching sbcl, connecting via slime,
 etc.

 Assume the ones who may fix the problem (like me and other maintainers)
 are not 100% familiar with Emacs/slime/sbcl, even though they can follow
 good recipes easily.

 Thanks for your efforts!

 PS: The hint about the last commented line triggered the bug is
 important and will certainly lead to a quick fix.

 --
  Bastien



Re: [O] [babel][PATCHES] exporting inline source code

2014-07-30 Thread Nicolas Berthier
You wrote:

 Hi Nicolas,

 Nicolas Berthier nbe...@member.fsf.org writes:

 I will investigate on this ASAP, and notice you when I receive
 a confirmation that the FSF signed it.

 Thanks, we should expect longer delays during the summer I guess.

Hi,

I received the confirmation form the FSF today (should I forward it to
some of you?).

In any case, as advised earlier in the discussion, I updated one patch
to integrate new tests for the new feature. I also slightly simplified
the HTML export patch to avoid useless display attributes.

From 00fc0209ba50587075e4cf271d1b9a3612574562 Mon Sep 17 00:00:00 2001
From: Nicolas Berthier nbe...@member.fsf.org
Date: Fri, 13 Jun 2014 15:32:54 +0200
Subject: [PATCH 1/2] ob: Support for exporting inline source code

* lisp/ob-exp.el (org-babel-exp-inline-code-template): New
customizable variable to export inline source code (similar to
`org-babel-exp-code-template').
(org-babel-exp-code): New `type' argument to differentiate between
inline and standard code blocks.

* lisp/ob-core.el (org-babel-inline-src-block-regexp): Allow empty set
of switches and header arguments as in src_sh[]{echo foo;}.

* testing/lisp/test-ob-exp.el (ob-exp/exports-inline-code): New
function for testing inline source code handling.

* testing/lisp/test-ob.el
(test-org-babel/org-babel-get-inline-src-block-matches): Test for
inline source blocks with empty header arguments.

* testing/examples/babel.org: New sections for testing (i) exported
inline source code (used by `ob-exp/exports-inline-code'); (ii)
parsing inline source blocks with empty header arguments (used by
`test-org-babel/org-babel-get-inline-src-block-matches').

Until now pieces of inline source code were handled as standard code
blocks during export.  These changes enable them to be exported.
---
 lisp/ob-core.el |  2 +-
 lisp/ob-exp.el  | 30 ---
 testing/examples/babel.org  | 22 ++
 testing/lisp/test-ob-exp.el | 14 +
 testing/lisp/test-ob.el | 71 ++---
 5 files changed, 104 insertions(+), 35 deletions(-)

diff --git a/lisp/ob-core.el b/lisp/ob-core.el
index ccc0878..08d4c65 100644
--- a/lisp/ob-core.el
+++ b/lisp/ob-core.el
@@ -203,7 +203,7 @@ This string must include a \%s\ which will be replaced by the results.
 (defvar org-babel-inline-src-block-regexp
   (concat
;; (1) replacement target (2) lang
-   \\(?:^\\|[^-[:alnum:]]\\)\\(src_\\([^ \f\t\n\r\v]+\\)
+   \\(?:^\\|[^-[:alnum:]]\\)\\(src_\\([^ \f\t\n\r\v\\[]+\\)
;; (3,4) (unused, headers)
\\(\\|\\[\\(.*?\\)\\]\\)
;; (5) body
diff --git a/lisp/ob-exp.el b/lisp/ob-exp.el
index 3a47661..37625ab 100644
--- a/lisp/ob-exp.el
+++ b/lisp/ob-exp.el
@@ -318,10 +318,10 @@ The function respects the value of the :exports header argument.
 	(clean (lambda () (unless (eq type 'inline) (org-babel-remove-result info)
 (case (intern (or (cdr (assoc :exports (nth 2 info))) code))
   ('none (funcall silently) (funcall clean) )
-  ('code (funcall silently) (funcall clean) (org-babel-exp-code info))
+  ('code (funcall silently) (funcall clean) (org-babel-exp-code info type))
   ('results (org-babel-exp-results info type nil hash) )
   ('both (org-babel-exp-results info type nil hash)
-	 (org-babel-exp-code info)
+	 (org-babel-exp-code info type)
 
 (defcustom org-babel-exp-code-template
   #+BEGIN_SRC %lang%switches%flags\n%body\n#+END_SRC
@@ -343,7 +343,27 @@ replaced with its value.
   :group 'org-babel
   :type 'string)
 
-(defun org-babel-exp-code (info)
+(defcustom org-babel-exp-inline-code-template
+  src_%lang[%switches%flags]{%body}
+  Template used to export the body of inline code blocks.
+This template may be customized to include additional information
+such as the code block name, or the values of particular header
+arguments.  The template is filled out using `org-fill-template',
+and the following %keys may be used.
+
+ lang -- the language of the code block
+ name -- the name of the code block
+ body -- the body of the code block
+ switches -- the switches associated to the code block
+ flags - the flags passed to the code block
+
+In addition to the keys mentioned above, every header argument
+defined for the code block may be used as a key and will be
+replaced with its value.
+  :group 'org-babel
+  :type 'string)
+
+(defun org-babel-exp-code (info type)
   Return the original code block formatted for export.
   (setf (nth 1 info)
 	(if (string= strip-export (cdr (assoc :noweb (nth 2 info
@@ -354,7 +374,9 @@ replaced with its value.
 	   info org-babel-exp-reference-buffer)
 	(nth 1 info
   (org-fill-template
-   org-babel-exp-code-template
+   (if (eq type 'inline)
+   org-babel-exp-inline-code-template 
+   org-babel-exp-code-template)
`((lang  . ,(nth 0 info))
  (body  . ,(org-escape-code-in-string (nth 1 info)))
  (switches . ,(let ((f (nth 3 info)))
diff --git 

Re: [O] org-element - canonical way to parse only headline at point?

2014-07-30 Thread Nicolas Goaziou
Hello,

Thorsten Jolitz tjol...@gmail.com writes:

 with the new parser, how do I parse only the headline at point?  There
 are ARGS in the parser/mapper functions that restrict parsing, but I
 suspect that still the whole buffer is parsed for the genealogy - right?

 With my current knowledge I would either narrow the buffer to the subtree at
 point or copy this subtree to a temp-buffer before parsing/mapping it,
 but maybe there is a better way?

 Would this be a valid template (a simple and fast solution)?

 #+begin_src emacs-lisp
   (save-restriction
(org-narrow-to-subtree
 (org-element-map (org-element-parse-buffer 'headline t) 'headline
   (lambda () ...)
   nil t t)))
 #+end_src

What about (org-element-at-point) ?


Regards,

-- 
Nicolas Goaziou



Re: [O] Bug: [PATCH] Make org-narrow-to-subtree usable out of Org mode [8.2.7b (release_8.2.7b-6-g07d470 @ /home/youngfrog/sourcetrees/org-mode/lisp/)]

2014-07-30 Thread Thorsten Jolitz
Nicolas Richard theonewiththeevill...@yahoo.fr writes:

 Thorsten Jolitz tjol...@gmail.com writes:

 Nicolas Richard theonewiththeevill...@yahoo.fr writes:

 I think backporting narrow-to-subtree to outline is a very good move.
 (Other things would be cool in outline, e.g. why does it not have
 outline-cycle ? But that's a longer story, I guess.)

 It does via outline-magic.el (now maintained by me:
 https://github.com/tj64/outline-magic), and the short story is (my

 It is fully integrated (and partly improved and expanded) in outshine.el

 Thanks for the URL. The description looks great but why not patch
 outline.el instead of making it an external library ? Is there an
 incompatibility ?

Well, outshine merges quite old extension libraries for outline like
outline-magic (Carsten Dominik) and out-xtra (Per Abrahamsen) and adds
lots of new stuff. Why did the old guys back then wrote extensions
instead of patching outline? No idea ... 

Outshine was never meant to replace outline, and there is a conceptual
incompability. Outshine trys to bring Org-mode's lookfeel to
programming major-modes, meaning that headlines are outcommented
Org headlines, e.g.

,
| ;; ** 2nd Level
`

But pure outline users tend to fold whatever they want, e.g. function defs
in elisp etc., and thats too much of a conceptual mismatch to merge it
in one library. 

Outshine users should structure their source-files just like Org files,
only with outcommented headlines, then many things will work just like
in Org-mode. Additional folding features could be added like in Org-mode
(plain list, src-blocks etc), but the Org-headline as core structural
element is mandatory in both Org-mode and Outshine.

Thus outshine is one option for outline users, but not the only
one. They can still use plain old outline and define whatever they want
as outline-regexp.

But, btw, navi-mode gives you that too, so its possible to have the best
of both worlds:

E.g, after doing 'M-s n' (M-x navi-search-and-switch) in outshine.el, 

doing 'f' in the *Navi* buffer gives:

,
| 194 matches for ^[[:space:]]*(def[maus][^elt][a-z]*\*?  in buffer: 
outshine.el
| 344:(defun outshine-compatible-face (inherits specs)
| 695:(defmacro outshine-define-key-with-fallback
| 734:(defun outshine-chomp (str)
| 744:(defun outshine-set-outline-regexp-base ()
| 757:(defun outshine-normalize-regexps ()
| 772:(defun outshine-modern-header-style-in-elisp-p (optional buffer)
| 785:(defun outshine-calc-comment-region-starter ()
| 795:(defun outshine-calc-comment-padding ()
| 811:(defun outshine-calc-outline-regexp ()
| 834:(defun outshine-calc-outline-level ()
| 871:(defun outshine-set-local-outline-regexp-and-level
| 888:(defun outshine-write-hidden-lines-cookies ()
| 902:(defun outshine-hidden-lines-cookie-status-changed-p ()
| 912:(defun outshine-set-hidden-lines-cookie ()
| 949:(defun outshine-calc-outline-string-at-level (level)
| 961:(defun outshine-calc-outline-base-string-at-level (level)
| 968:(defun outshine-transform-normalized-outline-regexp-base-to-string ()
| 976:(defun outshine-make-promotion-headings-list (max-level)
| 990:(defun outshine-fontify-headlines (outline-regexp) ...
`

doing 'v' gives

,
| 55 matches for ^[[:space:]]*(def[vcgf][^l][a-z]+  in buffer: outshine.el
| 150:(defconst outshine-version 1.0
| 153:(defconst outshine-max-level 8
| 157:(defconst outshine-level-faces
| 162:(defconst outshine-outline-heading-end-regexp \n
| 167:(defconst outshine-oldschool-elisp-outline-regexp-base
| 171:(defconst outshine-speed-commands-default
| 249:(defconst outshine-comment-tag comment
| 256:(defvar outline-minor-mode-prefix \M-#
| 264:(defvar outline-promotion-headings nil
| 273:(defvar outshine-delete-leading-whitespace-from-outline-regexp-base-p 
nil
| 278:(defvar outshine-enforce-no-comment-padding-p nil
| 283:(defvar outshine-outline-regexp-base 
| 286:(defvar outshine-normalized-comment-start  ...
`

etc etc, here is the key-word search help for Emacs Lisp:

,
| [KEY] : [SEARCH]
| 
|   a : ALL
|   f : FUN
|   v : VAR
|   x : OBJ
|   b : DB
|   F : defun
|   V : defvar
|   C : defconst
|   G : defgroup
|   U : defcustom
|   A : defadvice
|   W : defalias
|   M : defmarcro
|   D : defface
|   S : defstruct
|   B : defsubst
|   L : defclass
|   I : define
|   J : declare
|   K : global-set-key
|   T : add-to-list
|   Q : setq
|   H : add-hook
| 

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

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

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

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

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

Best,
Ista

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

 some comments on the code below.

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

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

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

 ;; This file is not part of GNU Emacs.

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

 ;; Stata and ESS are required.

 Maybe add some links for the requirements.

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

 This needs to be 8.3

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

 Maybe simply remove this, or make it more readable.

 Thanks in advance for this contribution!

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

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


;; This file is not part of GNU Emacs.

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

;;; Commentary:

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

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

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

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

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

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

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

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

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

[O] [POLL] Syntax change: make \[...\] non-inline (+1)

2014-07-30 Thread Federico Beffa
Who is entitled to vote? If I am then here is my vote in favor for the
following reasons:

1. the construct \[...\] has been defined in LaTeX for equations which
must stand out and therefore belong on separate lines. It would
therefore make sense to conform to the borrowed syntax.

2. the alternative displaymath environment could in principle be used
instead of \[...\]. However, this is not very nice because when
exporting to a text file the former is very invasive, while latter is
not.

3. Right now the \[...\] construct when exported to LaTeX produces
equations on dedicated lines. While the same construct when exported
to a text file results in an inline equation. This is inconsistent and
would be corrected by the change.

4. There are 2 other constructs dedicated to inline equations: \(...\)
and $...$.

5. Existing documents are very easy to fix.

6. Exporting to html can be adapted to produces any desired result and
should therefore not be a concern.

Regards,
Federico



Re: [O] [PATCH] Remove unecesssary invocations of org-mode in ox-publish

2014-07-30 Thread Nicolas Goaziou
Hello,

Matt Lundin m...@imapmail.org writes:

 Clearly, this is still very inadequate, but it is an improvement. I
 would love to use the built in site-map functions, but they are simply
 to slow for any larger projects.

 Could we do something like this to speed it up?

 (with-temp-buffer 
   (insert-file-contents file)
   (goto-char (point-min))
   (when (re-search-forward ^#\\+TITLE: nil t)
 (org-element-at-point)))

No, you also need to parse #+SETUPFILE: keywords. You could also get
false positive within a verbatim block:

 #+begin_example
 #+title: something
 #+end_example

However, it is possible to write a specialized function to extract
only #+TITLE.

Another option is to cache results. See `org-publish-cache-set' and
`org-publish-cache-get'.


Regards,

-- 
Nicolas Goaziou



Re: [O] Where is the git master branch?

2014-07-30 Thread John Kitchin
After you have the repo, run this to get on the master branch.

 git checkout master

and

 git checkout maint

to get back to maint.



Nicolas Richard theonewiththeevill...@yahoo.fr writes:

 Sharon Kimble boudic...@skimble.plus.com writes:
 If git clone git://orgmode.org/org-mode.git gets the development
 branch of org-mode, what is the git command to get the master branch
 please? I've been looking on http://orgmode.org/ but can't see any
 reference for it.

 The 'master' branch is the development/unstable branch. The stable
 branch is called 'maint'.

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



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

2014-07-30 Thread Nick Dokos
Ista Zahn istaz...@gmail.com writes:

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

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

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


I don't think there is any set-up you need to do (and the command works
for me, so there does not seem to be anything wrong with the server);
I think you are right in suspecting that your key was not properly
added. Unfortunately, Bastien is going to be away for a while and I'm
not sure who has access in his absence.

Nick




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

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

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

Unrelated to your problem: you should not use the SSH connection for
pulling.  Configure the orgmode repo to use the normal git for reading,
then configure (in your global user configuration) to use the SSH
connection just for pushing:

--8---cut here---start-8---
[url git+ssh:orgm...@orgmode.org:org-mode.git]
pushInsteadOf = git://orgmode.org/org-mode.git
--8---cut here---end---8---

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

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

Most likely, but it could also be that you haven't entered the correct
passphrase or are using the wrong key.


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

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




Re: [O] [POLL] Syntax change: make \[...\] non-inline (+1)

2014-07-30 Thread Nick Dokos
Federico Beffa be...@ieee.org writes:

 Who is entitled to vote? If I am then here is my vote in favor for the
 following reasons:

 1. the construct \[...\] has been defined in LaTeX for equations which
 must stand out and therefore belong on separate lines. It would
 therefore make sense to conform to the borrowed syntax.


I don't quite understand why you are so gung-ho for this but the
following works fine:

--8---cut here---start-8---
\documentclass{article}

\begin{document}
This is a displayed \[ x = 3 \] equation.
\end{document}
--8---cut here---end---8---

So what exactly is the problem?

 5. Existing documents are very easy to fix.


Backwards compatibility is important. It has been broken
before, for very good reasons, and even though it was done very
carefully, it still caused many problems (still does).
So I don't buy the very easy to fix part: it will bite somebody
two minutes before he/she has to make a presentation (or even during the
presentation - DAMHIKT).

Nick




Re: [O] org-element - canonical way to parse only headline at point?

2014-07-30 Thread Thorsten Jolitz
Nicolas Goaziou m...@nicolasgoaziou.fr writes:

 Hello,

 Thorsten Jolitz tjol...@gmail.com writes:

 with the new parser, how do I parse only the headline at point?  There
 are ARGS in the parser/mapper functions that restrict parsing, but I
 suspect that still the whole buffer is parsed for the genealogy - right?

 With my current knowledge I would either narrow the buffer to the subtree at
 point or copy this subtree to a temp-buffer before parsing/mapping it,
 but maybe there is a better way?

 Would this be a valid template (a simple and fast solution)?

 #+begin_src emacs-lisp
   (save-restriction
(org-narrow-to-subtree
 (org-element-map (org-element-parse-buffer 'headline t) 'headline
   (lambda () ...)
   nil t t)))
 #+end_src

 What about (org-element-at-point) ?

Thats why I asked - exactly the function I was looking for. Thanks.

-- 
cheers,
Thorsten




Re: [O] Installing Org 8

2014-07-30 Thread SabreWolfy
Jorge A. Alfaro-Murillo jorge.a.alfaro at gmail.com writes:

 Try putting (package-initialize) as the first line of your .emacs, 
 that should do the trick. 

This solved it. Thanks :)




[O] Feature Request: Merge subtrees in clock report

2014-07-30 Thread Subhan Michael Tindall
I'm looking for a way to merge subtrees with duplicate structure into a single 
subtree, primarily for the purposes of clockreporting on time.
In my mind it would work like this
'(org-merge-subtree-level 2) = determines how far down the tree to merge
org-merge-subtrees would match headlines down to the org-merge-subtree level, 
and if matched, content and further subtrees from matches would be merged into 
the first match. This could be done non-destructively or destructively 
(possibly another configuration option to determine this)
* m1
** mm1
   CLOCK: [2013-07-28 Mon 09:05]--[2013-07-28 Mon 09:30] =  0:25
   mm1 content
** mm2
   CLOCK: [2013-07-28 Mon 09:45]--[2013-07-28 Mon 10:13] =  0:28
   mm2 content
* m1
  CLOCK: [2013-07-28 Mon 09:30]--[2013-07-28 Mon 09:40] =  0:10
** mm2
   CLOCK: [2013-07-28 Mon 09:40]--[2013-07-28 Mon 09:45] =  0:05
   more mm2 content
** mm3
   CLOCK: [2013-07-28 Mon 10:30]--[2013-07-28 Mon 11:30] =  1:00
   mm3 content
(org-merge-subtrees) would produce a single tree:
* m1
 CLOCK: [2013-07-28 Mon 09:30]--[2013-07-28 Mon 09:40] =  0:10
** mm1
   CLOCK: [2013-07-28 Mon 09:05]--[2013-07-28 Mon 09:30] =  0:25
   mm1 content
** mm2
   CLOCK: [2013-07-28 Mon 09:45]--[2013-07-28 Mon 10:13] =  0:28
   CLOCK: [2013-07-28 Mon 09:40]--[2013-07-28 Mon 09:45] =  0:05
   mm2 content
   more mm2 content
** mm3
   CLOCK: [2013-07-28 Mon 10:30]--[2013-07-28 Mon 11:30] =  1:00
   mm3 content

Drawers should merge, CLOCK notes stay with the CLOCK line, etc

Ideally this would operate across files into a temporary buffer or var as well

Motivation is primarily to facilitate clockreporting.
Example: I have a project, RA, with 3 files in it.
I use a standard structure in files, like this
* overview
  project overview
* data files
** file 1
   content
** file 2
*** TODO generate data
* SQL
** query 1

I'd like to be able to generate a clocktable at the project level with all time 
spent on eg data files grouped and summarized into one entry. Instead what I 
get is something that looks like this (using my example above)
#+BEGIN: clocktable :block lastyear :narrow 30 :scope file :tcolumns 2 
:maxlevel 2
#+CAPTION: Clock summary at [2014-07-30 Wed 10:22], for the year 2013.
| 30   ||  |
| Headline   |   Time |  |
|++--|
| *Total time*   | *2:08* |  |
|++--|
| m1 |   0:53 |  |
| \__ mm1|| 0:25 |
| \__ mm2|| 0:28 |
| m1 |   1:15 |  |
| \__ mm2|| 0:05 |
| \__ mm3|| 1:00 |
#+END:

I guess this could operate either on the subtrees themselves, or maybe make 
clocktable smarter and have options to collapse tables like the above like this:
#+BEGIN: clocktable :block lastyear :narrow 30 :scope file :tcolumns 2 
:maxlevel 2 :collapse 2
#+CAPTION: Clock summary at [2014-07-30 Wed 10:22], for the year 2013.
| 30   ||  |
| Headline   |   Time |  |
|++--|
| *Total time*   | *2:08* |  |
|++--|
| m1 |  2:08 |  |
| \__ mm1|| 0:25 |
| \__ mm2|| 0:33 |
| \__ mm3|| 1:00 |
#+END:

And also work at the file level, so if the 2 m1 trees came from separate files 
they would be combined.

Subhan




Subhan Michael Tindall
Program Analyst - FamilyCare Health Plans
825 NE Multnomah St, Suite 1400; Portland OR 97232
Direct: 503-471-3127
Fax:  503-471-3177
Email:  subh...@familycareinc.orgmailto:subh...@familycareinc.org
[Email-Signature-Logos June 20143]


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


Re: [O] org-latex filters

2014-07-30 Thread Nicolas Goaziou
Hello,

Shiyuan gshy2...@gmail.com writes:

 I try to understand what the filter system is for and why the
 transcoders itself doesn't suffice. So I take an example and want to see
 how the filters are used in real exporter.  I look at ox-latex.el and try
 to make sense of the filters

 1. There are only two filters are used:

  :filters-alist '((:filter-options . org-latex-math-block-options-filter)
(:filter-parse-tree . org-latex-math-block-tree-filter))

 The purpose of org-latex-math-block-options-filter seems to be converting
 whatever in the property list of :author, :date, :title  to strings of
 latex commands(please correct me if I am wrong).  But what is the purpose
 of org-latex-math-block-tree-filter?

The same as `org-latex-math-block-options-filter', but on the parse tree
itself.

 The org-latex--wrap-latex-math-block is quite sophisticate and I don't
 get what it's doing.

It merges contiguous math objects into a single one, and give it a new
type (i.e, a pseudo type), which requires its own translator. For
example:

  \(1\)\alpha$+1$

more or less becomes

  \(\beta\alpha+1\)

 2. For the filters of the form :filter-TYPE, there is also a transcoder for
 processing the same TYPE. For example, for bold, there are :filter-bold,
 but bold is also processed in the transcoder specified in the transcoder
 alist when the backend is defined(by org-export-define-backend). When shall
 we use a transcode and when shall we use a filter?

A transcoder is mandatory. It transforms the parsed object into
a string. If there is no transcoder for a given type of object, all
objects of that type will be omitted from output.

A filter is applied on the output of the transcoder, for further
tweaking. Filters mainly target users, who do not have complete control
over transcoders (unless they create their own derived back-end).

There are also three special filters, which are not applied to the
output of a transcoder. Among them, two can be useful even for
a back-end developer: options filter and parse tree filter. For example,
they permit, as in ox-latex.el to introduce pseudo objects into the
parsed data.

You can also read The Filter System section in ox.el.

HTH,

-- 
Nicolas Goaziou



[O] Archiving logbook entries

2014-07-30 Thread Giorgio Valoti
Hi all,
I remember a discussion some time ago about archiving the logbook
entries, but I can’t find it on Gmane.

If someone has a link to to the thread, by any chance, I would be really
grateful.

Thank you in advance.

--
Giorgio Valoti




Re: [O] allow multiline #+BIND

2014-07-30 Thread Sebastien Vauban
Vladimir Alexiev wrote:
 It would be nice to allow multiline BINDs. I'd much rather write this than 
 put it all on one line:

 #+BIND: va/org-dot-preamble digraph g {
 #+BIND:   rankdir=LR nodesep=0.2 ranksep=0.1 arrowsize=0.2
 #+BIND:   node [fontname=courier fontsize=8 margin='0.02,0.01' shape=circle 
 width=0.1 height=0.1 label='']
 #+BIND:   edge [fontname=courier fontsize=8 labelfontname=courier 
 labelfontsize=8]

 The usual continuation syntax of backslash before the EOL can be used.
 Or else, a new keyword #+BIND1: for each continuation line.

 The function to fix is ox.el::org-export--list-bound-variables

In case it wouldn't get implemented, a workaround consists into setting
that var in an Emacs Lisp code block, run at the file opening.

Best regards,
  Seb

-- 
Sebastien Vauban




Re: [O] [babel][PATCHES] exporting inline source code

2014-07-30 Thread Nicolas Goaziou
Hello,

Nicolas Berthier nbe...@member.fsf.org writes:

 In any case, as advised earlier in the discussion, I updated one patch
 to integrate new tests for the new feature. I also slightly simplified
 the HTML export patch to avoid useless display attributes.

Thank you for this nice patch. Some comments follow.

 +   \\(?:^\\|[^-[:alnum:]]\\)\\(src_\\([^ \f\t\n\r\v\\[]+\\)

I think [^ \f\t\n\r\v[] is enough.

 +(defcustom org-babel-exp-inline-code-template
 +  src_%lang[%switches%flags]{%body}
 +  Template used to export the body of inline code blocks.
 +This template may be customized to include additional information
 +such as the code block name, or the values of particular header
 +arguments.  The template is filled out using `org-fill-template',
 +and the following %keys may be used.
 +
 + lang -- the language of the code block
 + name -- the name of the code block
 + body -- the body of the code block
 + switches -- the switches associated to the code block
 + flags - the flags passed to the code block
 +
 +In addition to the keys mentioned above, every header argument
 +defined for the code block may be used as a key and will be
 +replaced with its value.
 +  :group 'org-babel
 +  :type 'string)

You need to add :version and :package-version values for new defcustoms.

 +(ert-deftest ob-exp/exports-inline-code ()
 +  (should
 +   (string-match
 +(replace-regexp-in-string
 + \\[]{ \\(?:\\[]\\)?{ ;accept both src_sh[]{...} or src_sh{...}
 + (regexp-quote Here is one in the middle src_sh[]{echo 1} of a line.
 +Here is one at the end of a line. src_sh[]{echo 2}
 +src_sh[]{echo 3} Here is one at the beginning of a line.
 +Here is one that is also evaluated: src_sh[]{echo 4} =4=)
 + nil t)
 +(org-test-at-id cd54fc88-1b6b-45b6-8511-4d8fa7fc8076
 +  (org-narrow-to-subtree)
 +  (org-test-with-expanded-babel-code (buffer-string))

It is a matter of taste, but I think tests should be self-contained. In
particular, it isn't fun debugging `org-test-at-id'. The same goes for
other tests.

 +  (if lang
 +   (format code class=\src src-%s\%s%s/code lang label code)
 +   (format code class=\example\%s\n%s/code label code)

LANG cannot be nil. So,

  (format code class=\src src-%s\%s%s/code lang label code)

is sufficient.


Regards,

-- 
Nicolas Goaziou



Re: [O] [PATCH] Remove unecesssary invocations of org-mode in ox-publish

2014-07-30 Thread Matt Lundin
Nicolas Goaziou m...@nicolasgoaziou.fr writes:

 Hello,

 Matt Lundin m...@imapmail.org writes:

 Clearly, this is still very inadequate, but it is an improvement. I
 would love to use the built in site-map functions, but they are simply
 to slow for any larger projects.

 Could we do something like this to speed it up?

 (with-temp-buffer 
   (insert-file-contents file)
   (goto-char (point-min))
   (when (re-search-forward ^#\\+TITLE: nil t)
 (org-element-at-point)))

 No, you also need to parse #+SETUPFILE: keywords. You could also get
 false positive within a verbatim block:

  #+begin_example
  #+title: something
  #+end_example

 However, it is possible to write a specialized function to extract
 only #+TITLE.

 Another option is to cache results. See `org-publish-cache-set' and
 `org-publish-cache-get'.

Thanks for the helpful information. I think the cache would be a nice
way to go, especially if it were combined a timestamp check. E.g., only
files that have been updated since the last publishing should be queried
for titles; otherwise, use the cached file.

I notice that org-publish-find-title does cache the title, but AFAICT
this is never used, since org-publish-format-file-entry calls
org-publish-find-title with the reset argument. Perhaps we could add a
variable to make this optional in org-publish-format-file-entry. E.g., 

--8---cut here---start-8---
(defun org-publish-format-file-entry (fmt file project-plist)
  (format-spec
   fmt
   `((?t . ,(org-publish-find-title file org-publish-find-title-use-cache))
[...]
--8---cut here---end---8---

A similar option could be added to the date function date function.

Would it be O.K. if I went ahead and implemented this?
Thanks,
Matt





Re: [O] proposal for improved integration of cdlatex

2014-07-30 Thread Federico Beffa
Please find attached the patch as discussed.

Regards,
Fede

On Tue, Jul 29, 2014 at 4:54 PM, Bastien b...@gnu.org wrote:
 Federico Beffa be...@ieee.org writes:

 To be honest, I do not know. But, the original cdlatex-tab function
 takes those parameters and I thought it would be a good idea to pass
 on the same parameters, just in case someone uses them.

 Ah okay, I didn't check that.  Please go ahead with the patch then,

 --
  Bastien


0001-org.el-add-function-to-indent-environment-inserted-b.patch
Description: Binary data


Re: [O] [babel][PATCHES] exporting inline source code

2014-07-30 Thread Achim Gratz
Nicolas Goaziou writes:
 +   \\(?:^\\|[^-[:alnum:]]\\)\\(src_\\([^ \f\t\n\r\v\\[]+\\)

 I think [^ \f\t\n\r\v[] is enough.

Yes.  But looking at the original regex has me wondering if the need for
the extra '[' isn't an indication of something more fundamentally wrong
with it.  Where does that need to have unused groups and groups that
match the empty string come from?


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

SD adaptations for KORG EX-800 and Poly-800MkII V0.9:
http://Synth.Stromeko.net/Downloads.html#KorgSDada




Re: [O] Where is the git master branch?

2014-07-30 Thread Sharon Kimble
Nicolas Richard theonewiththeevill...@yahoo.fr writes:

 Sharon Kimble boudic...@skimble.plus.com writes:
 If git clone git://orgmode.org/org-mode.git gets the development
 branch of org-mode, what is the git command to get the master branch
 please? I've been looking on http://orgmode.org/ but can't see any
 reference for it.

 The 'master' branch is the development/unstable branch. The stable
 branch is called 'maint'.

Ok, so what is the command for the maint branch then please?

Thanks
Sharon.
-- 
A taste of linux = http://www.sharons.org.uk
my git repo = https://bitbucket.org/boudiccas/dots
TGmeds = http://www.tgmeds.org.uk
Debian testing, fluxbox 1.3.5, emacs 24.3.92.1


signature.asc
Description: PGP signature


Re: [O] [POLL] Syntax change: make \[...\] non-inline (+1)

2014-07-30 Thread Federico Beffa
 So what exactly is the problem?

The problem is that \[...\] is often used for long/complicated
equations. If you allow auto-fill to change/modify your carefully
written equation, it becomes very difficult to read.

Regards,
Fede



Re: [O] Where is the git master branch?

2014-07-30 Thread Achim Gratz
Sharon Kimble writes:
 The 'master' branch is the development/unstable branch. The stable
 branch is called 'maint'.

 Ok, so what is the command for the maint branch then please?

You'd say

git checkout maint

on the command line or just define

GIT_BRANCH=maint

in your local.mk and keep up-to-date with make up2 or another of the
convenience targets (check make helpall for details).


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

Factory and User Sound Singles for Waldorf Q+, Q and microQ:
http://Synth.Stromeko.net/Downloads.html#WaldorfSounds




Re: [O] [babel][PATCHES] exporting inline source code

2014-07-30 Thread Nicolas Goaziou
Hello,

Achim Gratz strom...@nexgo.de writes:

 Yes.  But looking at the original regex has me wondering if the need for
 the extra '[' isn't an indication of something more fundamentally wrong
 with it.

[^ \f\t\n\r\v] is wrong as character set allowed for languages should be
much more limited than that. I discussed it with Eric some months ago.

 Where does that need to have unused groups and groups that match the
 empty string come from?

This is probably to prevent matching

  thisisasrc_emacs-list{}


Regards,

-- 
Nicolas Goaziou



Re: [O] proposal for improved integration of cdlatex

2014-07-30 Thread Nicolas Goaziou
Hello,

Federico Beffa be...@ieee.org writes:

 +  (save-excursion
 +(org-mark-element)
 +(org-indent-region (point) (mark

The function shouldn't set the mark. The following should be enough:


  (let ((element (org-element-at-point)))
(when element
  (org-indent-region (org-element-property :begin element)
 (org-element-property :end element


Regards,

-- 
Nicolas Goaziou



Re: [O] Bug: pdf page numbers in links are ignored when exporting to latex [8.2.7b (8.2.7b-13-gd8a0ee-elpa @ /home/moritz/.emacs.d/elpa/org-20140728/)]

2014-07-30 Thread Nicolas Goaziou
Hello,

Moritz Kiefer moritz.kie...@gmail.com writes:

 I have lots of links to specific pages in a pdf like
 [[filename.pdf::24]] which works fine (with a correctly configured
 org-file-apps) but when I export to latex the page number is ignored and
 the includegraphics directive includes the first page. This can
 obviously manually be changed using #+ATTR_LATEX: :options page=42 but
 as the page number is already there it would be nice if orgmode would
 automatically use that when exporting.

Good idea. Page number can be accessed with

  (org-element-property :search-option link)

However, it should be checked against \\`[0-9]+\\' since a search
option can also be a headline:

  [[file:test.org::*My headline]]

Also, I guess it should only apply to link to pdf files.

Do you want to provide a patch for that?


Regards,

-- 
Nicolas Goaziou



[O] how to stop using org-mode from /usr/local/share/emacs/24.3.92/lisp/org/

2014-07-30 Thread Sharon Kimble
I've now got the maintenance branch, thanks for the pointers folks.

This is what I've done -
--8---cut here---start-8---
cd ~/git/org-mode-master
git checkout maint
git pull
make autoloads
make
make doc
sudo make install
cd ~
--8---cut here---end---8---

I know from watching it when its building that I have version
8.2.7c. But when I've reloaded org using the menu items = org -
refresh/reload - reload org after update, and then do M-x org-version
it shows
╭
│Org-mode version 8.2.6 (release_8.2.6-1 @ 
/usr/local/share/emacs/24.3.92/lisp/org/)
╰
 I have this line in my 'init.el'
 --8---cut here---start-8---
  (setq load-path (cons /home/boudiccas/git/org-mode-master load-path))
--8---cut here---end---8---

So how do I get it to only use the one from my init.el please? I've
never run into this problem before, and although I do remember hearing
about it, I can't recall the solution and there is no mention of it in
my emacsinstructions.org which is my repository for how to do various
things.

Thanks
Sharon.
-- 
A taste of linux = http://www.sharons.org.uk
my git repo = https://bitbucket.org/boudiccas/dots
TGmeds = http://www.tgmeds.org.uk
Debian testing, fluxbox 1.3.5, emacs 24.3.92.1


signature.asc
Description: PGP signature


Re: [O] [PATCH] Remove unecesssary invocations of org-mode in ox-publish

2014-07-30 Thread Nicolas Goaziou
Matt Lundin m...@imapmail.org writes:

 Thanks for the helpful information. I think the cache would be a nice
 way to go, especially if it were combined a timestamp check. E.g., only
 files that have been updated since the last publishing should be queried
 for titles; otherwise, use the cached file.

Unfortunately, in the following (unexpected) setup

  == a.org ==
  #+SETUPFILE: b.org

  == b.org ==
  #+TITLE: Something

modifying b.org changes title for a.org, even though the latter is
not modified. A dag would be needed to handle this case.

The same goes for #+INCLUDE keywords.

Overkill, IMO.

 I notice that org-publish-find-title does cache the title, but AFAICT
 this is never used, since org-publish-format-file-entry calls
 org-publish-find-title with the reset argument. Perhaps we could add a
 variable to make this optional in org-publish-format-file-entry. E.g., 

 (defun org-publish-format-file-entry (fmt file project-plist)
   (format-spec
fmt
`((?t . ,(org-publish-find-title file org-publish-find-title-use-cache))
 [...]

 A similar option could be added to the date function date function.

 Would it be O.K. if I went ahead and implemented this?

Fine by me. I suggest to mention previous caveat in the docstring.


Regards,

-- 
Nicolas Goaziou



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

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

Best,
Ista

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

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

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

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

[O] [BUG] org-toggle-time-stamp-overlays does not work in #+DATE line

2014-07-30 Thread Matt Lundin
Steps to replicate.

1. Evaluate the following:

(setq org-time-stamp-custom-formats '(%B %e, %Y . %B %e, %Y))

2. Use the following sample org file. 

--8---cut here---start-8---
#+DATE: [2014-07-30 Wed 22:05]

* Headline
  [2014-07-30 Wed 22:05]
--8---cut here---end---8---

3. M-x org-toggle-time-stamp-overlays

The buffer should look like this:

--8---cut here---start-8---
#+DATE: [2014-07-30 Wed]

* Headline
  [2014-07-30 Wed]
--8---cut here---end---8---

4. M-x org-toggle-time-stamp-overlays

The buffer now looks like this:

--8---cut here---start-8---
#+DATE: [2014-07-30 Wed 22:05]

* Headline
  [2014-07-30 Wed 22:05]
--8---cut here---end---8---

...thus preventing any easy editing of the timestamp in the #+DATE
line.

Best,
Matt



Re: [O] how to stop using org-mode from /usr/local/share/emacs/24.3.92/lisp/org/

2014-07-30 Thread Nick Dokos
Sharon Kimble boudic...@skimble.plus.com writes:

 I've now got the maintenance branch, thanks for the pointers folks.

 This is what I've done -

 cd ~/git/org-mode-master
 git checkout maint
 git pull
 make autoloads
 make
 make doc
 sudo make install

That will install org in a place like
/usr/local/share/emacs/site-lisp/org (the exact location depends on
makefile settings - check your local.mk for lispdir or do it again
and see where the finall install command installs everything.


 cd ~

 I know from watching it when its building that I have version
 8.2.7c. But when I've reloaded org using the menu items = org -
 refresh/reload - reload org after update, and then do M-x org-version
 it shows
 ╭
 │Org-mode version 8.2.6 (release_8.2.6-1 @ 
 /usr/local/share/emacs/24.3.92/lisp/org/)
 ╰
  I have this line in my 'init.el'
  --8---cut here---start-8---
   (setq load-path (cons /home/boudiccas/git/org-mode-master load-path))
 --8---cut here---end---8---

 So how do I get it to only use the one from my init.el please? I've
 never run into this problem before, and although I do remember hearing
 about it, I can't recall the solution and there is no mention of it in
 my emacsinstructions.org which is my repository for how to do various
 things.


Add the install directory to your load-path instead:

   (add-to-list 'load-path /usr/local/share/emacs/site-lisp/org)

or whatever the correct value is in your case.

-- 
Nick




[O] [BUG] org-html export does not put section numbers in div id

2014-07-30 Thread Matt Lundin
Take the following file:

--8---cut here---start-8---
#+options: num:nil

* Headline
** Subheading
* Another headline
--8---cut here---end---8---

When exported to html, the section headings are not numbered, as
expected. 

However, the section numbers are missing from the outline container
divs, which look like this:

div id=outline-container-sec- class=outline-2

As a result, the table of contents links do not work.

Here are the relevant portions of the html:

--8---cut here---start-8---
div id=content
h1 class=titletest/h1
div id=table-of-contents
h2Table of Contents/h2
div id=text-table-of-contents
ul
lia href=#sec-1Headline/a
ul
lia href=#sec-1-1Subheading/a/li
/ul
/li
lia href=#sec-2Another headline/a/li
/ul
/div
/div

div id=outline-container-sec- class=outline-2
h2 id=sec-Headline/h2
div class=outline-text-2 id=text-1
/divdiv id=outline-container-sec- class=outline-3
h3 id=sec-Subheading/h3
/div
/div
div id=outline-container-sec- class=outline-2
h2 id=sec-Another headline/h2
/div
/div
--8---cut here---end---8---

Thanks,
Matt



Re: [O] how to stop using org-mode from /usr/local/share/emacs/24.3.92/lisp/org/

2014-07-30 Thread Sharon Kimble
Nick Dokos ndo...@gmail.com writes:

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

 I've now got the maintenance branch, thanks for the pointers folks.

 This is what I've done -

 cd ~/git/org-mode-master
 git checkout maint
 git pull
 make autoloads
 make
 make doc
 sudo make install

 That will install org in a place like
 /usr/local/share/emacs/site-lisp/org (the exact location depends on
 makefile settings - check your local.mk for lispdir or do it again
 and see where the finall install command installs everything.


 cd ~

 I know from watching it when its building that I have version
 8.2.7c. But when I've reloaded org using the menu items = org -
 refresh/reload - reload org after update, and then do M-x org-version
 it shows
 ╭
 │Org-mode version 8.2.6 (release_8.2.6-1 @ 
 /usr/local/share/emacs/24.3.92/lisp/org/)
 ╰
  I have this line in my 'init.el'
  --8---cut here---start-8---
   (setq load-path (cons /home/boudiccas/git/org-mode-master load-path))
 --8---cut here---end---8---

 So how do I get it to only use the one from my init.el please? I've
 never run into this problem before, and although I do remember hearing
 about it, I can't recall the solution and there is no mention of it in
 my emacsinstructions.org which is my repository for how to do various
 things.


 Add the install directory to your load-path instead:

(add-to-list 'load-path /usr/local/share/emacs/site-lisp/org)

 or whatever the correct value is in your case.

Thanks for this Nick. I solved my problem by re-git-cloning the org-mode
repo, but this time I called it org-mode instead of the previous
org-mode-master. And now M-x org-version shows -
╭
│Org-mode version 8.2.7c (release_8.2.7c @ /home/boudiccas/git/org-mode/lisp/)
╰
which is what I've been looking for all along :)

Thanks
Sharon.
-- 
A taste of linux = http://www.sharons.org.uk
my git repo = https://bitbucket.org/boudiccas/dots
TGmeds = http://www.tgmeds.org.uk
Debian testing, fluxbox 1.3.5, emacs 24.3.92.1


signature.asc
Description: PGP signature