Re: [O] Modifications in org-src.el
Hello, Rasmus ras...@gmx.us writes: I don't know if this is a bug, but when I open Emacs and open a buffer without (require 'ox) first, org-element will not recognize export-blocks. This is a known limitation: export blocks are not recognized until the corresponding back-end is loaded. The solution is to create a dedicated syntax for export blocks so they cannot be confused with special blocks. This was discussed in another thread (http://permalink.gmane.org/gmane.emacs.orgmode/88945). Regards, -- Nicolas Goaziou
Re: [O] Modifications in org-src.el
Hello Nicolas, I also added export block sub-editing. Could you elaborate on this? What do you mean exactly? Just a couple of words... Best regards, Seb -- Sebastien Vauban
[O] [bug] YASnippet (bound to SPC) and Org in `master'
Hello, In Org `master' (not in `maint'), there is a bug (or conflict or ???) when one binds `yas-expand' to SPC (the abbrev-way), as in the following minimal Emacs configuration file: --8---cut here---start-8--- ;; Autoloads. (add-to-list 'load-path ~/.emacs.d/elpa/yasnippet-20141117.327) (load-library yasnippet-autoloads) ;; Enable YASnippet in all buffers. (yas-global-mode 1) ;; Bind yas-expand to SPC (abbrev-way). (define-key yas-minor-mode-map (kbd SPC) 'yas-expand) --8---cut here---end---8--- With the above config, typing SPC after any word in any Org table cell deletes the whole contents of the cell... [1] When typing, for example, Every word gets deleted on pressing SPC..., you successively only see Every, then word, then gets, ..., and then finally SPC... as the cell contents! Searching for the difference between `maint' and `master' shows that the problem occurs since the following commit in `master': --8---cut here---start-8--- e8b51c0ce5d6dbd5f2c6cfff2d260a3f5f7ac58f is the first bad commit commit e8b51c0ce5d6dbd5f2c6cfff2d260a3f5f7ac58f Author: Bastien Guerry b...@altern.org Date: Mon Jul 28 17:28:54 2014 +0200 org.el (org-self-insert-command): Use `yas-expand' * org.el (org-self-insert-command): Use `yas-expand' as yas/expand is obsolete since Yasnippet 0.8. Thanks to Craig Tanis for reporting this. :04 04 203e5106edcfa9d9809cae034e9f551819f75941 a43fde57dd3143ddd91b932f6634bb09c7857708 M lisp --8---cut here---end---8--- Best regards, Seb [1] Demo on http://screencast.com/t/KKKCQJYo. -- Sebastien Vauban
Re: [O] [PATCH] inline src block results can be removed
On 2014-11-17 00:23, Nicolas Goaziou wrote: Charles C. Berry writes: For now, I'd be willing to make patches that will allow removal of the inline src block results that do *not* involve these header args: [] IMO, we're too much focused on the implementation details. We ought to agree on what should be done first. For example, considering `org-babel-insert-result' and its RESULT-PARAMS argument, I think the following makes sense: | Param | Example output| |-+---| | default | {{{results(42)}}} | | file| {{{results(file:something.pdf)}}} | | list| | | raw | 42| | drawer | | | org | {{{results(src_org{...})}}} | | html| {{{results(@@html:...@@)}}} | | latex | {{{results(@@latex:...@@)}}} | | code| {{{results(src_xxx{...})}}} | Basically, it should be possible to remove any kind of result using results macro, with the exception of raw. list and drawer can be ignored since there is no inline equivalent. [] There's no rush, however. Non-removable results from inline source blocks have been there for a long time. Hello all, I jump into this conversation because in the next months I will try to write a supplementary information annex using org-mode with Gnu R, so my idea on what should be done follows... I guess I will start my project using those patches. Thanks! A brief review on how how results are presented (or usually anticipated) inline led me to the following wish list: * provide some facilities to keep track of the 'unit of measurement' Few numbers are pure numbers. There is a little value added to the correctness of the work as a whole if I get the correct number from babel but I have hard coded the wrong unit of measure in the text. Please follow the examples. # Load used languages #+BEGIN_SRC emacs-lisp (org-babel-do-load-languages 'org-babel-load-languages '((emacs-lisp . nil) (octave . t) (R . t))) #+END_SRC Ideally, I think that reasonable solution would take table like the following: #+TBLNAME:speed-1 | speed | speed_unit | |---+| |12 | km/s | and output by default or through an easy to call syntax: #+BEGIN_EXAMPLE 12 km/s #+END_EXAMPLE I am not aware of any facilities provided by languages like R or octave to keep track of the unit of measure, If you have some please share. A more space wise representation, that add another layer of indirection would be to have a look-up table like the following: #+TBLNAME:speed-1-units-lookup | name | unit | |+--| | speed | km/s | | length | km | | time | s| But I am not sure that it's worth it, at least for those that are working with small data sets. * support for inline rendering of tables The most complex inline output I think I will need at some point follows: #+TBLNAME:data-set-1 #+NAME:data-set-1 | position | item1 | author1 | item2 | author2 | correlation | |--+---+-+---+-+-| |1 | i1| a1 | j1| b1 | c1 | |2 | i2| a2 | j2| b2 | c2 | |3 | i3| a3 | j3| b3 | c3 | #+NAME: block-1 #+BEGIN_SRC R :session :colnames yes :exports none :var data_set_1=data-set-1 # Just to show that we use R data_set_2 - data_set_1 #+END_SRC #+RESULTS: block-1 | position | item1 | author1 | item2 | author2 | correlation | |--+---+-+---+-+-| |1 | i1| a1 | j1| b1 | c1 | |2 | i2| a2 | j2| b2 | c2 | |3 | i3| a3 | j3| b3 | c3 | And I really like to be easily rendered as an inline string through some formatting specs e.g.: #+BEGIN_EXAMPLE #+PROPERTY: header-args: R :fmt '(%(position)i) “%(item1)s” by /%(author1)s/ correlate to “%(item2)s” by /%(author2)s/ with a correlation coefficient of %(correlation).2f' #+PROPERTY: header-args: R :rowsep (', ', ' and ') The preliminary results show that: src_R[:session :results replace]{data_set_2}. #+END_EXAMPLE Will be rendered as: #+BEGIN_org The preliminary results show that: (1) “i1” by /a1/ correlate to “j1” by /b1/ with a correlation coefficient of c1, (2) “i2” by /a2/ correlate to “j2” by /b2/ with a correlation coefficient of c2 and (3) “i3” by /a3/ correlate to “j3” by /b3/ with a correlation coefficient of c3. #+END_org For languages that does not support tables with headers we can stick with the positional formatting: #+NAME: block-2 #+BEGIN_SRC octave :session :colnames yes :exports none :var data_set_1=data-set-1 ans = data_set_1; #+END_SRC # TODO: figure out why this does not work #+RESULTS: block-2 : iii123aaa123jjj123bbb123ccc123 #+BEGIN_EXAMPLE #+PROPERTY: header-args: octave :fmt '(%i)
Re: [O] [PATCH] inline src block results can be removed
Hi Daniele, I think your wishlist is somewhere further down the road. I usually implement some of your points in the src_language. I see that it would be nice if org supported these use cases, but I would see them as part of the LOB or maybe in some package in contrib rather than in core org/babel. For that, I'd argue removable inline results that can be exported without special formatting would be all that is needed to support your wishlist. A few inline comments below. Daniele Pizzolli d...@toel.it writes: On 2014-11-17 00:23, Nicolas Goaziou wrote: Charles C. Berry writes: For now, I'd be willing to make patches that will allow removal of the inline src block results that do *not* involve these header args: [] IMO, we're too much focused on the implementation details. We ought to agree on what should be done first. For example, considering `org-babel-insert-result' and its RESULT-PARAMS argument, I think the following makes sense: | Param | Example output| |-+---| | default | {{{results(42)}}} | | file| {{{results(file:something.pdf)}}} | | list| | | raw | 42| | drawer | | | org | {{{results(src_org{...})}}} | | html| {{{results(@@html:...@@)}}} | | latex | {{{results(@@latex:...@@)}}} | | code| {{{results(src_xxx{...})}}} | Basically, it should be possible to remove any kind of result using results macro, with the exception of raw. list and drawer can be ignored since there is no inline equivalent. [] There's no rush, however. Non-removable results from inline source blocks have been there for a long time. Hello all, I jump into this conversation because in the next months I will try to write a supplementary information annex using org-mode with Gnu R, so my idea on what should be done follows... I guess I will start my project using those patches. Thanks! A brief review on how how results are presented (or usually anticipated) inline led me to the following wish list: * provide some facilities to keep track of the 'unit of measurement' Few numbers are pure numbers. There is a little value added to the correctness of the work as a whole if I get the correct number from babel but I have hard coded the wrong unit of measure in the text. Please follow the examples. # Load used languages #+BEGIN_SRC emacs-lisp (org-babel-do-load-languages 'org-babel-load-languages '((emacs-lisp . nil) (octave . t) (R . t))) #+END_SRC Ideally, I think that reasonable solution would take table like the following: #+TBLNAME:speed-1 | speed | speed_unit | |---+| |12 | km/s | and output by default or through an easy to call syntax: #+BEGIN_EXAMPLE 12 km/s #+END_EXAMPLE I am not aware of any facilities provided by languages like R or octave to keep track of the unit of measure, If you have some please share. A more space wise representation, that add another layer of indirection would be to have a look-up table like the following: #+TBLNAME:speed-1-units-lookup | name | unit | |+--| | speed | km/s | | length | km | | time | s| I usually have an even more elaborate legend table like | name | display | unit | |--+-+--| | sp | speed | km/s | | le | length | km | | ti | time| s| And sometimes even (some) translation support: | name | display | de | unit | |--+-+-+--| | sp | speed | Geschwindigkeit | km/s | | le | length | Länge | km | | ti | time| Zeit| s| Only the table is in org, the handling is done not by org, but in R. But I am not sure that it's worth it, at least for those that are working with small data sets. * support for inline rendering of tables The most complex inline output I think I will need at some point follows: #+TBLNAME:data-set-1 #+NAME:data-set-1 | position | item1 | author1 | item2 | author2 | correlation | |--+---+-+---+-+-| |1 | i1| a1 | j1| b1 | c1 | |2 | i2| a2 | j2| b2 | c2 | |3 | i3| a3 | j3| b3 | c3 | #+NAME: block-1 #+BEGIN_SRC R :session :colnames yes :exports none :var data_set_1=data-set-1 # Just to show that we use R data_set_2 - data_set_1 #+END_SRC #+RESULTS: block-1 | position | item1 | author1 | item2 | author2 | correlation | |--+---+-+---+-+-| |1 | i1| a1 | j1| b1 | c1 | |2 | i2| a2 | j2| b2 | c2 | |3 | i3| a3 | j3| b3 | c3 | And I really
Re: [O] Patch org-capture-set-target-location
Sorry for make you lose your time. Using the package version of 20141124 of org, the bug is present, but in the git master, it's solved in a nicer way. By in the org-capture-place-entry function getting out of the cond the test of :exact-position Package version: (cond ((org-capture-get :exact-position) (goto-char (org-capture-get :exact-position))) ((not target-entry-p) Git Master version: (and (org-capture-get :exact-position) (goto-char (org-capture-get :exact-position))) (cond ((not target-entry-p) Thank you very much. On Sun, Nov 23, 2014 at 7:15 PM, Nicolas Goaziou m...@nicolasgoaziou.fr wrote: Hello, Roberto Huelga rhue...@gmail.com writes: Patch proposal for org-capture-set-target-location Thanks for the patch. The idea is that when somebody use the function or file+function targets you can make the template subheading from the heading where the custom-function set the point. org-capture-set-target-loction force the org-capture-plist :exact-position to (point). So the template is inserted in the same level not as subheading With my patch the custom-function can (org-capture-put :exact-position nil), and now if point its placed in a heading the template is created as his subheading. AFAIU, :exact-position is an internal property (it isn't documented in (info (org) Template elements). You are not expected to set it directly. After a cursory look into org-capture.el, if (point) is on a headline, the template should create a subheading (see `org-capture-place-entry'). Can't you use that instead? Regards, -- Nicolas Goaziou
Re: [O] [PATCH] inline src block results can be removed
On 2014-11-24 11:18, Andreas Leha wrote: Hi Daniele, I think your wishlist is somewhere further down the road. I usually implement some of your points in the src_language. I see that it would be nice if org supported these use cases, but I would see them as part of the LOB or maybe in some package in contrib rather than in core org/babel. For that, I'd argue removable inline results that can be exported without special formatting would be all that is needed to support your wishlist. Hi Andreas, sure, I think I will start getting the string I needed from src_language. But in some language is really hard to get facilities for text manipulation while the output as table generally supported. And I also think that the fine grained control of the layout of the inline sentence pertains to the org layer. A few inline comments below. Thanks again, they are really a nice help to start with! Best, Daniele
Re: [O] Bug: [Capture] wrongly duplicated date tree outlines [8.2.10]
On Sunday, 23 Nov 2014 at 23:52, kuanyui wrote: So sorry to everyone, I just found this is problem is caused by `pangu-spacing'. https://github.com/coldnew/pangu-spacing/issues/5 I notice that there has been a response to your issue. As well as that response, I wonder whether setting the pangu-spacing-real-insert-separator for org mode files would solve your problem as well? Mind you, you might not want to have the space inserted... From an org point of view, I am surprised that org-capture has a problem if the space is not actually there. Is the original date inserted in the datetree hierarchy inserted by org or by you? If org, I would have thought that it would find the same heading later when inserting again. -- : Eric S Fraga (0xFFFCF67D), Emacs 24.4.1, Org release_8.3beta-589-g9eff31.dirty
Re: [O] Beamer export, file-link format
On Sunday, 23 Nov 2014 at 22:05, James Harkins wrote: I'm using org + beamer, and I've put in some links like this: \href{media/something.mp3}{Listen: Something} I want Listen: Something to appear in another color. LaTeX is steadfastly refusing to do this: all links appear in the normal document font and color. Hyperref is invoked in the preamble like so: \usepackage{hyperref} Have you tried adding the colorlinks=true option and/or setting the linkcolor=red (say)? -- : Eric S Fraga (0xFFFCF67D), Emacs 24.4.1, Org release_8.3beta-589-g9eff31.dirty
[O] [export] latex: texorpdfstring in heading
Hi all, Background: I am always loading the hyperref package in my latex exports. That one complains (warns) about math in headings. (Token not allowed in a PDF string) The proposed solution in LaTeX is to use \texorpdfstring{}{}. I've used that successfully in the past also from org. As it seems that stopped working as the {}{} get escaped now during export. So, here is my question: How do I use \texorpdfstring correctly in an org heading? And here is a minimal example: --8---cut here---start-8--- #+latex_header: \usepackage{hyperref} * This contains \texorpdfstring{$\prod_{k=1}^N$}{product 1toN} math For some reason. --8---cut here---end---8--- which exports to --8---cut here---start-8--- \section{This contains \texorpdfstring\{\$\(\prod_{\text{k=1}}^{\text{N}}\)\$\}\{product 1toN\} math} \label{sec-1} For some reason. --8---cut here---end---8--- Thanks, Andreas
[O] Is #+SEQ_TODO: TODO | legal?
Hi there, for some reason I want to have a TODO item that /cannot/ be (directly, by C-c C-t) made into a done state. It seems that #+SEQ_TODO: TODO | works. Is that legal? TIA, -- Marcin Borkowski http://octd.wmi.amu.edu.pl/en/Marcin_Borkowski Faculty of Mathematics and Computer Science Adam Mickiewicz University
[O] How to represent Emacs keystrokes in Org?
Hello, I'm writing (in Org) a text on Emacs usage. How to correctly/canonically represent keystrokes, like C-x RET f? Currently, I use =C-x RET f=; are there any alternatives? TIA, -- Marcin Borkowski http://octd.wmi.amu.edu.pl/en/Marcin_Borkowski Faculty of Mathematics and Computer Science Adam Mickiewicz University
Re: [O] [export] latex: texorpdfstring in heading
Hello, Andreas Leha andreas.l...@med.uni-goettingen.de writes: So, here is my question: How do I use \texorpdfstring correctly in an org heading? And here is a minimal example: #+latex_header: \usepackage{hyperref} * This contains \texorpdfstring{$\prod_{k=1}^N$}{product 1toN} math For some reason. * This contains @@latex:\texorpdfstring{$\prod_{k=1}^N$}{product 1toN}@@ math Regards, -- Nicolas Goaziou
Re: [O] Modifications in org-src.el
Hello, Sebastien Vauban sva-news-D0wtAvR13HarG/idocf...@public.gmane.org writes: I also added export block sub-editing. Could you elaborate on this? What do you mean exactly? Just a couple of words... You can use C-c ' in #+begin_latex...#+end_latex blocks and alike. Regards, -- Nicolas Goaziou
Re: [O] Is #+SEQ_TODO: TODO | legal?
Hello, Marcin Borkowski mb...@wmi.amu.edu.pl writes: for some reason I want to have a TODO item that /cannot/ be (directly, by C-c C-t) made into a done state. It seems that #+SEQ_TODO: TODO | works. Is that legal? It may seem to work, but you are probably going to run into subtle problems. The TODO/DONE code expects both a TODO and a DONE states. Reconsider your reason! Regards, -- Nicolas Goaziou
Re: [O] Export backends are loaded after code block evaluation
Nope, no harm has been done. Still curious about it though. IMO, there's no reference to 'ox.el' in the babel source files so I don't understand how is this possible. 2014-11-23 13:36 GMT-03:00 Nicolas Goaziou m...@nicolasgoaziou.fr: Hello, Vicente Vera vicente...@gmail.com writes: Hello. Just noticed that after evaluating a code block with C-c C-c (org-babel-execute-src-block?) all export backends stored in 'org-export-backends' are loaded---or 'required'---automatically. Once I commented out my 'org-export-backends' setup those backends weren't loaded, but the default ones did (ascii html icalendar latex). Is this the intended behavior? `org-babel-execute-src-block' probably requires ox.el or some back-end, triggering. Back-ends are loaded as soon as ox.el is required. Tried to grep my way through Org's source files looking for a clue with no success. Also, is there a way to prevent this from happening? It doesn't seem extremely necessary to me. It doesn't really hurt either. Regards, -- Nicolas Goaziou
Re: [O] How to represent Emacs keystrokes in Org?
Marcin Borkowski mb...@wmi.amu.edu.pl writes: Hello, I'm writing (in Org) a text on Emacs usage. How to correctly/canonically represent keystrokes, like C-x RET f? Currently, I use =C-x RET f=; are there any alternatives? That's what I'd do. Or ~C-x RET f~. You could also use a macro, if you want it to me be more semantic (I hope I use this word correctly). Cheers, Rasmus -- ⠠⠵
Re: [O] Export backends are loaded after code block evaluation
Vicente Vera vicente...@gmail.com writes: Nope, no harm has been done. Still curious about it though. IMO, there's no reference to 'ox.el' in the babel source files so I don't understand how is this possible. See line 848 in org.el (master branch, if it matters). Basically, Babel requires an export backend (ox-latex.el, likely), which, in turn requires ox.el. The snippet above does the rest. Regards,
Re: [O] Modifications in org-src.el
Hello Nicolas, Sebastien Vauban writes: I also added export block sub-editing. Could you elaborate on this? What do you mean exactly? Just a couple of words... You can use C-c ' in #+begin_latex...#+end_latex blocks and alike. OK, much clearer (to me) now! Thanks for that feature. Best regards, Seb -- Sebastien Vauban
Re: [O] [export] latex: texorpdfstring in heading
Hi Nicolas, Nicolas Goaziou m...@nicolasgoaziou.fr writes: Hello, Andreas Leha andreas.l...@med.uni-goettingen.de writes: So, here is my question: How do I use \texorpdfstring correctly in an org heading? And here is a minimal example: #+latex_header: \usepackage{hyperref} * This contains \texorpdfstring{$\prod_{k=1}^N$}{product 1toN} math For some reason. * This contains @@latex:\texorpdfstring{$\prod_{k=1}^N$}{product 1toN}@@ math That should have occurred to me as well. Ähem. Thank you very much for the quick answer! Regards, Andreas
Re: [O] [export] latex: texorpdfstring in heading
On Monday, 24 Nov 2014 at 15:16, Andreas Leha wrote: [...] So, here is my question: How do I use \texorpdfstring correctly in an org heading? #+latex_header: \usepackage{hyperref} * This contains \texorpdfstring{$\prod_{k=1}^N$}{product 1toN} math For some reason. Use the @@latex:xxx@@ directive, as in * This contains @@latex:\texorpdfstring{$\prod_{k=1}^N$}{product 1toN}@@ math -- : Eric S Fraga (0xFFFCF67D), Emacs 24.4.1, Org release_8.3beta-558-g83d8a2
[O] [PATCH] Improve success message from org-remove-file.
The attached patch improves the interactive success message from `org-remove-file'. Comments / suggestions welcome, of course; I've tried to follow http://orgmode.org/worg/org-contribute.html here. Best, -Karl From 846d66a15c73a336c110f5238307242f9192e8c3 Mon Sep 17 00:00:00 2001 From: Karl Fogel kfo...@red-bean.com Date: Mon, 24 Nov 2014 11:32:42 -0600 Subject: [PATCH] org.el: Improve accuracy of message * lisp/org.el (org-remove-file): Reword success message. Before this change, when `org-remove-file' succeeded in removing a file from `org-agenda-files', it would display this unduly alarming message to the user: Removed file: foo.org. This made it seem as though the file itself were removed from the filesystem, rather than simply being delisted from `org-agenda-files'. After this change, the message Removed from Org Agenda list: foo.org is displayed instead, so the user will experience only the normal level of panic involved in using Org Mode, not the increased panic that results from thinking a file has been removed when it hasn't. --- lisp/org.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/org.el b/lisp/org.el index 38c5726..9372191 100755 --- a/lisp/org.el +++ b/lisp/org.el @@ -18465,7 +18465,7 @@ Optional argument FILE means use this file instead of the current. (progn (org-store-new-agenda-file-list files) (org-install-agenda-files-menu) - (message Removed file: %s afile)) + (message Removed from Org Agenda list: %s afile)) (message File was not in list: %s (not removed) afile (defun org-file-menu-entry (file) -- 2.1.3
Re: [O] Export backends are loaded after code block evaluation
Ok, finally sorted it out. Babel doesn't load ox-* files by itself (except for ob-haskell ob-latex). But, in my case, the code block's result is a table. In consequence Org needs org-table which in turn requires some ox- files and THEN org.el evaluates (after ox.el) 'org-export-backends'. Thank you for your patience. Now I can sleep soundly. 2014-11-24 16:42 GMT-03:00 Nicolas Goaziou m...@nicolasgoaziou.fr: Vicente Vera vicente...@gmail.com writes: Nope, no harm has been done. Still curious about it though. IMO, there's no reference to 'ox.el' in the babel source files so I don't understand how is this possible. See line 848 in org.el (master branch, if it matters). Basically, Babel requires an export backend (ox-latex.el, likely), which, in turn requires ox.el. The snippet above does the rest. Regards,
Re: [O] [export] latex: texorpdfstring in heading
Hi Eric, Eric S Fraga e.fr...@ucl.ac.uk writes: On Monday, 24 Nov 2014 at 15:16, Andreas Leha wrote: [...] So, here is my question: How do I use \texorpdfstring correctly in an org heading? #+latex_header: \usepackage{hyperref} * This contains \texorpdfstring{$\prod_{k=1}^N$}{product 1toN} math For some reason. Use the @@latex:xxx@@ directive, as in * This contains @@latex:\texorpdfstring{$\prod_{k=1}^N$}{product 1toN}@@ math Thank you very much! That should have been obvious to me as well... (It seems that you sent your reply even earlier than Nicolas -- unfortunately I only just saw it now appearing on the list) Thanks, Andreas
Re: [O] Customize org-todo-repeat-to-state to return to previous TODO state
Great, thanks for all the excellent advice and code! I decided to approach this locally with a capture template and put my repeating APPT tasks under my Calendar headline. I created this capture template that does the job: (setq org-capture-templates '((c Calendar entry (file+headline ~/grantMain.org Calendar) * APPT %?\n%i\n%a\n:PROPERTIES:\n:REPEAT_TO_STATE: APPT\n:END:\n :prepend t))) Grant On Fri, Nov 21, 2014 at 1:56 PM, Brady Trainor algeb...@uw.edu wrote: Grant Schissler grant.schiss...@gmail.com writes: Hi Org-mode Users, I am trying to change the behavior of marking a repeated task as DONE. I would like the task to return to the current TODO state rather than the first in the TODO sequence or a fixed state. For example, ** APPT Lunch with Mallorie 2014-12-04 Thu 12:00 +1w should return to APPT, not TODO or some other predefined state as in the current behavior: TODO Lunch with Mallorie - State DONE from APPT [2014-11-21 Fri 10:56] 2014-12-11 Thu 12:00 +1w I am sure that customizing the org-todo-repeat-to-state will do the trick, but sadly, I have had the time to learn elisp well enough to perform this. Any help would be much appreciated. Please let me know if you have questions. Thanks for the support and to all those that make org-mode great! Grant I haven't tried any of the following, and there may be better solutions, but... It looks like the variable you mention reads as (via C-h v org-todo-repeat-to-state RET and follow link to source), #+BEGIN_SRC emacs-lisp (defcustom org-todo-repeat-to-state nil The TODO state to which a repeater should return the repeating task. By default this is the first task in a TODO sequence, or the previous state in a TODO_TYP set. But you can specify another task here. alternatively, set the :REPEAT_TO_STATE: property of the entry. :group 'org-todo :version 24.1 :type '(choice (const :tag Head of sequence nil) (string :tag Specific state))) #+END_SRC It looks like this variable will not allow to recall the previous TODO state. But you could make a separate TODO_TYP set. Depending on whether you define your TODO states in an init file or per-file base, you could try an extra line in your org file header, #+BEGIN_SRC org ,#+TYP_TODO: APPT | DONE #+END_SRC or an extra block in your org-todo-keywords variable #+BEGIN_SRC emacs-lisp (setq org-todo-keywords '((type APPT | DONE))) #+END_SRC Another solution according to the above would be to use a property drawer, #+BEGIN_SRC org ,** APPT Lunch with Mallorie 2014-12-04 Thu 12:00 +1w :PROPERTIES: :REPEAT_TO_STATE: APPT :END: #+END_SRC You can get this via C-c C-x p repeat_to_state RET APPT RET. Interestingly, there is a function in the same source file, org-auto-repeat-maybe, which suggests that it does exactly what you ask for. #+BEGIN_EXAMPLE org-auto-repeat-maybe is a compiled Lisp function in `org.el'. (org-auto-repeat-maybe DONE-WORD) Check if the current headline contains a repeated deadline/schedule. If yes, set TODO state back to what it was and change the base date of repeating deadline/scheduled time stamps to new date. This function is run automatically after each state change to a DONE state. [back] #+END_EXAMPLE I can see in the definition of the function it has an expression org-last-state, so maybe that suggests there is a way built-in (or intended to?), but I only took that quick look at the source. -- Brady
[O] Cannot start any agenda anymore
Hi all, since yesterday I cannot start any agenda anymore. I did reorganise a few things but cannot find the reason whats wrong. setting debug to true I get the message below after a standard C-a a t. Please help I am completely stuck. Thank you, Rainer Org-mode version 8.3beta (release_8.3beta-589-g9eff31 @ c:/Users/rainer/AppData/Roaming/.emacs.d/org/lisp/) GNU Emacs 24.3.50.1 (i386-mingw-nt6.1.7601) of 2013-03-14 on VBOX Debugger entered--Lisp error: (wrong-type-argument stringp nil) looking-at(nil) outline-on-heading-p(t) org-at-heading-p() (cond ((eq mode (quote item)) (org-element-item-parser limit structure raw-secondary-p)) ((eq mode (quote table-row)) (org-element-table-row-parser limit)) ((eq mode (quote node-property)) (org-element-node-property-parser limit)) ((let* ((org-called-with-limited-levels t) (org-outline-regexp (org-get-limited-outline-regexp)) (outline-regexp org-outline-regexp) (org-outline-regexp-bol (concat ^ org-outline-regexp))) (org-at-heading-p)) (org-element-headline-parser limit raw-secondary-p)) ((eq mode (quote section)) (org-element-section-parser limit)) ((eq mode (quote first-section)) (org-element-section-parser (or (save-excursion (let* ((org-called-with-limited-levels t) (org-outline-regexp ...) (outline-regexp org-outline-regexp) (org-outline-regexp-bol ...)) (outline-next-heading))) limit))) ((and (eq mode (quote planning)) (looking-at org-planning-line-re)) (org-element-planning-parser limit)) ((and (memq mode (quote (planning property-drawer))) (looking-at org-property-drawer-re)) (org-element-property-drawer-parser limit)) ((not (bolp)) (org-element-paragraph-parser limit (list (point ((looking-at org-clock-line-re) (org-element-clock-parser limit)) ((org-at-heading-p) (org-element-inlinetask-parser limit raw-secondary-p)) (t (let ((affiliated (org-element--collect-affiliated-keywords limit))) (cond ((and (cdr affiliated) (= (point) limit)) (goto-char (car affiliated)) (org-element-keyword-parser limit nil)) ((looking-at org-element--latex-begin-environment) (org-element-latex-environment-parser limit affiliated)) ((looking-at org-drawer-regexp) (org-element-drawer-parser limit affiliated)) ((looking-at [ ]*:\\( \\|$\\)) (org-element-fixed-width-parser limit affiliated)) ((looking-at [ ]*#) (goto-char (match-end 0)) (cond ((looking-at \\(?: \\|$\\)) (beginning-of-line) (org-element-comment-parser limit affiliated)) ((looking-at \\+BEGIN_\\(\\S-+\\)) (beginning-of-line) (let ... ...)) ((looking-at \\+CALL:) (beginning-of-line) (org-element-babel-call-parser limit affiliated)) ((looking-at \\+BEGIN:? ) (beginning-of-line) (org-element-dynamic-block-parser limit affiliated)) ((looking-at \\+\\S-+:) (beginning-of-line) (org-element-keyword-parser limit affiliated)) (t (beginning-of-line) (org-element-paragraph-parser limit affiliated ((looking-at org-footnote-definition-re) (org-element-footnote-definition-parser limit affiliated)) ((looking-at [ ]*-\\{5,\\}[]*$) (org-element-horizontal-rule-parser limit affiliated)) ((looking-at %%() (org-element-diary-sexp-parser limit affiliated)) ((org-at-table-p t) (org-element-table-parser limit affiliated)) ((looking-at (org-item-re)) (org-element-plain-list-parser limit affiliated (or structure (org-element--list-struct limit (t (org-element-paragraph-parser limit affiliated)) (let ((case-fold-search t) (raw-secondary-p (and granularity (not (eq granularity (quote object)) (cond ((eq mode (quote item)) (org-element-item-parser limit structure raw-secondary-p)) ((eq mode (quote table-row)) (org-element-table-row-parser limit)) ((eq mode (quote node-property)) (org-element-node-property-parser limit)) ((let* ((org-called-with-limited-levels t) (org-outline-regexp (org-get-limited-outline-regexp)) (outline-regexp org-outline-regexp) (org-outline-regexp-bol (concat ^ org-outline-regexp))) (org-at-heading-p)) (org-element-headline-parser limit raw-secondary-p)) ((eq mode (quote section)) (org-element-section-parser limit)) ((eq mode (quote first-section)) (org-element-section-parser (or (save-excursion (let* (... ... ... ...) (outline-next-heading))) limit))) ((and (eq mode (quote planning)) (looking-at org-planning-line-re)) (org-element-planning-parser limit)) ((and (memq mode (quote (planning property-drawer))) (looking-at org-property-drawer-re)) (org-element-property-drawer-parser limit)) ((not (bolp)) (org-element-paragraph-parser limit (list (point ((looking-at org-clock-line-re) (org-element-clock-parser limit)) ((org-at-heading-p) (org-element-inlinetask-parser limit raw-secondary-p)) (t (let ((affiliated (org-element--collect-affiliated-keywords limit))) (cond ((and (cdr affiliated) (= ... limit)) (goto-char (car affiliated)) (org-element-keyword-parser limit nil)) ((looking-at org-element--latex-begin-environment) (org-element-latex-environment-parser limit affiliated)) ((looking-at org-drawer-regexp)