Re: [O] Fwd: Anyone using or interested in an org to Rmarkdown exporter?

2014-11-01 Thread Charles C. Berry

On Sat, 1 Nov 2014, John Hendy wrote:

[snip]

From: John Hendy 
Date: Fri, Oct 31, 2014 at 7:32 PM
Subject: Re: [O] Anyone using or interested in an org to Rmarkdown exporter?
To: Grant Rettke 


On Thu, Oct 30, 2014 at 11:37 AM, Grant Rettke  wrote:

Good morning,

Last week I started learning about [RMarkdown]. It is a [literate
programming] tool implemented in, and for, the [ℝ programming
language]. Although I haven't dug in deep yet, I do know that (1) it is
/basically/ [Markdown] and that (2) `org' exports both to [vanilla
markdown] and also [GitHub flavored Markdown] and that (3) a lot of my
peers use `RMarkdown' and not `org'. With that that in mind I got
curious about what it would take to write an `org2rmarkdown' exporter.

The scope of my interest is one-time exports for the most basic and
simple `org' document. As such, right now I have no requirements beyond
thinking about the opportunity. After doing some Internet searches,
there does not seem to be an exporter right now. Questions:

• Does one exist and I missed it?


Possibly; at least in some form it does:
- https://github.com/chasberry/orgmode-accessories/blob/master/ox-ravel.org


• Do you have any interest in such an exporter?


Yes!
- https://lists.gnu.org/archive/html/emacs-orgmode/2014-01/msg01436.html
- https://lists.gnu.org/archive/html/emacs-orgmode/2014-02/msg00291.html


• Has anyone else ever thought of doing this? If yes, why didn't you?


Yes:
- Don't know elisp
- Found the above, which mostly worked. I had to edit my Org file to
feature a carriage return between text and my lists. ox-ravel appears
to export literally,


Actually ox-ravel uses derived backends (see the docstring for 
`org-export-define-derived-backend'. Exporting lists and other orgmode 
markup to Rmarkdown is handled by the `md' exporter in ox-md.el.



and it appears knittr won't pick up a list if
there's no blank line between regular text and a list.


No, it doesn't. knitr assumes the markdown (or LaTeX or whatever it is 
processing) is correct as written.



In other words,
this:

list
- item1
- item2

Isn't the same as this:

list

- item1
- item2


If this is a bug (as it seems), it should probably get a thread with a 
subject line like `org-md-plain-list needs newline' and your example above 
as the ECM.


It is really easy to force `org-md-plain-list' to do this like so:

#+BEGIN_SRC emacs-lisp
  (defun org-md-plain-list (plain-list contents info)
"Transcode PLAIN-LIST element into Markdown format.
  CONTENTS is the plain-list contents.  INFO is a plist used as
  a communication channel."
(concat "\n" contents))
#+END_SRC

but this adds vertical padded around nested lists, so something a bit more 
sophisticated is needed.




Probably a simple enough fix, but just pointing out one nuance that
org in general and other exporters don't struggle with (they recognize
a list even with no blank line).


The `md' exporter knows the list is a list - it just doesn't add the 
newline that tells pandoc (or whatever) that the next line could start a 
list.





• My guess is that doing an exporter that [builds on an existing
  exporter], mentioned above, would be a great start. Thoughts?
  • The big difference seems to be control statements passed to the
interpreter, which may or may not be necessary to convert. If not,
than the *stock* `markdown' exporter would provide everything



See if the attached are satisfactory
- test.org: just a heading, a couple lists, R code (and output), and an image
- test.Rmd: output of ox-ravel Rmd exporter
- test.html (well, a screenshot): results of opening test.Rmd in
RStudio and knitting



Thanks for the example.

Best,

Chuck


[O] How to select the entry to clock in from already clocked entries in the current buffer?

2014-11-01 Thread Marcin Borkowski
Hi list,

the subject line is pretty much it.  I have lots of entries in my
current Org buffer, and only some of them contain LOGBOOK drawers with
any clock data.  Is it possible to (quickly) select one of them for
clocking?

Best,

-- 
Marcin Borkowski
http://octd.wmi.amu.edu.pl/en/Marcin_Borkowski
Adam Mickiewicz University



Re: [O] Org Babel Clojure No Prettyprint

2014-11-01 Thread Prathyush
Thanks a bunch Oleh. Works very well now.

Oleh  gmail.com> writes:

> 
> Hi,
> 
> I've just pushed a fix for this.
> See if works now.
> 
> regards,
> Oleh







[O] [PATCH] org.el (org-adapt-indentation): Fix typo

2014-11-01 Thread Kyle Meyer
Hello,

A patch for a minor docstring typo is attached.

Thanks,
Kyle

>From 21dc34060c939b862b2e926f5aa68d5e97e53cbf Mon Sep 17 00:00:00 2001
From: Kyle Meyer 
Date: Sat, 1 Nov 2014 17:45:11 -0400
Subject: [PATCH] org.el (org-adapt-indentation): Fix typo

* lisp/org.el (org-adapt-indentation): Fix typo in docstring.
---
 lisp/org.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lisp/org.el b/lisp/org.el
index 84b0786..1b17d2c 100755
--- a/lisp/org.el
+++ b/lisp/org.el
@@ -1470,7 +1470,7 @@ (defcustom org-adapt-indentation t
   body starts with text at column 0, indentation is not changed at all.
 
 - Property drawers and planning information is inserted indented when
-  this variable s set.  When nil, they will not be indented.
+  this variable is set.  When nil, they will not be indented.
 
 - TAB indents a line relative to context.  The lines below a headline
   will be indented when this variable is set.
-- 
2.1.3



Re: [O] Proper settings for tj3 report directory/output?

2014-11-01 Thread John Hendy
On Wed, Oct 29, 2014 at 6:39 PM, John Hendy  wrote:
> I just re-set up tj3 on a new work computer and am a bit puzzled by
> the report directory structure.

Disregard; it's an Arch Linux package issue. Created a bug report, and
through trying the Arch package way vs. straight up gem install, found
out that the vanilla gem functions properly.
- Github issue filed (now closed):
https://github.com/taskjuggler/TaskJuggler/issues/154
- Arch linux bug report: https://bugs.archlinux.org/task/42651

So... all is fine with Org and the exporter. Sorry for the noise!


John



[O] org-babel-detangle not working

2014-11-01 Thread Jaakko Järvi
There seems to be something wrong with detangling.
Would it be working, it would be a really wonderful feature.

Detangling moves back to the org buffer and opens a source block editing buffer,
but does not change to block in the org buffer.

Is detangling working for some? I see this same issue described around
2013:

  http://thread.gmane.org/gmane.emacs.orgmode/75290/focus=75299

Below, a minimal test.org file and its tangled output.

Thanks, 

  Jaakko Järvi

- test.org 
* Heading

#+BEGIN_SRC js :comments noweb :tangle yes :padline no
  function foo() {}
#+END_SRC
--- 

- test.js -
// [[file:~/test/test.org::*Heading][Heading:1]]
function foo() {}
// Heading:1 ends here
---


[O] patch to add new link type "infoi" that leverages Info-index command

2014-11-01 Thread Richard Kim
A patch is provided below which implements a new link type called "infoi"
as a complement to "info" type that exist already.

Why new link type?  Because info index is almost always finer grain
than info nodes.  For example [[infoi:libc#close]] brings up not only
"(libc)Opening and Closing Files" info node, but also place the cursor
on the line that documents "open" function within the node.  Hence it
is more useful to link function, variable and other names that are in
the index.  Most info documents have very rich indexes.

I am not familiar with org coding style, so I share this patch to
present the idea rather than as a finished patch that can be checked
in.  I assume that name changes and other changes will be needed prior
to being acceptable for check in assuming that the idea is ok.

ChangeLog entry is followed by the git diff of my change.



org-info.el: Add new link type "infoi" that looks up info file index.

* lisp/org-info.el (org-info-index-open): New function to implement
new link type named "infoi".



diff --git a/doc/org.texi b/doc/org.texi
index 3fcf4b2..3aedefe 100644
--- a/doc/org.texi
+++ b/doc/org.texi
@@ -3576,6 +3576,7 @@ gnus:group#id @r{Gnus
article link}
 bbdb:R.*Stallman  @r{BBDB link (with regexp)}
 irc:/irc.com/#emacs/bob   @r{IRC link}
 info:org#External links   @r{Info node link}
+infoi:org#topic   @r{Info index link}
 shell:ls *.org@r{A shell command}
 elisp:org-agenda  @r{Interactive Elisp command}
 elisp:(find-file-other-frame "Elisp.org") @r{Elisp form to evaluate}
diff --git a/lisp/org-info.el b/lisp/org-info.el
index 8a2d717..bb65347 100644
--- a/lisp/org-info.el
+++ b/lisp/org-info.el
@@ -74,6 +74,23 @@
   (Info-find-node (match-string 1 name) "Top")))
 (message "Could not open: %s" name)))

+;;; info-index
+
+(org-add-link-type "infoi" 'org-info-index-open)
+
+(declare-function Info-index "info" (topic))
+
+(defun org-info-index-open (name)
+  "Follow an Info file and look up index item specified by NAME."
+  (if (or (string-match "\\(.*\\)[#:]:?\\(.*\\)" name)
+  (string-match "\\(.*\\)" name))
+  (let ((nodename (match-string 2 name)))
+(require 'info)
+(Info-find-node (match-string 1 name) "Top")
+(if nodename ; If there isn't a node, choose "Top"
+(Info-index nodename)))
+(message "Could not open: %s" name)))
+
 (provide 'org-info)

 ;;; org-info.el ends here


Re: [O] Anyone using or interested in an org to Rmarkdown exporter?

2014-11-01 Thread Thorsten Jolitz
"Charles C. Berry"  writes:

> As to Thorsten's query:
>
> ,
> | what would acutally be the benefit of using RMarkdown over Org-mode,
> | or put it another way - when you already use RMarkdown, why do you
> | need Org-mode too? And if you use Org-mode, what does RMarkdown add to
> | the table?
> `
>
> There is some discussion of this in the README.org...
>
> If you already use org-mode:
>
> You get access to Sweave, knitr, slidify, pander, et cetera.
>
> Their `chunk' options (akin to babel header args) can be easier to use
> than header args for complicated displays.
>
> Dependency aware caching of R objects is available in those engines
> and its lack in Babel [1] is a serious impediment to working with long
> running computations.
>
> bioConductor vignettes can be authored in org-mode and exported for a
> suitable vignette engine.
>
> If you already use Rmarkdown, etc, you get the ease of editting and
> working in org-mode - cycling visibility of headlines, lists, src
> blocks, and results, and of storing results inline, previewing latex
> fragments, and all.
>
> HTH,

Yes, definitely, thanks for the info. So it makes sense to add another
tool ;)

-- 
cheers,
Thorsten




Re: [O] Anyone using or interested in an org to Rmarkdown exporter?

2014-11-01 Thread Charles C. Berry

On Sat, 1 Nov 2014, Rasmus wrote:


Hello,

Grant Rettke  writes:


• Does one exist and I missed it?


Are you aware of this project?

   https://github.com/chasberry/orgmode-accessories

—Rasmus



Thanks for this, Rasmus.

Grant,

If ox-ravel is something you are interested, I recommend that you
tryout the `ravel-lang' branch. In addition to the examples in the
master branch, there is `demos.org' with some simple examples.

As to Thorsten's query:

,
| what would acutally be the benefit of using RMarkdown over Org-mode,
| or put it another way - when you already use RMarkdown, why do you
| need Org-mode too? And if you use Org-mode, what does RMarkdown add to
| the table?
`

There is some discussion of this in the README.org...

If you already use org-mode:

You get access to Sweave, knitr, slidify, pander, et cetera.

Their `chunk' options (akin to babel header args) can be easier to use
than header args for complicated displays.

Dependency aware caching of R objects is available in those engines and 
its lack in Babel [1] is a serious impediment to working with long running 
computations.


bioConductor vignettes can be authored in org-mode and exported for a
suitable vignette engine.

If you already use Rmarkdown, etc, you get the ease of editting and
working in org-mode - cycling visibility of headlines, lists, src
blocks, and results, and of storing results inline, previewing latex
fragments, and all.

HTH,

Chuck

[1] Yes, I do know that there is a :cache header arg.

[O] Fwd: Anyone using or interested in an org to Rmarkdown exporter?

2014-11-01 Thread John Hendy
Whoops -- missed the reply-all on this!

John


-- Forwarded message --
From: John Hendy 
Date: Fri, Oct 31, 2014 at 7:32 PM
Subject: Re: [O] Anyone using or interested in an org to Rmarkdown exporter?
To: Grant Rettke 


On Thu, Oct 30, 2014 at 11:37 AM, Grant Rettke  wrote:
> Good morning,
>
> Last week I started learning about [RMarkdown]. It is a [literate
> programming] tool implemented in, and for, the [ℝ programming
> language]. Although I haven't dug in deep yet, I do know that (1) it is
> /basically/ [Markdown] and that (2) `org' exports both to [vanilla
> markdown] and also [GitHub flavored Markdown] and that (3) a lot of my
> peers use `RMarkdown' and not `org'. With that that in mind I got
> curious about what it would take to write an `org2rmarkdown' exporter.
>
> The scope of my interest is one-time exports for the most basic and
> simple `org' document. As such, right now I have no requirements beyond
> thinking about the opportunity. After doing some Internet searches,
> there does not seem to be an exporter right now. Questions:
>
> • Does one exist and I missed it?

Possibly; at least in some form it does:
- https://github.com/chasberry/orgmode-accessories/blob/master/ox-ravel.org

> • Do you have any interest in such an exporter?

Yes!
- https://lists.gnu.org/archive/html/emacs-orgmode/2014-01/msg01436.html
- https://lists.gnu.org/archive/html/emacs-orgmode/2014-02/msg00291.html

> • Has anyone else ever thought of doing this? If yes, why didn't you?

Yes:
- Don't know elisp
- Found the above, which mostly worked. I had to edit my Org file to
feature a carriage return between text and my lists. ox-ravel appears
to export literally, and it appears knittr won't pick up a list if
there's no blank line between regular text and a list. In other words,
this:

list
- item1
- item2

Isn't the same as this:

list

- item1
- item2

Probably a simple enough fix, but just pointing out one nuance that
org in general and other exporters don't struggle with (they recognize
a list even with no blank line).

> • My guess is that doing an exporter that [builds on an existing
>   exporter], mentioned above, would be a great start. Thoughts?
>   • The big difference seems to be control statements passed to the
> interpreter, which may or may not be necessary to convert. If not,
> than the *stock* `markdown' exporter would provide everything
>

See if the attached are satisfactory
- test.org: just a heading, a couple lists, R code (and output), and an image
- test.Rmd: output of ox-ravel Rmd exporter
- test.html (well, a screenshot): results of opening test.Rmd in
RStudio and knitting


Let me know what you think!
John


test.org
Description: Binary data
# test

Unordered list

-   How does this work?
-   Simple list
-   'Nother item

Numbered list

1.  Switch it up
2.  Numbers this time

Some code:

```{r }
x <- 1:10
y <- x^2

y
```

Image?

![img](./tux.png)

[O] Contribution to org-mode, Eldoc support

2014-11-01 Thread Łukasz Gruner
Hi

I would like to contribute Eldoc support.
I've already changed license, but dont quite get that pgp part, I have
generated my pgp and now what?

Cheers,
Łukasz Gruner
From e96112a92c7c24f16c1274b3e8c6567634e19eb1 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=C5=81ukasz=20Gruner?= 
Date: Sat, 1 Nov 2014 15:57:54 +0100
Subject: [PATCH] Add eldoc support for src_blocks and headlines.

* lisp/org-eldoc.el (org-eldoc-hook-setup) initialize
eldoc with org mode. Org mode will display Breadcrumb path
when on a header line, src block properties when on src block
and while inside of src-block will try to act natively for that
language.
---
 lisp/org-eldoc.el | 172 ++
 1 file changed, 172 insertions(+)
 create mode 100644 lisp/org-eldoc.el

diff --git a/lisp/org-eldoc.el b/lisp/org-eldoc.el
new file mode 100644
index 000..844100d
--- /dev/null
+++ b/lisp/org-eldoc.el
@@ -0,0 +1,172 @@
+;;; org-eldoc.el --- display org header and src block info using eldoc
+
+;; Copyright (c) 2014 Free Software Foundation, Inc.
+
+;; Author: Łukasz Gruner 
+;; Maintainer: Łukasz Gruner 
+;; Version: 6
+;; Package-Requires: ((org "8"))
+;; URL: https://bitbucket.org/ukaszg/org-eldoc
+;; Created: 25/05/2014
+;; Keywords: eldoc, outline, breadcrumb, org, babel, minibuffer
+
+;; This file is not part of Emacs.
+
+;; GNU Emacs 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 of the License, or
+;; (at your option) any later version.
+
+;; GNU Emacs 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.  If not, see .
+
+;;; Commentary:
+
+;; To enable, put the following in your .emacs file:
+;;
+;; (org-eldoc-hook-setup) ;; have org-eldoc add itself to `org-mode-hook'
+;; OR run:
+;; (org-eldoc-load)   ;; to setup org-eldoc and enable `eldoc-mode'
+;;
+;;
+;; Report bugs and feature requests at:
+;;
+;; https://bitbucket.org/ukaszg/org-eldoc/issues
+
+;;; Changelog:
+
+;; As of 01/11/14 switching license to GPL3 to allow submission to org-mode.
+
+;;; Code:
+
+(require 'org)
+(require 'ob-core)
+(require 'eldoc)
+
+(defgroup org-eldoc nil "" :group 'org)
+
+(defcustom org-eldoc-breadcrumb-separator "/"
+  "Breadcrumb separator."
+  :group 'org-eldoc
+  :type 'string)
+
+(defcustom org-eldoc-test-buffer-name " *Org-eldoc test buffer*"
+  "Name of the buffer used while testing for mode-local variable values."
+  :group 'org-eldoc
+  :type 'string)
+
+(defun org-eldoc-get-breadcrumb ()
+  "Return breadcrumb if on a headline or nil."
+  (let ((case-fold-search t) cur)
+(save-excursion
+  (beginning-of-line)
+  (save-match-data
+(when (looking-at org-complex-heading-regexp)
+  (setq cur (match-string 4))
+  (org-format-outline-path
+   (append (org-get-outline-path) (list cur))
+   (frame-width) "" org-eldoc-breadcrumb-separator))
+
+(defun org-eldoc-get-src-header ()
+  "Returns lang and list of header properties if on src definition line and nil otherwise."
+  (let ((case-fold-search t) info lang hdr-args)
+(save-excursion
+  (beginning-of-line)
+  (save-match-data
+(when (looking-at "^[ \t]*#\\+\\(begin\\|end\\)_src")
+  (setq info (org-babel-get-src-block-info 'light)
+lang (propertize (nth 0 info) 'face 'font-lock-string-face)
+hdr-args (nth 2 info))
+  (concat
+   lang
+   ": "
+   (mapconcat
+(lambda (elem)
+  (when (and (cdr elem) (not (string= "" (cdr elem
+(concat
+ (propertize (symbol-name (car elem)) 'face 'org-list-dt)
+ " "
+ (propertize (cdr elem) 'face 'org-verbatim)
+ " ")))
+hdr-args " ")))
+
+(defun org-eldoc-get-src-lang ()
+  "Return value of lang for the current block if in block body and nil otherwise."
+  (let ((case-fold-search t))
+(save-match-data
+  (when (org-between-regexps-p ".*#\\+begin_src"
+   ".*#\\+end_src")
+(save-excursion
+  (goto-char (org-babel-where-is-src-block-head))
+  (car (org-babel-parse-src-block-match)))
+
+(defvar org-eldoc-local-functions-cache (make-hash-table :size 40 :test 'equal)
+  "Cache of major-mode's eldoc-documentation-functions,
+ used by \\[org-eldoc-get-mode-local-documentation-function].")
+
+(defun org-eldoc-get-mode-local-documentation-function (lang)
+  "Check if LANG-mode sets eldoc-documentation-function and return its value."
+  (let ((cached-func (ge

Re: [O] Anyone using or interested in an org to Rmarkdown exporter?

2014-11-01 Thread Rasmus
Hello,

Grant Rettke  writes:

> • Does one exist and I missed it?

Are you aware of this project?

https://github.com/chasberry/orgmode-accessories

—Rasmus

-- 
Dobbelt-A





Re: [O] How do you interact with org src blocks for your gmane.emacs.orgmode correspondence?

2014-11-01 Thread Alexander Baier
On 2014-10-31 23:51 Brady Trainor wrote:
> This seems wholly inefficient, and I'm hoping there is some obviously
> easier way to do it, no matter how much elisp is needed.
>
> I am not sure it is relevant, but my rather vanilla Gnus setup
> includes drafting mail in Message buffer. I didn't quickly find how to
> switch to drafting with Gnus, so I make the cursory assumption that
> this is not the trick to at least seeing highlighting of src blocks
> while drafting emails.

I use the setup described in this thread:
http://permalink.gmane.org/gmane.emacs.orgmode/86234

Regards,
-- 
Alexander Baier



Re: [O] Recent startup error in Org

2014-11-01 Thread Mike McLean
On Sat, Nov 1, 2014 at 7:08 AM, Nicolas Goaziou 
wrote:

> Hello,
>
> Mike McLean  writes:
>
> > I updated to git-head today; my most recent update was about 1 week
> prior.
> > Today I get a startup error in Emacs (Back trace of debug-init below).
> >
> > Emacs Version: GNU Emacs 24.4.1 (x86_64-apple-darwin13.4.0, NS
> > apple-appkit-1265.21) of 2014-10-21 on mac-mike-2013
> >
> > Org Version: Org-mode version 8.3beta (release_8.3beta-513-gaa1fd6.dirty
> @
> > /Users/mlm/.emacs.d/el-get/org-mode/lisp/)
> >
> > Debugger entered--Lisp error: (error "Symbol nil may not be
> buffer-local")
>
> This should be fixed. Thank you for reporting it.
>

I can confirm; fixed as of 82de7da

Thank you for the quick fix.


Re: [O] fixed: Endless loop in org--setup-collect-keywords (agenda, ...)

2014-11-01 Thread Karl Voit
* Nicolas Goaziou  wrote:
> Hello,

Hello Nicolas!

> Karl Voit  writes:
>
>> At many occasions, my Emacs 24.3.50.1 hangs in an endless loop.
>>
>> | Debugger entered--Lisp error: (quit)
>> |   org--setup-collect-keywords("^[ 
>> ]*#\\+\\(\\(?:ARCHIVE\\|C\\(?:ATEGORY\\|O\\(?:\\(?:LUMN\\|NSTANT\\)S\\)\\)\\|FILETAGS\\|LINK\\|PR\\(?:IORITIES\\|OPERTY\\)\\|S\\(?:E\\(?:Q_TODO\\|TUPFILE\\)\\|TARTUP\\)\\|T\\(?:AGS\\|\\(?:YP_T\\)?ODO\\)\\)\\):[
>>  ]*\\(.*\\)")
>
> I think latest commit fixed it. Could you confirm it? Otherwise, I'll
> need an ECM to reproduce it.

The latest master commit fixed this issue - thanks for the quick
response!




Re: [O] Beamer Export Columns

2014-11-01 Thread Eric S Fraga
Quick question: what version of the exporter (and org) are you using?
-- 
: Eric S Fraga (0xFFFCF67D), Emacs 25.0.50.1, Org release_8.3beta-475-g25d50e



Re: [O] Recent startup error in Org

2014-11-01 Thread Nicolas Goaziou
Hello,

Mike McLean  writes:

> I updated to git-head today; my most recent update was about 1 week prior.
> Today I get a startup error in Emacs (Back trace of debug-init below).
>
> Emacs Version: GNU Emacs 24.4.1 (x86_64-apple-darwin13.4.0, NS
> apple-appkit-1265.21) of 2014-10-21 on mac-mike-2013
>
> Org Version: Org-mode version 8.3beta (release_8.3beta-513-gaa1fd6.dirty @
> /Users/mlm/.emacs.d/el-get/org-mode/lisp/)
>
> Debugger entered--Lisp error: (error "Symbol nil may not be buffer-local")

This should be fixed. Thank you for reporting it.


Regards,

-- 
Nicolas Goaziou



Re: [O] How do you interact with org src blocks for your gmane.emacs.orgmode correspondence?

2014-11-01 Thread Thorsten Jolitz
Brady Trainor  writes:

> 1. Cut some pieces from my .el or .org files, 
> 2. Paste into the scratch buffer,
> 3. Convert scratch buffer to Major mode org, 
> 4. Add src blocks using org-mode shortcuts (" 5. Edit as needed for email, for instance taking advantage of
> indenting etc. in "C-c '" mode
> 6. Cut and paste from scratch buffer to email draft
> 7. Edit email
> 8. If extensive editing of src blocks is needed while drafting, may
> consider switching back to scratch buffer including further cutting
> and pasting
>
> This seems wholly inefficient, and I'm hoping there is some obviously
> easier way to do it, no matter how much elisp is needed.

Yup. 

Outorg works with message-mode too, so I write my mails in message-mode,
and do

,
| M-# # (outorg-edit-as-org)
`

whenever I need Org-mode functionality like src-blocks, and then

,
| M-# (outorg-copy-edits-and-exit)
`

in the *outorg-edit-buffer* when I'm done with editing in
Org-mode. Makes it easy to edit you emails in full Org-mode.

There are some extra benefits, like automatic (optionally temporary)
insertion of export headers, automatic backup files in a /tmp folder
(one file for each explicit save with C-x C-s, and one saved when
killing the *outorg-edit-buffer*). 

And there is a new library

[[http://goo.gl/pYYzS6][outorg-export]]

by Jonathan Leech-Pepin that keeps source-files and (Org) exports in
sync.

-- 
cheers,
Thorsten




Re: [O] Endless loop in org--setup-collect-keywords (agenda, ...)

2014-11-01 Thread Nicolas Goaziou
Hello,

Karl Voit  writes:

> Weird behaviour: yesterday I switched my init.el to OrgStruct and
> re-organized it a bit. Silly me thought it would also be a clever
> time to update my Org git repo.
>
> At many occasions, my Emacs 24.3.50.1 hangs in an endless loop. When
> I break it, I get following Backtrace:
>
> | Debugger entered--Lisp error: (quit)
> |   org--setup-collect-keywords("^[ 
> ]*#\\+\\(\\(?:ARCHIVE\\|C\\(?:ATEGORY\\|O\\(?:\\(?:LUMN\\|NSTANT\\)S\\)\\)\\|FILETAGS\\|LINK\\|PR\\(?:IORITIES\\|OPERTY\\)\\|S\\(?:E\\(?:Q_TODO\\|TUPFILE\\)\\|TARTUP\\)\\|T\\(?:AGS\\|\\(?:YP_T\\)?ODO\\)\\)\\):[
>  ]*\\(.*\\)")
> |   org-set-regexps-and-options()
> |   org-mode()
> |   set-auto-mode-0(org-mode nil)
> |   #[0 "\302\242\237\211\205.
> | [...]
>
> (Sorry for the long line)
>
> Do you have a clue if my update or my re-arrangement of my init.el
> could have caused this?

I think latest commit fixed it. Could you confirm it? Otherwise, I'll
need an ECM to reproduce it.


Regards,

-- 
Nicolas Goaziou



Re: [O] [RFC] Change property drawer syntax

2014-11-01 Thread Nicolas Goaziou
Hello,

Christian Egli  writes:

> I see that it is too late now, but let me still note that the
> taskjuggler exporter is quite liberal in what attribute values it allows
> for exporting. I've never used it and I haven't ever seen anyone using
> it, but in theory you could give a task a note or a journalentry which
> spans multiple lines. This will no longer be possible with this
> change.

I'm not sure to understand what is a note or a journalentry which spans
multiple lines. Could you give an example?


Regards,

-- 
Nicolas Goaziou



Re: [O] [Bug] Hanging multiple TAG lines in setup file

2014-11-01 Thread Nicolas Goaziou
Hello,

Kyle Meyer  writes:

> I'm experiencing a second issue that seems to be introduced by commit
> 61a241f ('Rewrite setup keywords initialization'). Starting Emacs (24.4)
> with 'emacs -Q' and with no additional setup besides loading Org, I see
> the following behavior.
>
> Opening test-good.org works as usual.
>
> , setup-good.org
> | #+TAGS: tag1 tag2
> | #+TAGS: tag3 tag4
> `
> , test-good.org
> | #+setupfile: setup-good.org
> |
> | * heading 1
> `
>
> Opening test-bad.org hangs indefinitely.
>
> , setup-bad.org
> | #+TAGS: tag1 tag2
> | #+TAGS: tag3 tag4
> | #+TAGS: tag5 tag6
> `
> , test-bad.org
> | #+setupfile: setup-bad.org
> |
> | * heading 1
> `

This should be fixed. Thank you for reporting it.


Regards,

-- 
Nicolas Goaziou



Re: [O] OrgStruct: start with collapsed view

2014-11-01 Thread Thorsten Jolitz
Scott Randby  writes:

>> What if you try navi-mode with your orgstruct init.el? It works with
>> outshine and with org-mode, so maybe with orgstruct too?
>
> I found this on http://orgmode.org/worg/org-tutorials/org-outside-org.html.
>
>   "orgstruct currently does NOT work with outorg and navi-mode..."

Ups, than I wrote this (and forgot about it). I still wonder why it
wouldn't work if 'natural' header conventions are used like

,
| ;; * 1st level
| ;; ** 2nd level
`

or 

,
| ;;; 1st level
|  2nd level
`

but I somehow remember that orgstructs default conventions are
different. 

Well, thinking about it, its probably a matter of buffer-local vars for
outline-mode, and orgstructs sets its own variables leaving the outline
vars as-is (correct?), but outshine uses the outline vars and thus does
not find regexps for Org-style headers. Or so...

-- 
cheers,
Thorsten




Re: [O] Anyone using or interested in an org to Rmarkdown exporter?

2014-11-01 Thread Thorsten Jolitz
Grant Rettke  writes:

Hi Grant,

> Last week I started learning about [RMarkdown]. It is a [literate
> programming] tool implemented in, and for, the [ℝ programming
> language]. Although I haven't dug in deep yet, I do know that (1) it is
> /basically/ [Markdown] and that (2) `org' exports both to [vanilla
> markdown] and also [GitHub flavored Markdown] and that (3) a lot of my
> peers use `RMarkdown' and not `org'. With that that in mind I got
> curious about what it would take to write an `org2rmarkdown' exporter.
>
> The scope of my interest is one-time exports for the most basic and
> simple `org' document. As such, right now I have no requirements beyond
> thinking about the opportunity. After doing some Internet searches,
> there does not seem to be an exporter right now. Questions:
>
> • Does one exist and I missed it?
> • Do you have any interest in such an exporter?
> • Has anyone else ever thought of doing this? If yes, why didn't you?
> • My guess is that doing an exporter that [builds on an existing
>   exporter], mentioned above, would be a great start. Thoughts?
>   • The big difference seems to be control statements passed to the
> interpreter, which may or may not be necessary to convert. If not,
> than the *stock* `markdown' exporter would provide everything
>
> Kind regards,

what would acutally be the benefit of using RMarkdown over Org-mode, or
put it another way - when you already use RMarkdown, why do you need
Org-mode too? And if you use Org-mode, what does RMarkdown add to the
table? 

And then there is Outshine too, which lets you switch seemlessly switch
between ESS[R] and Org-mode, so you can program in R-mode, and write and
export in Org-ode, as well as other LP modes like the old (now
overhauled) ESS multi-mode and a new multi-mode developed by Phillip
Lord, so one needs reasons to add just another tool to the tool stack IMO.

> [RMarkdown] http://rmarkdown.rstudio.com/
>
> [literate programming]
> https://en.wikipedia.org/wiki/Literate_programming
>
> [ℝ programming language] http://www.r-project.org/
>
> [Markdown] http://daringfireball.net/projects/markdown/syntax
>
> [vanilla markdown] http://orgmode.org/manual/Markdown-export.html
>
> [GitHub flavored Markdown]
> http://orgmode.org/cgit.cgi/org-mode.git/plain/contrib/lisp/ox-gfm.el
>
> [builds on an existing exporter]
> http://orgmode.org/manual/Adding-export-back_002dends.html

-- 
cheers,
Thorsten




Re: [O] OrgStruct: start with collapsed view

2014-11-01 Thread Karl Voit
* Scott Randby  wrote:
> On 10/30/2014 08:41 AM, Thorsten Jolitz wrote:
>> Karl Voit  writes:
>>
>> Not a solution, but an alternative (and an interesting experiment):
>>
>> What if you try navi-mode with your orgstruct init.el? It works with
>> outshine and with org-mode, so maybe with orgstruct too?
>
> I found this on http://orgmode.org/worg/org-tutorials/org-outside-org.html.
>
>"orgstruct currently does NOT work with outorg and navi-mode..."

So maybe I'll test Outshine as well.





Re: [O] Recent startup error in Org

2014-11-01 Thread Mike McLean
More information:

Git Bisect yields the following:

61a241f0dc07aef5a3a5c2bd037a197236bde2e6 is the first bad commit
commit 61a241f0dc07aef5a3a5c2bd037a197236bde2e6
Author: Nicolas Goaziou 
Date:   Tue Oct 14 10:53:29 2014 +0200

Rewrite setup keywords initialization

* lisp/org-table.el (org-table-set-constants): Remove function.
* lisp/org.el (org-set-regexps-and-options): Rewrite function.  Merge
  it with `org-set-regexps-and-options-for-tags'.
(org-set-regexps-and-options-for-tags): Remove function
(org--setup-collect-keywords, org--setup-process-tags): New functions.
(org-mode): Remove `org-set-regexps-and-options-for-tags' call.
(org-agenda-prepare-buffers): Use optimized setup for tags in all
cases.  Improve docstring.
(org-make-options-regexp): Make returned regexp more efficient.

:04 04 afaa4ae741d1427954081fcbc29ee4a0363e6636
4a2d2634d397a45d3c9528fb1919a6e1a1315430 M lisp


On Fri, Oct 31, 2014 at 5:51 PM, Mike McLean  wrote:

> Hello
>
> I updated to git-head today; my most recent update was about 1 week prior.
> Today I get a startup error in Emacs (Back trace of debug-init below).
>
> Emacs Version: GNU Emacs 24.4.1 (x86_64-apple-darwin13.4.0, NS
> apple-appkit-1265.21) of 2014-10-21 on mac-mike-2013
>
> Org Version: Org-mode version 8.3beta (release_8.3beta-513-gaa1fd6.dirty @
> /Users/mlm/.emacs.d/el-get/org-mode/lisp/)
>
> Debugger entered--Lisp error: (error "Symbol nil may not be buffer-local")
>   make-local-variable(nil)
>   org-set-regexps-and-options()
>   org-mode()
>   set-auto-mode-0(org-mode nil)
>   set-auto-mode()
>   normal-mode(t)
>   after-find-file(nil t)
>   find-file-noselect-1(#
> "~/Documents/OrgMaster/org/break-tracking.org" nil nil
> "~/Documents/OrgMaster/org/break-tracking.org" (259606255 16777220))
>   find-file-noselect("/Users/mlm/Documents/OrgMaster/org/
> break-tracking.org")
>   #[(f) "\301\302 \"\210\303 !\207" [f message "Opening Org mode file: %s"
> find-file-noselect] 3]("/Users/mlm/Documents/OrgMaster/org/
> break-tracking.org")
>   mapc(#[(f) "\301\302 \"\210\303 !\207" [f message "Opening Org mode
> file: %s" find-file-noselect] 3]
> ("/Users/mlm/Documents/OrgMaster/financial-notes/Financial-Notes.org"
> "/Users/mlm/Documents/OrgMaster/Library-eReader-Device-Support/Library-eReader-Device-Recommendation.org"
> "/Users/mlm/Documents/OrgMaster/Life_Planning/Life_Plan.org"
> "/Users/mlm/Documents/OrgMaster/MaaS360/MaaS360-for-Mobile-Development.org"
> "/Users/mlm/Documents/OrgMaster/MaaS360/MaaS360.org"
> "/Users/mlm/Documents/OrgMaster/Macintosh-Vision-Goals-Strategy/Macintosh-Vision-Goals-Strategy.org"
> "/Users/mlm/Documents/OrgMaster/Mobile-Vision-Goals-Strategy/Mobile-Vision-Goals-Strategy.org"
> "/Users/mlm/Documents/OrgMaster/org/Agile_Results.org"
> "/Users/mlm/Documents/OrgMaster/org/BCBSFL/BCBSFL-Journal.org"
> "/Users/mlm/Documents/OrgMaster/org/BCBSFL/Bulletproof_Configuration_Security_Vulnerability_Remediation.org"
> "/Users/mlm/Documents/OrgMaster/org/BCBSFL/Caretaker_of_Sustainable_Macintosh_Ecosystem.org"
> "/Users/mlm/Documents/OrgMaster/org/BCBSFL/Florida-Blue-Administrative-Overhead.org"
> "/Users/mlm/Documents/OrgMaster/org/BCBSFL/Macintosh_Strategic_Planner_Extraordinaire.org"
> "/Users/mlm/Documents/OrgMaster/org/BCBSFL/Master_of_Mobile_Device_Strategy_and_Support.org"
> "/Users/mlm/Documents/OrgMaster/org/BCBSFL/Provider_of_Superior_Macintosh_Support.org"
> "/Users/mlm/Documents/OrgMaster/org/BCBSFL/Rocket_Propelled_Career.org"
> "/Users/mlm/Documents/OrgMaster/org/BCBSFL/SLT-ipad-tracking.org"
> "/Users/mlm/Documents/OrgMaster/org/break-tracking.org"
> "/Users/mlm/Documents/OrgMaster/org/Commute.org"
> "/Users/mlm/Documents/OrgMaster/org/Effective-and-Efficient.org"
> "/Users/mlm/Documents/OrgMaster/org/from-mobile.org"
> "/Users/mlm/Documents/OrgMaster/org/Health-Fitness-Vitality.org"
> "/Users/mlm/Documents/OrgMaster/org/Home-Technology.org"
> "/Users/mlm/Documents/OrgMaster/org/Journal.org"
> "/Users/mlm/Documents/OrgMaster/org/Julie.org"
> "/Users/mlm/Documents/OrgMaster/org/Learn-Everything.org"
> "/Users/mlm/Documents/OrgMaster/org/Montu.org"
> "/Users/mlm/Documents/OrgMaster/org/Outstanding-Marriage.org"
> "/Users/mlm/Documents/OrgMaster/org/PamperedChef.org"
> "/Users/mlm/Documents/OrgMaster/org/Personal-Administrative-Overhead.org"
> "/Users/mlm/Documents/OrgMaster/org/refile.org"
> "/Users/mlm/Documents/OrgMaster/org/Toastmasters.org"
> "/Users/mlm/Documents/OrgMaster/Periodic-Reporting/background.org"
> "/Users/mlm/Documents/OrgMaster/Periodic-Reporting/Periodic-Report.org"
> "/Users/mlm/Documents/OrgMaster/Twinleaf_HOA/Twinleaf-Administrative-Overhead.org"
> "/Users/mlm/Documents/OrgMaster/Twinleaf_HOA/Twinleaf-Journal.org"
> "/Users/mlm/Documents/OrgMaster/Twinleaf_HOA/Twinleaf-Operations.org"
> "~/.init/emacs/emacs-init.org" "~/.init/emacs/org-init.org"))
>   byte-code("\302\303\304\"\210\305 \306\307 \"\207" [org-feed-alist
> org-agenda-files add-to-list org-export-fi

Re: [O] Confirmed: Endless loop in org--setup-collect-keywords caused by commit 61a241f

2014-11-01 Thread Karl Voit
* Kyle Meyer  wrote:
> Hello,

Hi!

> Karl Voit  wrote:
> [...]
>> Do you have a clue if my update or my re-arrangement of my init.el
>> could have caused this?
>
> I'd guess this is related to commit 61a241f (because that is the commit
> that introduced org--setup-collect-keywords and because I'm seeing
> hanging that may be related [1]). You could checkout the commit before
> (0b74864) and see if you still get the issue.
>
> [1] http://article.gmane.org/gmane.emacs.orgmode/92245

I can confirm this assumption.

And I also have file-local tags defined as in [1] and this file got
issues when being opened.

Thanks for the pointer!

Is Nicolas already following this thread? :-)


Greetings from Graz/Austria!