[O] [PATCH] Add support for ordered list to ox-confluence.el

2016-12-08 Thread Lungang Fang
Hi there,

Attached is a patch for contrib/lisp/ox-confluence.el generated following
instructions on http://orgmode.org/worg/org-contribute.html#patches . It
adds support for ordered list.

I didn't find where I should send this patch. Hopefully, this is the
correct email list for patch request. If it is not, could anyone please
tell me the correct way to submit a patch request to org-mode?

Regards,
-- 
Lungang Fang


0001-ox-confluence.el-Add-support-for-ordered-list.patch
Description: Binary data


[O] Bug with Habits and Active Dates

2016-12-08 Thread craven
Hello!

I have run into problems with a TODO entry that has a body which
contains an active date. Finishing it results in

Entry repeats: SCHEDULED: <2016-12-13 Tue +1w>

being printed to *Messages*, but no actual new SCHEDULED line is added
to the entry.

See the attached org-file. If I remove the active date, things work
fine. If I put the date into a table, it is still broken.

Thanks for any help with this!

Greetings, Peter
#+TODO: TODO(t) | DONE(d!/!)
* TODO test
  SCHEDULED: <2016-12-06 Tue +1w>
<2016-12-06 Tue>


Re: [O] Fwd: [PATCH] Add support for ordered list to ox-confluence.el

2016-12-08 Thread Charles Durst
They do conflict.  My version is slightly more complicated since it
also supports nested mixed lists.

For example:

1. Here
   * is
   * an
2. example
   * of
   * a
3. mixed
4. list

Which translates to:

# Here
#- is
#- an
# example
#- of
#- a
# mixed
# list

Which is effectively the same as the example in the Confluence documentation:
https://confluence.atlassian.com/confcloud/confluence-wiki-markup-724765099.html#ConfluenceWikiMarkup-Mixedlists
--
Charles Durst
cdu...@alum.rpi.edu


On Thu, Dec 8, 2016 at 5:49 PM, Nicolas Goaziou  wrote:
> Hello,
>
> Lungang Fang  writes:
>
>> Attached is a patch for contrib/lisp/ox-confluence.el generated following
>> instructions on http://orgmode.org/worg/org-contribute.html#patches . It
>> adds support for ordered list.
>
> Thank you.
>
> However, this somewhat conflicts with a patch recently sent on the ML,
> but not yet applied, by Charles Durst (Cc'ed).
>
> Could one double-check if one doesn't supersede the other, or if they
> could be merged (although I suspect the former) and report back so
> I know what patch to apply?
>
> Regards,
>
> --
> Nicolas Goaziou



[O] Bug: s [8.2.10 (release_8.2.10 @ /usr/local/Cellar/emacs/24.5/share/emacs/24.5/lisp/org/)]

2016-12-08 Thread Codievilky August

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

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

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

In my org-mode, I can't use the Key of S-M-RET to set my line to be a
TODO or add checkbox in my mission.I have search a lot in the Internet,
I haven't found any solution to fix this problem.

Emacs  : GNU Emacs 24.5.1 (x86_64-apple-darwin15.2.0)
of 2015-12-20 on elcapitanvm.local
Package: Org-mode version 8.2.10 (release_8.2.10 @ 
/usr/local/Cellar/emacs/24.5/share/emacs/24.5/lisp/org/)

current state:
==
(setq
org-tab-first-hook '(org-hide-block-toggle-maybe
  org-src-native-tab-command-maybe
  org-babel-hide-result-toggle-maybe
  org-babel-header-arg-expand)
org-speed-command-hook '(org-speed-command-default-hook
  org-babel-speed-command-hook)
org-occur-hook '(org-first-headline-recenter)
org-metaup-hook '(org-babel-load-in-session-maybe)
org-confirm-shell-link-function 'yes-or-no-p
org-startup-folded 'showall
org-after-todo-state-change-hook '(org-clock-out-if-current)
org-src-mode-hook '(org-src-babel-configure-edit-buffer
 org-src-mode-configure-edit-buffer)
org-agenda-before-write-hook '(org-agenda-add-entry-text)
org-babel-pre-tangle-hook '(save-buffer)
org-mode-hook '(#[nil "\300\301\302\303\304$\207"
   [org-add-hook change-major-mode-hook org-show-block-all
append local]
   5]
 #[nil "\300\301\302\303\304$\207"
   [org-add-hook change-major-mode-hook
org-babel-show-result-all append local]
   5]
 org-babel-result-hide-spec org-babel-hide-all-hashes
 (lambda nil (setq truncate-lines nil)))
org-ctrl-c-ctrl-c-hook '(org-babel-hash-at-point
  org-babel-execute-safely-maybe)
org-cycle-hook '(org-cycle-hide-archived-subtrees org-cycle-hide-drawers
  org-cycle-hide-inline-tasks org-cycle-show-empty-lines
  org-optimize-window-after-visibility-change)
org-confirm-elisp-link-function 'yes-or-no-p
org-metadown-hook '(org-babel-pop-to-session-maybe)
org-clock-out-hook '(org-clock-remove-empty-clock-drawer)
org-src-fontify-natively t
)





Re: [O] teaching with live-updating code examples

2016-12-08 Thread Eric S Fraga
On Thursday,  8 Dec 2016 at 18:07, Matt Price wrote:
> I am preparing a set of lectures for a class teaching HTML, CSS, and
> javascript ot humanities students.
>
> I would like to have slides with a simple code editor on one side,
> and the results of the code on another:

[...]

> So, I'm looking for other solutions. What do other people do in
> lecture?

I do this all the time with code snippets but I use beamer which
supports columns.  I don't think it's easy to do in reveal.js from
within org, however.

-- 
: Eric S Fraga (0xFFFCF67D), Emacs 26.0.50.1, Org release_9.0.1-49-ga43eac


signature.asc
Description: PGP signature


Re: [O] Fwd: [PATCH] Add support for ordered list to ox-confluence.el

2016-12-08 Thread Charles Durst
I have tried the results of both versions and loaded them into the
Confluence Wiki, and Lungang is correct, from what I can tell, they
both will work.

So I don't really care which one you choose either.  I just needed the
functionality.
--
Charles Durst
cwdurst+orgm...@gmail.com

On Thu, Dec 8, 2016 at 9:32 PM, Lungang Fang  wrote:
> Hi Charles and Nicholas,
>
> My code also supports nested mixed lists but is simpler. I mean, my code
> will convert the list given by Charles to
>
> # Here
> -- is
> -- an
> # example
> -- of
> -- a
> # mixed
> # list
>
> Although this format is not mentioned in confluence wiki, it is supported by
> conflucence according to my test (in Jira).
>
> So, in my opinion, it is a matter of personal preference: more complicated
> code complies with documented interface, or simpler code that exploits
> undocumented feature.
>
> I prefer my code. But you guys feel free to make decision. I am OK with
> whatever you choose.
>
> Cheers,
> Lungang
>
> On Fri, Dec 9, 2016 at 10:37 AM, Charles Durst 
> wrote:
>>
>> They do conflict.  My version is slightly more complicated since it
>> also supports nested mixed lists.
>>
>> For example:
>>
>> 1. Here
>>* is
>>* an
>> 2. example
>>* of
>>* a
>> 3. mixed
>> 4. list
>>
>> Which translates to:
>>
>> # Here
>> #- is
>> #- an
>> # example
>> #- of
>> #- a
>> # mixed
>> # list
>>
>> Which is effectively the same as the example in the Confluence
>> documentation:
>>
>> https://confluence.atlassian.com/confcloud/confluence-wiki-markup-724765099.html#ConfluenceWikiMarkup-Mixedlists
>>
>> --
>> Charles Durst
>> cwdurst+orgm...@gmail.com
>>
>>
>> On Thu, Dec 8, 2016 at 5:49 PM, Nicolas Goaziou 
>> wrote:
>> > Hello,
>> >
>> > Lungang Fang  writes:
>> >
>> >> Attached is a patch for contrib/lisp/ox-confluence.el generated
>> >> following
>> >> instructions on http://orgmode.org/worg/org-contribute.html#patches .
>> >> It
>> >> adds support for ordered list.
>> >
>> > Thank you.
>> >
>> > However, this somewhat conflicts with a patch recently sent on the ML,
>> > but not yet applied, by Charles Durst (Cc'ed).
>> >
>> > Could one double-check if one doesn't supersede the other, or if they
>> > could be merged (although I suspect the former) and report back so
>> > I know what patch to apply?
>> >
>> > Regards,
>> >
>> > --
>> > Nicolas Goaziou
>
>



Re: [O] Fwd: [PATCH] Add support for ordered list to ox-confluence.el

2016-12-08 Thread Lungang Fang
Hi Charles and Nicholas,

My code also supports nested mixed lists but is simpler. I mean, my code
will convert the list given by Charles to

# Here
-- is
-- an
# example
-- of
-- a
# mixed
# list

Although this format is not mentioned in confluence wiki, it is supported
by conflucence according to my test (in Jira).

So, in my opinion, it is a matter of personal preference: more complicated
code complies with documented interface, or simpler code that exploits
undocumented feature.

I prefer my code. But you guys feel free to make decision. I am OK with
whatever you choose.

Cheers,
Lungang

On Fri, Dec 9, 2016 at 10:37 AM, Charles Durst 
wrote:

> They do conflict.  My version is slightly more complicated since it
> also supports nested mixed lists.
>
> For example:
>
> 1. Here
>* is
>* an
> 2. example
>* of
>* a
> 3. mixed
> 4. list
>
> Which translates to:
>
> # Here
> #- is
> #- an
> # example
> #- of
> #- a
> # mixed
> # list
>
> Which is effectively the same as the example in the Confluence
> documentation:
> https://confluence.atlassian.com/confcloud/confluence-wiki-
> markup-724765099.html#ConfluenceWikiMarkup-Mixedlists
>
> --
> Charles Durst
> cwdurst+orgm...@gmail.com
>
>
> On Thu, Dec 8, 2016 at 5:49 PM, Nicolas Goaziou 
> wrote:
> > Hello,
> >
> > Lungang Fang  writes:
> >
> >> Attached is a patch for contrib/lisp/ox-confluence.el generated
> following
> >> instructions on http://orgmode.org/worg/org-contribute.html#patches .
> It
> >> adds support for ordered list.
> >
> > Thank you.
> >
> > However, this somewhat conflicts with a patch recently sent on the ML,
> > but not yet applied, by Charles Durst (Cc'ed).
> >
> > Could one double-check if one doesn't supersede the other, or if they
> > could be merged (although I suspect the former) and report back so
> > I know what patch to apply?
> >
> > Regards,
> >
> > --
> > Nicolas Goaziou
>


Re: [O] org-ref file path to pdf

2016-12-08 Thread John Kitchin
I just pushed a feature that might get you back what you want.

You can now put [[file:%F][%f]] in the org-ref-note-title-format
variable, and it will put (concat org-ref-pdf-directory key ".pdf") in
for %F, and (concat key ".pdf") in for %f. There is unfortunately, no
check if the pdf actually exists though.

A second option is to write a function to add to a new hook variable:
org-ref-create-notes-hook

There is an example function in that that adds a cite link (which can
open a pdf), but if you wanted to you could write a function that would
add a file link to a pdf if it could find one.

I hope those help.

Georg W. Otto writes:

> John Kitchin  writes:
>
>> This doesn't sound like something that should be happening I think. How
>> current is your org-ref?
>>
>> I do not use the notes feature so it does not get tested too often. You
>> may be able to control the format of the notes created with the variable
>> org-ref-note-title-format if you are using the default notes function
>> that adds a headline. 
>>
>>
>
> my org ref version was 20160503 from elpa. I updated it to 20161129 and
> here the part of org-ref-open-bibtex-notes that inserts a link to the
> pdf is commented out. However I like this functionality, so I keep the
> older version of org-ref-open-bibtex-notes in my init file.
>
> Sorry about asking about a functionality that has been removed, but I
> still do not understand why it it does expand my ~/dir to
> /home/user/dir.
>
> My org-ref-open-bibtex-notes is set to adaptive.
>
> It might happen here, but I do not understand elisp enough to tell:
>
> (setq pdf (-first 'f-file?
> (--map (f-join it (concat key ".pdf"))
>(-flatten (list org-ref-pdf-directory)
>
> (if (file-exists-p pdf)
> (insert (format
>" [[file:%s][pdf]]\n\n"
>pdf)))
>
>
> Cheers,
>
> Georg


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



Re: [O] writing letters using the latex letters class?

2016-12-08 Thread Eric S Fraga
On Thursday,  8 Dec 2016 at 11:40, Stig Brautaset wrote:

[...]

> It looks promising but I can't get it to work as I expect; is it
> perhaps not fully compatible with Org 9? After following the

Stig,

maybe post an ECM?  Koma letters work fine with me with org 9.  I just
tried.

-- 
: Eric S Fraga (0xFFFCF67D), Emacs 26.0.50.1, Org release_9.0.1-49-ga43eac


signature.asc
Description: PGP signature


[O] agenda hangs with Org 9

2016-12-08 Thread Stig Brautaset

Hi,

After upgrading to Org 9 I am experiencing hangs in agenda, 
particularly
after refiling. I've got only one Agenda file, though it is quite 
big:


: Region has 1185 lines, 5887 words, and 41293 characters.

I've activated `debug-on-quit' and capturing some stack traces. 
I'm afraid
they don't mean much to me, but perhaps they will mean something 
to someone

with more knowledge of the internals than I:

#+BEGIN_EXAMPLE
Debugger entered--Lisp error: (quit)
 avl-tree--do-delete(org-element--cache-compare [[nil nil 
 (property-drawer (:begin 18463 :end 18529 :contents-begin 18479 
 :contents-end 18519 :post-blank 1 :post-affiliated 18463 :parent 
 nil)) 0] [nil nil (plain-list (:type unordered :begin 18547 :end 
 18749 :contents-begin 18574 :contents-end 18748 :structure ... 
 :post-blank 1 :post-affiliated 18574 :name "candidate-names" 
 :parent nil)) 0] (paragraph (:begin 18529 :end 18547 
 :contents-begin 18529 :contents-end 18546 :post-blank 1 
 :post-affiliated 18529 :parent nil)) 0] [[nil nil (keyword (:key 
 "RESULTS" :value "" :begin 18905 :end 18920 :post-blank 1 
 :post-affiliated 18905 :parent nil)) 0] [nil nil (paragraph 
 (:begin 19570 :end 19586 :contents-begin 19570 :contents-end 
 19585 :post-blank 1 :post-affiliated 19570 :parent nil)) 0] 
 (table (:begin 18920 :end 19570 :type org :tblfm nil 
 :contents-begin 18920 :contents-end 19568 :value nil :post-blank 
 2 :post-affiliated 18920 :parent nil)) 0] (src-block (:language 
 "sh" :switches nil :parameters ":var names=candidate-names 
 :results table" :begin 18749 :end 18905 :number-lines nil 
 :preserve-indent nil :retain-labels t :use-labels t :label-fmt 
 nil :value "   echo $names | xargs -n1 | perl  -MList::Util -e 
 'print List::Util::shuffle <>'\n" :post-blank 1 :post-affiliated 
 18749 :parent nil)) 0] [[[nil nil (paragraph (:begin 19669 :end 
 19686 :contents-begin 19669 :contents-end 19685 :post-blank 1 
 :post-affiliated 19669 :parent nil)) 0] [nil nil (drawer (:begin 
 19930 :end 20489 :drawer-name "LOGBOOK" :contents-begin 19943 
 :contents-end 20480 :post-blank 0 :post-affiliated 19930 :parent 
 nil)) 0] (quote-block (:begin 19686 :end 19930 :contents-begin 
 19703 :contents-end 19914 :post-blank 1 :post-affiliated 19686 
 :parent nil)) 0] [[nil nil (drawer (:begin 22024 :end 22336 
 :drawer-name "LOGBOOK" :contents-begin 22038 :contents-end 22325 
 :post-blank 1 :post-affiliated 22024 :parent nil)) 0] [nil nil 
 (drawer (:begin 22475 :end 22823 :drawer-name "LOGBOOK" 
 :contents-begin 22489 :contents-end 22812 :post-blank 1 
 :post-affiliated 22475 :parent nil)) 0] (planning (:closed nil 
 :deadline nil :scheduled (timestamp ...) :begin 22443 :end 22475 
 :post-blank 0 :post-affiliated 22443 :parent nil)) 0] (drawer 
 (:begin 20555 :end 20613 :drawer-name "LOGBOOK" :contents-begin 
 20568 :contents-end 20603 :post-blank 1 :post-affiliated 20555 
 :parent nil)) 0] (paragraph (:begin 19586 :end 19669 
 :contents-begin 19586 :contents-end 19668 :post-blank 1 
 :post-affiliated 19586 :parent nil)) 0] nil nil (drawer 
 (:begin 23180 :end 23313 :drawer-name "LOGBOOK" :contents-begin 
 23194 :contents-end 23302 :post-blank 1 :post-affiliated 23180 
 :parent nil)) 0] [nil nil (drawer (:begin 23673 :end 23731 
 :drawer-name "LOGBOOK" :contents-begin 23686 :contents-end 23721 
 :post-blank 1 :post-affiliated 23673 :parent nil)) 0] (planning 
 (:closed nil :deadline nil :scheduled (timestamp ...) :begin 
 23641 :end 23673 :post-blank 1 :post-affiliated 23641 :parent 
 nil)) 0] [[nil nil (drawer (:begin 24008 :end 24066 :drawer-name 
 "LOGBOOK" :contents-begin 24021 :contents-end 24056 :post-blank 
 1 :post-affiliated 24008 :parent nil)) 0] [nil nil (drawer 
 (:begin 25208 :end 25269 :drawer-name "LOGBOOK" :contents-begin 
 25222 :contents-end 25258 :post-blank 1 :post-affiliated 25208 
 :parent nil)) 0] (drawer (:begin 24886 :end 24947 :drawer-name 
 "LOGBOOK" :contents-begin 24900 :contents-end 24936 :post-blank 
 1 :post-affiliated 24886 :parent nil)) 0] (drawer (:begin 23879 
 :end 23937 :drawer-name "LOGBOOK" :contents-begin 23892 
 :contents-end 23927 :post-blank 1 :post-affiliated 23879 :parent 
 nil)) 0] [[[nil nil (drawer (:begin 25800 :end 25858 
 :drawer-name "LOGBOOK" :contents-begin 25813 :contents-end 25848 
 :post-blank 1 :post-affiliated 25800 :parent nil)) 0] [nil nil 
 (drawer (:begin 26660 :end 26777 :drawer-name "LOGBOOK" 
 :contents-begin 26674 :contents-end 26766 :post-blank 1 
 :post-affiliated 26660 :parent nil)) 0] (drawer (:begin 26173 
 :end 26231 :drawer-name "LOGBOOK" :contents-begin 26186 
 :contents-end 26221 :post-blank 1 :post-affiliated 26173 :parent 
 nil)) 0] [[nil nil (drawer (:begin 26947 :end 27005 :drawer-name 
 "LOGBOOK" :contents-begin 26960 :contents-end 26995 :post-blank 
 1 :post-affiliated 26947 :parent nil)) 0] [[nil nil (drawer ...) 
 0] nil (drawer (:begin 27382 :end 27440 :drawer-name "LOGBOOK" 
 :contents-begin 27395 :contents-end 27430 :post-blank 1 
 :post-affiliated 27382 

Re: [O] Fwd: [PATCH] Add support for ordered list to ox-confluence.el

2016-12-08 Thread Charles Durst
They do conflict.  My version is slightly more complicated since it
also supports nested mixed lists.

For example:

1. Here
   * is
   * an
2. example
   * of
   * a
3. mixed
4. list

Which translates to:

# Here
#- is
#- an
# example
#- of
#- a
# mixed
# list

Which is effectively the same as the example in the Confluence documentation:
https://confluence.atlassian.com/confcloud/confluence-wiki-markup-724765099.html#ConfluenceWikiMarkup-Mixedlists

--
Charles Durst
cwdurst+orgm...@gmail.com


On Thu, Dec 8, 2016 at 5:49 PM, Nicolas Goaziou  wrote:
> Hello,
>
> Lungang Fang  writes:
>
>> Attached is a patch for contrib/lisp/ox-confluence.el generated following
>> instructions on http://orgmode.org/worg/org-contribute.html#patches . It
>> adds support for ordered list.
>
> Thank you.
>
> However, this somewhat conflicts with a patch recently sent on the ML,
> but not yet applied, by Charles Durst (Cc'ed).
>
> Could one double-check if one doesn't supersede the other, or if they
> could be merged (although I suspect the former) and report back so
> I know what patch to apply?
>
> Regards,
>
> --
> Nicolas Goaziou



Re: [O] Fwd: [PATCH] Add support for ordered list to ox-confluence.el

2016-12-08 Thread Nicolas Goaziou
Hello,

Lungang Fang  writes:

> Attached is a patch for contrib/lisp/ox-confluence.el generated following
> instructions on http://orgmode.org/worg/org-contribute.html#patches . It
> adds support for ordered list.

Thank you. 

However, this somewhat conflicts with a patch recently sent on the ML,
but not yet applied, by Charles Durst (Cc'ed).

Could one double-check if one doesn't supersede the other, or if they
could be merged (although I suspect the former) and report back so
I know what patch to apply?

Regards,

-- 
Nicolas Goaziou



Re: [O] Allow #+SETUPFILE to point to an URL for the org file

2016-12-08 Thread Nicolas Goaziou
Kaushal Modi  writes:

> Hmm, is there a way to read a file from a URL to a variable directly? Or
> did you mean to download the file first, read that into a temp buffer and
> then delete the temp file?

You can use something like `url-insert' and `url-retrieve' or
`url-retrieve-synchronously'.

> This proposal was for the case where we have
>
> #+SETUPFILE: http://foo.bar/config.org
>
> So it cannot be local to begin with.

Sure, but SETUPFILE still accepts local file names. So I was pointing
out that you need to check if the URL is a local file name before
proceeding. In particular, this check needs to happen when using "C-c '"
(which may display URL contents in a read-only buffer, BTW).

> With respect to the point about not having the file in temp, we can have a
> flag that if set, will prevent re-downloading of the file. User can choose
> to reset that flag and then re-download that file. This will be lieu of the
> earlier condition "(2) that temp file does not exist."

Is it necessary? File contents could be stored in, e.g., a hash table,
url being the key. The file is downloaded only if the entry doesn't
exist in the table and the user didn't force download.-

> I would like to work on this. But I will be away from my computer for about
> a month starting tomorrow. Will get back to this once I am back from my
> vacation.

Great. Thank you.

Regards,



Re: [O] writing letters using the latex letters class?

2016-12-08 Thread Stig Brautaset


Eric S Fraga writes:

Stig,

maybe post an ECM?  Koma letters work fine with me with org 9. 
I just

tried.


Yeah, this is a bit embarrassing but it works fine here too now 
that I
use the koma exporter rather than the latex one as Sebastian 
pointed

out...

Stig



Re: [O] writing letters using the latex letters class?

2016-12-08 Thread Stig Brautaset


Sebastian Christ writes:

You need to load `ox-koma-letter' and make sure you're not using 
the
latex exporter. For letters there is (after loading 
`ox-koma-letter' of

course) a separate koma exporter.


Doh! I used the latex exporter. Thanks, I'll give koma another try 
:-)


Stig



Re: [O] Allow #+SETUPFILE to point to an URL for the org file

2016-12-08 Thread Kaushal Modi
On Thu, Dec 8, 2016 at 4:48 PM Nicolas Goaziou 
wrote:

> Kaushal Modi  writes:
>
> What about storing the contents of the file in a variable instead of
> cluttering the temp directory?
>

Hmm, is there a way to read a file from a URL to a variable directly? Or
did you mean to download the file first, read that into a temp buffer and
then delete the temp file?


>
> > - Now, the referenced SETUPFILE should be downloaded only if that (1)
> That
> > file is being fetched for the first time in that emacs session, or (2)
> that
> > temp file does not exist.
>
> And (3) it isn't local?
>

This proposal was for the case where we have

#+SETUPFILE: http://foo.bar/config.org

So it cannot be local to begin with.

With respect to the point about not having the file in temp, we can have a
flag that if set, will prevent re-downloading of the file. User can choose
to reset that flag and then re-download that file. This will be lieu of the
earlier condition "(2) that temp file does not exist."


>
> > - Add a defun to force reload the SETUPFILE from the referenced URL, in
> > which case the temp file will be deleted and re-downloaded (as the above
> > condition satisfied).
> >
> > So under the normal circumstance where that foo.org file buffer is
> reverted
> > multiple times in an emacs session, the same SETUPFILE downloaded to /tmp
> > will be used. If the user updated the file at the referenced URL, they
> can
> > do the above mentioned forced reload of SETUPFILE and download the latest
> > version of SETUPFILE.
> >
> > Thoughts?
>
> It could work. Do you want to provide an implementation?
>

I would like to work on this. But I will be away from my computer for about
a month starting tomorrow. Will get back to this once I am back from my
vacation.

Thank you for the feedback.
-- 

Kaushal Modi


Re: [O] Allow #+SETUPFILE to point to an URL for the org file

2016-12-08 Thread Nicolas Goaziou
Kaushal Modi  writes:

> Here are a couple of ideas:
>
> - Let's assume that if the current file name is /path/to/foo.org, the
> SETUPFILE is always downloaded to /tmp/path_to_foo_config.org for brevity.
> The function that sets that temp file should be a defcustom.

What about storing the contents of the file in a variable instead of
cluttering the temp directory?

> - Now, the referenced SETUPFILE should be downloaded only if that (1) That
> file is being fetched for the first time in that emacs session, or (2) that
> temp file does not exist.

And (3) it isn't local?

> - Add a defun to force reload the SETUPFILE from the referenced URL, in
> which case the temp file will be deleted and re-downloaded (as the above
> condition satisfied).
>
> So under the normal circumstance where that foo.org file buffer is reverted
> multiple times in an emacs session, the same SETUPFILE downloaded to /tmp
> will be used. If the user updated the file at the referenced URL, they can
> do the above mentioned forced reload of SETUPFILE and download the latest
> version of SETUPFILE.
>
> Thoughts?

It could work. Do you want to provide an implementation?

Regards,



Re: [O] [bug] org 9 hangs on link search

2016-12-08 Thread Nicolas Goaziou
Hello,

Samuel Wales  writes:

> in emacs -Q, with my org files, (org-link-search "*test") will hang in
> org 9maint, but not in org 8.  debug on quit produces this re.
>
>   re-search-forward("^\\*+ +.*\\(?:COMMENT[   ]+\\)?\\(?:\\(?:[
>   ]\\|\\(?:[  ]*\\[[0-9]*\\(?:%\\|/[0-9]*\\)\\][
>   ]*\\)\\)+\\)?*test\\(?:\\(?:[   ]\\|\\(?:[
>   ]*\\[[0-9]*\\(?:%\\|/[0-9]*\\)\\][  ]*\\)\\)+\\)?" nil t)

I committed a simplification of `org-link-search' so it no longer
produces this kind of regexp.

Anyway, please report if you encounter the freeze whenever you get the
chance to test the fix.


Regards,

-- 
Nicolas Goaziou



[O] Bug: Archive to Datetree Empty Lines [9.0.1 (9.0.1-elpa @ .../.emacs.d/elpa/org-20161118/)]

2016-12-08 Thread Klarre N
​If archiving to datetree (setq org-archive-location
"file.ext::datetree/"), then archiving tasks that are not in ascending
chronological order will have one more empty line than the original task
had, as opposed to zero (0) when archiving tasks that are in order.

The following (date for A1 is in the future with respect to the date for
A2) produces unexpected result on "Minimal Example":
1. Archive first TODO "A1".

2. Archive second TODO "A2".

* Minimal Example
** DONE A1: One Empty Line After
   CLOSED: [2016-06-28 Tue 21:00]

** DONE A2: Two Empty Lines After
   CLOSED: [2016-06-14 Tue 21:00]


** DONE A3: Extra


Result (three (3 = 2 + 1) empty lines between the tasks, the properties
have been deleted for readability):

* 2016
** 2016-06 June
*** 2016-06-14 Tuesday
 DONE A2: Two Empty Lines After
 CLOSED: [2016-06-14 Tue 21:00]
 :PROPERTIES:
 :END:



*** 2016-06-28 Tuesday
 DONE A1: One Empty Line After
 CLOSED: [2016-06-28 Tue 21:00]
 :PROPERTIES:
 :END:


Expected Result (same as archiving them in opposite order):

* 2016
** 2016-06 June
*** 2016-06-14 Tuesday
 DONE A2: Two Empty Lines After
 CLOSED: [2016-06-14 Tue 21:00]
 :PROPERTIES:
 :END:
*** 2016-06-28 Tuesday
 DONE A1: One Empty Line After
 CLOSED: [2016-06-28 Tue 21:00]
 :PROPERTIES:
 :END:


​The following produces the expected result (zero empty lines) on "Minimal
Example":
1. Archive second TODO "2".

2. Archive first TODO "1".

However, I personally think the *desired result* would be (two (2) empty
lines, that is, respect the original number), and it would have to be
changed for tasks in order also:

* 2016
** 2016-06 June
*** 2016-06-14 Tuesday
 DONE A2: Two Empty Lines After
 CLOSED: [2016-06-14 Tue 21:00]
 :PROPERTIES:
 :END:


*** 2016-06-28 Tuesday
 DONE A1: One Empty Line After
 CLOSED: [2016-06-28 Tue 21:00]
 :PROPERTIES:
 :END:


Note: this was posted before, tried to post it as a reply to a bug
(archiving tasks not in order to datetree, reported by me, that is now
fixed), but due to incorrect subject line or recipient it was a bit of a
mess and might have been lost or difficult to understand, sorry for that
and for posting twice!

Thank you!


*Regards,Klarre*


Emacs  : GNU Emacs 25.1.1 (x86_64-w64-mingw32)
 of 2016-09-22
Package: Org mode version 9.0.1 (9.0.1-elpa @
.../.emacs.d/elpa/org-20161118/)

current state:
==
(setq
 org-tab-first-hook '(org-babel-hide-result-toggle-maybe
org-babel-header-arg-expand)
 org-speed-command-hook '(org-speed-command-default-hook
org-babel-speed-command-hook)
 org-occur-hook '(org-first-headline-recenter)
 org-metaup-hook '(org-babel-load-in-session-maybe)
 org-confirm-shell-link-function 'yes-or-no-p
 org-after-todo-state-change-hook '(org-clock-out-if-current)
 org-src-mode-hook '(org-src-babel-configure-edit-buffer
org-src-mode-configure-edit-buffer)
 org-agenda-before-write-hook '(org-agenda-add-entry-text)
 org-babel-pre-tangle-hook '(save-buffer)
 org-mode-hook '(#[0 "\300\301\302\303\304$\207"
   [add-hook change-major-mode-hook org-show-block-all append
local] 5]
 #[0 "\300\301\302\303\304$\207"
   [add-hook change-major-mode-hook org-babel-show-result-all
append local] 5]
 org-babel-result-hide-spec org-babel-hide-all-hashes)
 org-archive-hook '(org-attach-archive-delete-maybe)
 org-cycle-hook '(org-cycle-hide-archived-subtrees org-cycle-hide-drawers
org-cycle-show-empty-lines
  org-optimize-window-after-visibility-change)
 org-archive-location "archive.arc::datetree/"
 org-confirm-elisp-link-function 'yes-or-no-p
 org-metadown-hook '(org-babel-pop-to-session-maybe)
 org-link-parameters '(("id" :follow org-id-open) ("rmail" :follow
org-rmail-open :store org-rmail-store-link)
   ("mhe" :follow org-mhe-open :store org-mhe-store-link)
   ("irc" :follow org-irc-visit :store org-irc-store-link)
   ("info" :follow org-info-open :export org-info-export :store
org-info-store-link)
   ("gnus" :follow org-gnus-open :store org-gnus-store-link)
   ("docview" :follow org-docview-open :export
org-docview-export :store
org-docview-store-link)
   ("bibtex" :follow org-bibtex-open :store
org-bibtex-store-link)
   ("bbdb" :follow org-bbdb-open :export org-bbdb-export
:complete org-bbdb-complete-link
:store org-bbdb-store-link)
   ("w3m" :store org-w3m-store-link) ("file+sys") ("file+emacs")
   ("doi" :follow org--open-doi-link) ("elisp" :follow
org--open-elisp-link)
   ("file" :complete org-file-complete-link)
   ("ftp" :follow (lambda (path) (browse-url (concat "ftp:"
path
   ("help" :follow org--open-help-link)
   ("http" :follow (lambda (path) (browse-url (concat "http:"
path
   ("https" :follow (lambda (path) (browse-url (concat "https:"
path
   

[O] teaching with live-updating code examples

2016-12-08 Thread Matt Price
I am preparing a set of lectures for a class teaching HTML, CSS, and
javascript ot humanities students.

I would like to have slides with a simple code editor on one side, and the
results of the code on another:


| [1,2,3].map(function(x){return x + 1;})   |   Array[2,3,4] |


or in other cases


|Hello| Hello in appropriate format  |
-

The former, at least, is pretty straightforward to do in CodeMirror with
the klipse plugin.  However, codemirror integrates poorly with reveal.js,
which is how I normally export my slides.

So, I'm looking for other solutions. What do other people do in lecture?
I'd really like to be able to keep all my notes and code in a single org
file, if at all possible.  I'm willing to switch away from reveal, but
since this is a course about the web I'd really like to kep it in an HTML
format if I can.
On the other hand if you have a great solution I'd love to hear about it no
matter what!


Thanks everyone!

Matt


[O] [bug] org 9 hangs on link search

2016-12-08 Thread Samuel Wales
in emacs -Q, with my org files, (org-link-search "*test") will hang in
org 9maint, but not in org 8.  debug on quit produces this re.

  re-search-forward("^\\*+ +.*\\(?:COMMENT[ ]+\\)?\\(?:\\(?:[
]\\|\\(?:[  ]*\\[[0-9]*\\(?:%\\|/[0-9]*\\)\\][
]*\\)\\)+\\)?*test\\(?:\\(?:[   ]\\|\\(?:[
]*\\[[0-9]*\\(?:%\\|/[0-9]*\\)\\][  ]*\\)\\)+\\)?" nil t)

-- 
The Kafka Pandemic: http://thekafkapandemic.blogspot.com

The disease DOES progress.  MANY people have died from it.  And
ANYBODY can get it.

Denmark: free Karina Hansen NOW.
  UPDATE 2016-10: home, but not fully free



Re: [O] writing letters using the latex letters class?

2016-12-08 Thread Sebastian Christ
On 2016-12-08 11:40, Stig Brautaset  wrote:
 > It looks promising but I can't get it to work as I expect; is it
 > perhaps
 > not fully compatible with Org 9? 

No. It's working fine with Org 9.

 > After following the instructions on that page to the best of my
 > abilities, and using their example document, my output contains lots
 > of stuff that I expect to be hidden. (E.g. all the to/from special
 > headings etc).

You need to load `ox-koma-letter' and make sure you're not using the
latex exporter. For letters there is (after loading `ox-koma-letter' of
course) a separate koma exporter.

Best,

Sebastian

-- 
Sebastian (Rudolfo) Christ
http://rudolfochrist.github.io
GPG Fingerprint: 306D 8FD3 DFB6 4E44 5061
 CE71 6407 D6F8 2AC5 55DD




Re: [O] org-depend: dependencies between TODO entries in different files

2016-12-08 Thread Nicolas Goaziou
Hello,

Carsten Dominik  writes:

> I can take a look at that.  Unless Nicolas already is working on it, of
> course.

It's somewhere on my (rather large) TODO list, but I'm not currently
working on it.

Regards,

-- 
Nicolas Goaziou



Re: [O] Allow #+SETUPFILE to point to an URL for the org file

2016-12-08 Thread Nicolas Goaziou
Hello,

Kaushal Modi  writes:

> Anyone?

Apparently not.

Note that it could drastically slow down opening buffers with a mediocre
connection since SETUPFILE is read every time buffer set-up is
refreshed, e.g., when the buffer is opened.

Regards,

-- 
Nicolas Goaziou



Re: [O] Allow #+SETUPFILE to point to an URL for the org file

2016-12-08 Thread John Kitchin
+1. I would use it like an xml dtd if I could ;).


Kaushal Modi writes:

> Anyone?
>
> On Sat, Dec 3, 2016, 12:23 PM Kaushal Modi  wrote:
>
>> Hello,
>>
>> I would like to put my common org config in github so that I can access it
>> from anywhere/any machine.
>>
>> Currently I have
>>
>> #+SETUPFILE: ~/org/common/config.org
>>
>> I would like to do something like
>>
>> #+SETUPFILE: https://cdn.rawgit.com/path/to/config.org
>>
>> I can probably add an async shell execution to wget that link, save it to
>> /tmp/config.org and then replace
>>
>> #+SETUPFILE: https://cdn.rawgit.com/path/to/config.org
>>
>> with
>>
>> #+SETUPFILE: /tmp/config.org
>>
>> in, may be, org-export-before-processing-hook?
>>
>> But has someone already implemented something like this?
>>
>> Thanks.
>> --
>>
>> Kaushal Modi
>>


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



Re: [O] Allow #+SETUPFILE to point to an URL for the org file

2016-12-08 Thread Kaushal Modi
On Thu, Dec 8, 2016 at 9:31 AM Nicolas Goaziou 
wrote:

> Hello,
>
> Kaushal Modi  writes:
>
> > Anyone?
>
> Apparently not.
>
> Note that it could drastically slow down opening buffers with a mediocre
> connection since SETUPFILE is read every time buffer set-up is
> refreshed, e.g., when the buffer is opened.
>
>
Here are a couple of ideas:

- Let's assume that if the current file name is /path/to/foo.org, the
SETUPFILE is always downloaded to /tmp/path_to_foo_config.org for brevity.
The function that sets that temp file should be a defcustom.
- Now, the referenced SETUPFILE should be downloaded only if that (1) That
file is being fetched for the first time in that emacs session, or (2) that
temp file does not exist.
- Add a defun to force reload the SETUPFILE from the referenced URL, in
which case the temp file will be deleted and re-downloaded (as the above
condition satisfied).

So under the normal circumstance where that foo.org file buffer is reverted
multiple times in an emacs session, the same SETUPFILE downloaded to /tmp
will be used. If the user updated the file at the referenced URL, they can
do the above mentioned forced reload of SETUPFILE and download the latest
version of SETUPFILE.

Thoughts?
-- 

Kaushal Modi


Re: [O] Allow #+SETUPFILE to point to an URL for the org file

2016-12-08 Thread Kaushal Modi
Anyone?

On Sat, Dec 3, 2016, 12:23 PM Kaushal Modi  wrote:

> Hello,
>
> I would like to put my common org config in github so that I can access it
> from anywhere/any machine.
>
> Currently I have
>
> #+SETUPFILE: ~/org/common/config.org
>
> I would like to do something like
>
> #+SETUPFILE: https://cdn.rawgit.com/path/to/config.org
>
> I can probably add an async shell execution to wget that link, save it to
> /tmp/config.org and then replace
>
> #+SETUPFILE: https://cdn.rawgit.com/path/to/config.org
>
> with
>
> #+SETUPFILE: /tmp/config.org
>
> in, may be, org-export-before-processing-hook?
>
> But has someone already implemented something like this?
>
> Thanks.
> --
>
> Kaushal Modi
>
-- 

Kaushal Modi


Re: [O] writing letters using the latex letters class?

2016-12-08 Thread Eric S Fraga
On Thursday,  8 Dec 2016 at 00:46, Stig Brautaset wrote:
> I've tried to get a simple letter to export to PDF using the latex
> letters class, but I can't get it to work in any satisfactory way. I
> want to get something like the following generated:

I can't help you directly but you may wish to look at the support for
koma letter class in org/contrib: ox-koma-letter.el.

-- 
: Eric S Fraga (0xFFFCF67D), Emacs 26.0.50.1, Org release_9.0.1-49-ga43eac


signature.asc
Description: PGP signature


Re: [O] writing letters using the latex letters class?

2016-12-08 Thread Stig Brautaset


Sebastian Christ writes:


On 2016-12-08 0:46, Stig Brautaset  wrote:
 > That at least got me past the "Unknow LaTeX class 'letter'" 
 > error,
 > but it doesn't produce a nice letter. I only get my lorem 
 > ipsum
 > text. I can't figure out how to get the \begin{letter}{...} 
 > stuff
 > inside the \begin{document} part automatically, nor how to 
 > inject

 > text from #+recipient: into the second block of the
 > \begin{letter}{...} macro.

I can't actually help in using the letter class, but have you 
checked
"Creating letters with KOMA-Script scrlttr2 and Org-mode" [1]? 
I've been
using it excursively for all  my /formal/ letter writing and it 
works
great. Maybe you can give that a try? Plus it produces really 
nice

letters :)



It looks promising but I can't get it to work as I expect; is it 
perhaps
not fully compatible with Org 9? After following the instructions 
on
that page to the best of my abilities, and using their example 
document,
my output contains lots of stuff that I expect to be hidden. (E.g. 
all

the to/from special headings etc).

Stig



Re: [O] org-depend: dependencies between TODO entries in different files

2016-12-08 Thread Samuel Loury
Jorge Morais Neto  writes:

> On 8 December 2016 at 04:44, Carsten Dominik  wrote:
>> One additional point is, of course, that org-depend is not part of the core,
>> but was written as a proof of concept.  Is anyone besides Karl using it
>> regularly?  I don't want to break anything by changing it.
> I use it (in a very small number of entries).

Me too. but I don't mind it to break.

-- 
Konubinix
GPG Key: 7439106A
Fingerprint: 5993 BE7A DA65 E2D9 06CE  5C36 75D2 3CED 7439 106A



Re: [O] org-depend: dependencies between TODO entries in different files

2016-12-08 Thread Jorge Morais Neto
On 8 December 2016 at 04:44, Carsten Dominik  wrote:
> One additional point is, of course, that org-depend is not part of the core,
> but was written as a proof of concept.  Is anyone besides Karl using it
> regularly?  I don't want to break anything by changing it.
I use it (in a very small number of entries).

Regards
-- 
• I am Brazilian.  I hope my English is correct and I welcome corrections.
• Please adopt free formats like PDF, ODF, Org, LaTeX, Opus, WebM and 7z.
• Free (as in free speech) software for Android: https://f-droid.org/



Re: [O] writing letters using the latex letters class?

2016-12-08 Thread Sebastian Christ
On 2016-12-08 0:46, Stig Brautaset  wrote:
 > That at least got me past the "Unknow LaTeX class 'letter'" error, but
 > it
 > doesn't produce a nice letter. I only get my lorem ipsum text. I can't
 > figure
 > out how to get the \begin{letter}{...} stuff inside the
 > \begin{document} part
 > automatically, nor how to inject text from #+recipient: into the
 > second block
 > of the \begin{letter}{...} macro.

I can't actually help in using the letter class, but have you checked
"Creating letters with KOMA-Script scrlttr2 and Org-mode" [1]? I've been
using it excursively for all  my /formal/ letter writing and it works
great. Maybe you can give that a try? Plus it produces really nice
letters :) 

Best,

Sebastian


[1] http://orgmode.org/worg/exporters/koma-letter-export.html

-- 
Sebastian (Rudolfo) Christ
http://rudolfochrist.github.io
GPG Fingerprint: 306D 8FD3 DFB6 4E44 5061
 CE71 6407 D6F8 2AC5 55DD