Re: Bug: ob-python mangles multiline :var values [9.3.6 (release_9.3.6-397-ga089600)]

2020-06-09 Thread Jack Kamm
Hi Kyle,

Thanks for the code review which was very helpful as always. I've fixed
the style and compile errors that you noticed, and pushed the commit to
master.

Cheers,
Jack



[ISSUE] org-agenda with clocktable infinite on logbook which has text-propertize links

2020-06-09 Thread stardiviner
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256


When org-agenda have option ~org-agenda-start-with-clockreport-mode~ enabled.
Generate Org Agenda with clocktable. Here is an Org content which has logbook
contains link which is text-propertized using Emacs extension
https://github.com/stardiviner/org-link-beautify (It's written by myself).

#+begin_src org
,** PROJECT google-translate [11/22]
   SCHEDULED: <2020-06-09 Tue>
   :LOGBOOK:
   CLOCK: [2020-06-10 Wed 09:19]--[2020-06-10 Wed 10:34] =>  1:15
   - create PR https://github.com/atykhonov/google-translate/pull/118
   CLOCK: [2020-06-10 Wed 09:09]--[2020-06-10 Wed 09:14] =>  0:05
   - finished bump version process, tag v0.12.0, draft GitHub release.

#+end_src

When I remove that text-propertized link, org-agenda generate fine. When have
that text-propertized link, org-agenda is infinitely un-finished.

- -- 
[ stardiviner ]
   I try to make every word tell the meaning that I want to express.

   Blog: https://stardiviner.github.io/
   IRC(freenode): stardiviner, Matrix: stardiviner
   GPG: F09F650D7D674819892591401B5DF1C95AE89AC3
-BEGIN PGP SIGNATURE-

iQFIBAEBCAAyFiEE8J9lDX1nSBmJJZFAG13xyVromsMFAl7gUQAUHG51bWJjaGls
ZEBnbWFpbC5jb20ACgkQG13xyVromsNdhQf/b2gkDc9jqbv2BD6zhFEh5nuQ+4hI
FjXXMUBuhiJnMCTXe0DeL4zG2iyU2N/IWHzP+ftuH8QWEK6xOPBAhEuS+6culgK8
aCehl/J9LQsnz6UC8IVw9Pc+Lg+342A4TNJpXgz80RsihwAiObn0Wb0bIOWLJ22n
Vc33x5+jFOCrOVkvjONI+YNTC2hpghfZ/CMW/cmjKsMj9jZ2oOuXIC8ksOhEMIWO
GMQtxQRzO6/gG/VWBC2Ijh0af10rTAYPhbUDfbSaE49tMRoMuWoj7ALceI6gEPtI
z4dWUtEQh2pxCd0ojfIswUJyAkDhNjbBo022DMqwpqgfNycnlMyZQPVq3Q==
=nH9N
-END PGP SIGNATURE-



Re: org-babel-tangle not using relative links

2020-06-09 Thread Jeremias Gonzalez

On 6/8/2020 5:37 PM, Kyle Meyer wrote:

Kyle Meyer writes:


Thank you for the excellent bug report.  This is should be fixed by


Guh, "is should be".  Apparently I started off feeling bold,
reconsidered, and then did a sloppy job of switching to a more cautious
claim :/


The new code works perfectly for me on both my test systems, your 
boldness was justified:) Thank you very much for the fix.




Re: Import Reusable org-babel snippet using #+SETUPFILE

2020-06-09 Thread Nicolas Goaziou
Hello,

Salomon Turgman  writes:

> Now, if I include the definition in every org file that I want to use it,
> everything works well. However, if I include the definition in a central
> org file that I import using #+SETUPFILE, things break and I don't get the
> proper output in my html exports.

SETUPFILE only imports keywords.

> Is there a way that I can "import" that snippet without rewriting it in
> every file I need it?

See (info "(org) Library of Babel")

Regards,

-- 
Nicolas Goaziou



FWD: Re: FWD: Org-Babel Support for Powershell

2020-06-09 Thread General discussions about Org-mode.
Hi,

I thought about four possible solutions to include Powershell 7 in Emacs. I 
understand that Powershell 5.1 is not Open Source. But is is not the case with 
Powershell 7.

I share my idea with nche...@linuxha.com below. I am still not very familiar 
with the vast emacs universe. But I am very good in generating ideas. 
Unfortunately, I am not very confident to get my ideas working on my own.

Yours sincerely

Stanislaw
-- 
 Securely sent with Tutanota. Get your own encrypted, ad-free mailbox: 
 https://tutanota.com


Date: Jun 9, 2020, 22:37
From: stanislaw_...@tutanota.com
To: nche...@linuxha.com
Subject: Re: FWD: Org-Babel Support for Powershell


> Hi,
>
> recently, I got some hints from Google Bing. Jupyter notebook offer a 
> powershell kernel. Jupyter notebook can be accessed from Emacs. I thought of 
> several ways to include Powershell in emacs:
>
> I. Use Powershell kernel in Jupyter notebook. Use Emacs to access Jupyter 
> notebook
>
> The Powershell kernel is community-driven and Azure actually use it. The 
> Powershell kernel is used with Anaconda - that is not light-weight. 
>
> https://github.com/Jaykul/Jupyter-PowerShel 
> > l 
> 
>
> Emacs supports w3m - a text browser - Microsoft recommends installing Windows 
> Server OS without GUI, because you can avoid update problems. 
>
> II. Adapt polymode in Emacs for Powershell
>
> But I think, we need something like webmode in order to mix different code 
> snippets. I take a look how polymode work in emacs this weekend.
>
> III. Use language-agnostic literate programming tool
>
> I got another idea to find a very simple language-agnostic literate 
> programming tool. 
>
> https://github.com/zyedidia/Literate
>
> This little language-agnostic tool looks very simple - maybe it can be adapt 
> for powershell. It used awk to extract the code snippets inside the code 
> fences
>
> https://github.com/0atman/blaze
>
> IV. Embedding Powershell in Python or Ruby and make configuration readable 
> with reverse literate programming tool
>
> Another idea of mine is embedding Powershell code in Python and Ruby code and 
> make it readable with a reverse literate programming tool:
>
> Python support: > https://github.com/7enderhead/antiweb
>
> Ruby support: > https://github.com/orenbenkiki/codnar
>
> I am not very familiar with all these tools. Maybe someone has daily 
> experience with these toolsand can publish his configurations. 
>
> Yours sincerely
>
> Stanislaw
>
> -- 
> Securely sent with Tutanota. Get your own encrypted, ad-free mailbox: 
> https://tutanota.com
>
>
> Jun 9, 2020, 15:08 by nche...@linuxha.com:
>
>> On 6/6/20 10:01 AM, stardiviner wrote:
>>
>>> I remember already there are some ob-powershell relative projects. You might
>>> want to work and improve features on those work. And integrate it into Org 
>>> Mode.
>>>
>>> - https://gist.github.com/cbilson/ae0d90d163be4d769f8a15ddb58292bc
>>>
>>
>> Using this in Windows 10.
>>
>> I found that I've had to change:
>>
>> "-NoLogo -NonInteractive"))
>>
>> to
>>
>> "-NoLogo -NonInteractive -ExecutionPolicy Bypass  ")) ;;; need to avoid MS 
>> no scripts policy
>>
>> I needed to user powershell to get around some of the stdout issues with 
>> cygwin
>> and mgwin.
>>
>> I've not used powershell before so I'm still learning it. Definitely not in
>> Unix anymore. Thirty five  years of Unix and DOS makes this a very strange
>> beast.
>>
>>> - https://github.com/togakangaroo/ob-pwsh
>>>
>>
>> I hadn't seen this one, I'll take a look at it later.
>>
>> -- 
>> Linux Home Automation Neil Cherry   nche...@linuxha.com
>> http://www.linuxha.com/ Main site
>> http://linuxha.blogspot.com/My HA Blog
>> Author of:   Linux Smart Homes For Dummies
>>
>
>



Re: ox-* vs org-* naming convention?

2020-06-09 Thread Diego Zamboni
Hi again,

> Given the special meanings of both the org- and ox- prefixes, I will
> insist on keeping the current naming, and maybe take a stab at coming
> up with a PR for https://github.com/purcell/package-lint/issues/89.

I submitted a PR to allow certain package-to-symbol prefix mappings in
package-lint: https://github.com/purcell/package-lint/pull/177

Feel free to comment!

--Diego



Canonical howto and init.el config for org-protocol and org-capture on OSX Catalina?

2020-06-09 Thread Daryl Manning
I've gone over a couple of older (and a newer) walkthroughs of how
org-protocol is supposed to work with a browser (firefox in my case) and
javascript bookmarklet to allow capture of info to emacs (27.0.91 from the
emacs-plus homebrew install) in my case.

None of them has seemed to work, I do know that a number of security
changes in Catalina might have broken or made this difficult, but does
anyone have this working in a reliable, smooth way? Mostly for me I want to
be able to capture email urls from gmail to have a ref for todos I've
creating though being able to save snipper from web pages and such would be
nice as well.

thanks (and apologies if my search fu simply let me down here, but I did
try 3 different instructions).

Daryl.


Re: org-ref for html and blog ?

2020-06-09 Thread Joseph Vidal-Rosset
Le   mar.   06/09/20   juin   2020   à   07:40:06   ,   András   Simonyi
 a envoyé ce message:
> Dear Joseph,
>
> strangely enough, using the same Emacs version with no customisations,
> and only the packages you listed (and their dependencies) with exactly
> the same versions I still can't reproduce any problem with the
> standard Org html export (C-c C-e and "Export to HTML") after running
> citeproc-org-setup. The only suspicious thing I noticed was that
> ox-pandoc does not seem to play totally nicely with citeproc-org --
> the references are not formatted correctly. Were you perhaps referring
> to ox-pandoc's html export? If not then I would still need a detailed
> minimal example I'm afraid.
>
> best regards,
> András

Dear Andras,

Thanks for having tried. I am sorry to be unable to give you an example,
because emacs do not reply with this "bug" (that comes from in fact from
my emacs setup, but  where exactly, I do not know)  and therefore I have
to kill it.

I will try to get a simpler setup and I will inform you.

Best wishes,

-- 
Jo.



Re: org-ref for html and blog ?

2020-06-09 Thread András Simonyi
Dear Joseph,

strangely enough, using the same Emacs version with no customisations,
and only the packages you listed (and their dependencies) with exactly
the same versions I still can't reproduce any problem with the
standard Org html export (C-c C-e and "Export to HTML") after running
citeproc-org-setup. The only suspicious thing I noticed was that
ox-pandoc does not seem to play totally nicely with citeproc-org --
the references are not formatted correctly. Were you perhaps referring
to ox-pandoc's html export? If not then I would still need a detailed
minimal example I'm afraid.

best regards,
András

On Tue, 9 Jun 2020 at 15:36, Joseph Vidal-Rosset
 wrote:
>
> Dear Andras,
>
> I just made test with less packages and the problem is not linked at
> all with org-export-head. In fact html export is no more possible with
> my emacs as soon as
>
> M-x citeproc-org-setup
>
> is done.
>
> Here are the list of packages:
>
> Emacs 26.3
>  org9.1.9 built-in (but the problem is the
> same with a more recent version of org).
>  org-bullets20200317.1740 installed
>   org-context20200418.1540 installed
>   org-mime   20200520.1100 installed
>   org-plus-contrib   20200608  installed
>   outorg 20190720.2002 installed
>   ox-pandoc  20180510.1338 installed
>  org-ref20200606.1848 dependency
>   citeproc-org   0.2.2 installed
>  citeproc   20200305.2126 dependency
>
> Best wishes,
>
> Jo.
>
> Le lun. 8 juin 2020 à 14:13, András Simonyi  a 
> écrit :
> >
> > Hi Joseph,
> >
> > this is rather mysterious. I tried to reproduce the bug: Downloaded
> > the ieee-with-url.csl style you are using and cloned the
> > org-export-head repository. Added some bibliographic references to the
> > blog entries in the example blog.org file, and... the whole export
> > with org-export-head ran without errors and the references and
> > bibliographies were formatted properly in the resulting html files.
> >
> > So I guess first we should try to find a minimal working example for
> > the bug that I can reproduce. Could you send an example where you add
> > just a single citation to the example blog.org file without any other
> > modifications and the org-export-head export hangs because of this?
> > It'd be also helpful if you could send the corresponding BibTeX entry
> > plus perhaps the Emacs and Org version numbers. Also, perhaps it'd be
> > worth trying out whether switching to other csl styles (e.g., the
> > Chicago style shipped with citeproc-org) make any difference.
> >
> > best regards,
> >
> > András
> >
> >
> > On Sun, 7 Jun 2020 at 16:23, Joseph Vidal-Rosset
> >  wrote:
> > >
> > > Hi again,
> > >
> > > I just discovered that my problem came from citeproc-org
> > >
> > > More exactly I had these lines in my init.el
> > >
> > > (require 'citeproc)
> > > (require 'citeproc-org)
> > > (citeproc-org-setup)
> > > (setq citeproc-org-html-bib-header "References\n")
> > > (setq citeproc-org-default-style-file 
> > > "~/Dropbox/Orgzly/ieee-with-url.csl")
> > >
> > > The function (citeproc-org-setup) is the responsible of this new problem.
> > >
> > > Sorry Andras to bother you with this problem with your package. I hope
> > > that you will have a solution.
> > >
> > > Best wishes,
> > >
> > > Jo.
> > >
> > > Le dim. 7 juin 2020 à 15:12, Joseph Vidal-Rosset
> > >  a écrit :
> > > >
> > > > Hi everybody,
> > > >
> > > > The package org-ref  is a wonderful tool and I do not imagine working
> > > > without its helps now (again many thanks to John Kitchin).
> > > >
> > > > But for some days now I meet a problem with bibliography html export
> > > > with org-ref and I cannot no more use org-export-head that I used for
> > > > my blog (https://github.com/itf/org-export-head thanks again to Ivan)
> > > > : as soon as there is a bibliographical reference, emacs loops.
> > > >
> > > > I guess that the problem is very probably in my emacs setup but I do
> > > > not find the solution.
> > > >
> > > > I would be happy to find help with html export with bibliographical
> > > > references, and advices for the best solution for blogging with emacs
> > > > (I've just tried Jekyll with org, but the problem with export
> > > > bibliographical reference is the same, my emacs loops.)
> > > >
> > > > In advance, thanks for your help, because I am lost.
> > > >
> > > > Jo.



Import Reusable org-babel snippet using #+SETUPFILE

2020-06-09 Thread Salomon Turgman
Hello all,

I have created what I hoped was a reusable org-babel snippet that looks
like this:

#+NAME: simulation
#+HEADER: :var cap="DEFAULTCAPTION" :cache yes :eval no-export :var
altimage="1_image.svg#img1"
#+BEGIN_SRC emacs-lisp :var divid="defid" :var num=1 :results html :exports
results
(format
"cool string that uses parameters %s %s ..."
num cap divid altimage (capitalize divid) divid)
#+END_SRC

I will use this snippet with something like:

#+CALL: simulation(cap="bam", num=1, divid="bamid"...)

Now, if I include the definition in every org file that I want to use it,
everything works well. However, if I include the definition in a central
org file that I import using #+SETUPFILE, things break and I don't get the
proper output in my html exports.

Is there a way that I can "import" that snippet without rewriting it in
every file I need it?

Thanks in advance!

-s-


Re: org-ref for html and blog ?

2020-06-09 Thread Joseph Vidal-Rosset
Dear Andras,

I just made test with less packages and the problem is not linked at
all with org-export-head. In fact html export is no more possible with
my emacs as soon as

M-x citeproc-org-setup

is done.

Here are the list of packages:

Emacs 26.3
 org9.1.9 built-in (but the problem is the
same with a more recent version of org).
 org-bullets20200317.1740 installed
  org-context20200418.1540 installed
  org-mime   20200520.1100 installed
  org-plus-contrib   20200608  installed
  outorg 20190720.2002 installed
  ox-pandoc  20180510.1338 installed
 org-ref20200606.1848 dependency
  citeproc-org   0.2.2 installed
 citeproc   20200305.2126 dependency

Best wishes,

Jo.

Le lun. 8 juin 2020 à 14:13, András Simonyi  a écrit :
>
> Hi Joseph,
>
> this is rather mysterious. I tried to reproduce the bug: Downloaded
> the ieee-with-url.csl style you are using and cloned the
> org-export-head repository. Added some bibliographic references to the
> blog entries in the example blog.org file, and... the whole export
> with org-export-head ran without errors and the references and
> bibliographies were formatted properly in the resulting html files.
>
> So I guess first we should try to find a minimal working example for
> the bug that I can reproduce. Could you send an example where you add
> just a single citation to the example blog.org file without any other
> modifications and the org-export-head export hangs because of this?
> It'd be also helpful if you could send the corresponding BibTeX entry
> plus perhaps the Emacs and Org version numbers. Also, perhaps it'd be
> worth trying out whether switching to other csl styles (e.g., the
> Chicago style shipped with citeproc-org) make any difference.
>
> best regards,
>
> András
>
>
> On Sun, 7 Jun 2020 at 16:23, Joseph Vidal-Rosset
>  wrote:
> >
> > Hi again,
> >
> > I just discovered that my problem came from citeproc-org
> >
> > More exactly I had these lines in my init.el
> >
> > (require 'citeproc)
> > (require 'citeproc-org)
> > (citeproc-org-setup)
> > (setq citeproc-org-html-bib-header "References\n")
> > (setq citeproc-org-default-style-file "~/Dropbox/Orgzly/ieee-with-url.csl")
> >
> > The function (citeproc-org-setup) is the responsible of this new problem.
> >
> > Sorry Andras to bother you with this problem with your package. I hope
> > that you will have a solution.
> >
> > Best wishes,
> >
> > Jo.
> >
> > Le dim. 7 juin 2020 à 15:12, Joseph Vidal-Rosset
> >  a écrit :
> > >
> > > Hi everybody,
> > >
> > > The package org-ref  is a wonderful tool and I do not imagine working
> > > without its helps now (again many thanks to John Kitchin).
> > >
> > > But for some days now I meet a problem with bibliography html export
> > > with org-ref and I cannot no more use org-export-head that I used for
> > > my blog (https://github.com/itf/org-export-head thanks again to Ivan)
> > > : as soon as there is a bibliographical reference, emacs loops.
> > >
> > > I guess that the problem is very probably in my emacs setup but I do
> > > not find the solution.
> > >
> > > I would be happy to find help with html export with bibliographical
> > > references, and advices for the best solution for blogging with emacs
> > > (I've just tried Jekyll with org, but the problem with export
> > > bibliographical reference is the same, my emacs loops.)
> > >
> > > In advance, thanks for your help, because I am lost.
> > >
> > > Jo.



Re: FWD: Org-Babel Support for Powershell

2020-06-09 Thread Neil Cherry
On 6/6/20 10:01 AM, stardiviner wrote:

> I remember already there are some ob-powershell relative projects. You might
> want to work and improve features on those work. And integrate it into Org 
> Mode.
> 
> - https://gist.github.com/cbilson/ae0d90d163be4d769f8a15ddb58292bc

Using this in Windows 10.

I found that I've had to change:

"-NoLogo -NonInteractive"))

to

"-NoLogo -NonInteractive -ExecutionPolicy Bypass  ")) ;;; need to avoid MS no 
scripts policy

I needed to user powershell to get around some of the stdout issues with cygwin
and mgwin.

I've not used powershell before so I'm still learning it. Definitely not in
Unix anymore. Thirty five  years of Unix and DOS makes this a very strange
beast.

> - https://github.com/togakangaroo/ob-pwsh

I hadn't seen this one, I'll take a look at it later.

-- 
Linux Home Automation Neil Cherry   nche...@linuxha.com
http://www.linuxha.com/ Main site
http://linuxha.blogspot.com/My HA Blog
Author of:  Linux Smart Homes For Dummies



signature.asc
Description: OpenPGP digital signature


Re: [BUG] All drawers except property drawers are open at startup

2020-06-09 Thread Nicolas Goaziou
Hello,

Matt Lundin  writes:

> In the function org-set-startup-visibility, that commit replaced
>
> (org-cycle-hide-drawers 'all)
>
> with
>
> (org-cycle-hide-property-drawers 'all)
>
> Thus, only property drawers are hidden at startup.

I forgot to say this was, hopefully, fixed in master.

Regards,

-- 
Nicolas Goaziou



[PATCH] org-element.el: Update comment

2020-06-09 Thread Leo Vivier
Hi there,

I’ve noticed that a comment on the caching of org-element wasn’t up to
date, so I went ahead and updated it.  I’ve also fixed a missing quote
for one of the variables.

HTH,

-- 
Leo Vivier
>From bf1fcc1c0650c30e1e12244df084ab344a2cac59 Mon Sep 17 00:00:00 2001
From: Leo Vivier 
Date: Tue, 9 Jun 2020 09:57:03 +0200
Subject: [PATCH] org-element.el: Update comment
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

* lisp/org-element.el (org-element-normalize-contents): Update comment

The comment mentions that caching for `org-elements' is enabled by
default, but this isn’t the case anymore since
bbdecd1e64a07b3821714d905a58eaca12828cb6, cf. `org-element-use-cache'.
---
 lisp/org-element.el | 8 +---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/lisp/org-element.el b/lisp/org-element.el
index ac41b7650..a5641e6ee 100644
--- a/lisp/org-element.el
+++ b/lisp/org-element.el
@@ -4821,10 +4821,12 @@ indentation removed from its contents."
 ;;
 ;; A single public function is provided: `org-element-cache-reset'.
 ;;
-;; Cache is enabled by default, but can be disabled globally with
+;; Cache is disabled by default for now because it sometimes triggers
+;; freezes, but it can be enabled globally with
 ;; `org-element-use-cache'.  `org-element-cache-sync-idle-time',
-;; org-element-cache-sync-duration' and `org-element-cache-sync-break'
-;; can be tweaked to control caching behavior.
+;; `org-element-cache-sync-duration' and
+;; `org-element-cache-sync-break' can be tweaked to control caching
+;; behavior.
 ;;
 ;; Internally, parsed elements are stored in an AVL tree,
 ;; `org-element--cache'.  This tree is updated lazily: whenever
-- 
2.26.2