[O] org-store/insert-link truncating the full subject of mails

2018-10-25 Thread Garreau, Alexandre
Why so?

It shouldn’t be this way by default.

I tried to link
“[[gnus:nnml:lists.gnu.emacs-orgmode#87in1rkqlk@gmail.com][Email
from Tim Cross: Re: {O} Ox-html: Replace  with  and  with
]]” and after org-store-link in appropriated buffer, org-insert-link
gave me “Email from Tim Cross: Re: {O} Ox-html: Replace  w”.



[O] *markup*, /markup/ and _markup_ true semantics [Was: Re: Ox-html: Replace with and with ]

2018-10-25 Thread Garreau, Alexandre
Sorry, just found out that interesting (to me) thread I shouldn’t have
let go:

On 2018-10-25 at 08:00, Tim Cross wrote:
> Kaushal Modi  writes:
>> […]
>> - b and i are not deprecated
>> - b and strong are both valid but their use depends on the writer's
>> context (but Org mode has just one mark for either "*")
>> - i and em are both valid but their use depends on the writer's
>> context (but Org mode has just one mark for either "/").
>>
>> […]
>> 
>> From "em" docs[em], in the NOTE section there:
>>> The em element isn’t a generic "italics" element. Sometimes, text
>>> is intended to stand out from the rest of the paragraph, as if it
>>> was in a different mood or voice. For this, the i element is more
>>> appropriate.
>>
>> […]
>>
>> I guess there's no need to change what "*" and "/" do right now in
>> ox-html, as there doesn't seem "one right way" to do things here.
>>
>> And folks strongly wanting to use  and  for bold and
>> italic can customize org-html-text-markup-alist.
>>
>> HTML experts, please chime in.
>
> I'll start by stating I'm definitely not an HTML expert.

I don’t exactely know what an expert is, at least I’m not a
professional, but I have passed some time figuring out various HTML
specs semantic meaning.

More especially, I’ve a big interest in semantics and typography, and
past many time on my now deleted-crecreated-then-lost github account,
and mail, to convince people to switch to more semantical markuping (oh,
and to use complex CSS selectors rather than classes, and stop using
 and  at all) and better typography (such as curly quotes,
simple quotes inside quotes, and many things specific to french).

> The problem with b and i is that they specify how rather than what and
> don't always make sense for all possible media types. For example, what
> does 'bold' or 'italic' mean for a screen reader?

Italic means often pronounced with a different pitch afair.  Bold
probably means prounced differently too but I don’t know how this is
pronounced iirc.  I need to recheck with orca and firefox addons (I’ll
do for a next mail).  That might be change accross screenreaders so I
might have to find some friend having a windows computer with NVDA, JAWS
or some other non-free program to either ask or check.

I believe the most correct handling for screen readers would be to use
the appropriate language from the attribute lang or xml:lang of  tag,
otherwise slower and slightly higher pitch, and for  the exact same
higher pitch as caps, without changing speed, plus adding it to an
easily reachable “keyword-list”, just as .

Fyi : both italic, bold, and underline, have been invented in typography
as special ways of *purposely* making text harder to read.  Both the
intent and result is that the reader taking more time to read something
in italic, for instance, will memorize it better, and have more free
time to think about it, hence increasing the importance of this
something.

In the following “from far” means when you look at the global document
and are not focusing reading a particular part of it.  It doesn’t mean
you are at a far distance and you can still read it, like it is for
uppercase.

Italic is the best way, the most readable, as it’s only seen when
reading, near the text, but not “from far” and doesn’t break structure,
flowing, or “typographic grey” (“gris typographique”, I’m not aware of
the english term).  It is hence commonly used for emphasis (best usage:
if ever it gets long, it gets hard to read, but that reflects the fact
original meaning was hard to grasp or hear or say originally), citation
of artistical work names (such as books: conventional usage, but still
okay, as these are mostly short anyway), and quotations (discouraged
usage as they can get long (and thus unreadable) and quote marks cover
this, *not* to be used *along* with them, never, as it is terribly
redundant and almost no serious professional printer do that).

Bold is sometimes harder to read, and sometimes, if not too bold,
easier, however it’s really easy to “notice” its text from looking afar:
therefore it’s normally *exclusively* recommanded for text structures,
whose *role* is to purposely cut in parts the text, that is: *outlines*.
However, in an attempt of pseudo-backward compatibility and “but look
everybody was okay since the beginning”, by the W3C, another usage for
bold than in outlines has been found: keywords.  These are *meant* to be
seen from far, are usually small (one word), and yet wouldn’t alter text
structure, and might not be candidate for  (however most time they
should).

Underline is to be banned from everywhere, theorically.  It is an
especially simple and awful way of making text unreadable: it cuts the
legs of non-zero-ascent letters (making as hard to read as italic) *and*
is easy to lookup from far, yet you can notice the underline without
having the word easily and quickly grasped when seen from far, like
bold.  Iirc it has been invented for typewriters because italic wasn’t

Re: [O] [PATCH] migrate ob-clojure initiate session code from ob-clojure-literate.el into ob-clojure.el

2018-10-25 Thread stardiviner


Nicolas Goaziou  writes:

>> 6 unexpected results:
>>FAILED  ob-D/inhomogeneous_table
>>FAILED  ob-D/list-list-var
>>FAILED  ob-D/list-var
>>FAILED  ob-D/vector-var

Test ob-D/inhomogeneous_table backtrace:
  signal(ert-test-failed (((should (equal '(("monday" 34) ("tuesday" 4
  ert-fail(((should (equal '(("monday" 34) ("tuesday" 41) ("wednesday"
  (if (unwind-protect (setq value-94 (apply fn-92 args-93)) (setq form
  (let (form-description-96) (if (unwind-protect (setq value-94 (apply
  (let ((value-94 'ert-form-evaluation-aborted-95)) (let (form-descrip
  (let* ((fn-92 (function equal)) (args-93 (condition-case err (let ((
  (save-restriction (org-babel-next-src-block 2) (let* ((fn-92 (functi
  (progn (org-id-goto "e112bc2e-419a-4890-99c2-7ac4779531cc") (setq to
  (unwind-protect (progn (org-id-goto "e112bc2e-419a-4890-99c2-7ac4779
  (let ((save-match-data-internal (match-data))) (unwind-protect (prog
  (progn (let ((save-match-data-internal (match-data))) (unwind-protec
  (unwind-protect (progn (let ((save-match-data-internal (match-data))
  (let ((wconfig (current-window-configuration))) (unwind-protect (pro
  (unwind-protect (let ((wconfig (current-window-configuration))) (unw
  (let* ((id-location (org-id-find "e112bc2e-419a-4890-99c2-7ac4779531
  (if (executable-find org-babel-D-compiler) (let* ((id-location (org-
  (lambda nil (if (executable-find org-babel-D-compiler) (let* ((id-lo
  ert--run-test-internal(#s(ert--test-execution-info :test #s(ert-test
  ert-run-test(#s(ert-test :name ob-D/inhomogeneous_table :documentati
  ert-run-or-rerun-test(#s(ert--stats :selector "\\(org\\|ob\\)" :test
  ert-run-tests("\\(org\\|ob\\)" #f(compiled-function (event-type 
  ert-run-tests-batch("\\(org\\|ob\\)")
  ert-run-tests-batch-and-exit("\\(org\\|ob\\)")
  (let ((org-id-track-globally t) (org-test-selector (if org-test-sele
  org-test-run-batch-tests("\\(org\\|ob\\)")
  eval((org-test-run-batch-tests org-test-select-re))
  command-line-1(("--eval" "(setq vc-handled-backends nil org-startup-
  command-line()
  normal-top-level()
Test ob-D/inhomogeneous_table condition:
(ert-test-failed
 ((should
   (equal '...
(org-babel-execute-src-block)))
  :form
  (equal
   (("monday" 34)
("tuesday" 41)
("wednesday" 56)
("thursday" 17)
("friday" 12)
("saturday" 7)
("sunday" 4)
("Friday" "friday"))
   nil)
  :value nil :explanation
  (different-types
   (("monday" 34)
("tuesday" 41)
("wednesday" 56)
("thursday" 17)
("friday" 12)
("saturday" 7)
("sunday" 4)
("Friday" "friday"))
   nil)))
   FAILED   12/814  ob-D/inhomogeneous_table
executing D code block (integer_var)...
"12"
   passed   13/814  ob-D/integer-var
executing D code block (list_list_var)...
Babel evaluation exited with code 1
nil
Test ob-D/list-list-var backtrace:
  signal(ert-test-failed (((should (equal '((1 3) (2 4)) (org-babel-ex
  ert-fail(((should (equal '((1 3) (2 4)) (org-babel-execute-src-block
  (if (unwind-protect (setq value-84 (apply fn-82 args-83)) (setq form
  (let (form-description-86) (if (unwind-protect (setq value-84 (apply
  (let ((value-84 'ert-form-evaluation-aborted-85)) (let (form-descrip
  (let* ((fn-82 (function equal)) (args-83 (condition-case err (let ((
  (save-restriction (org-babel-next-src-block 6) (let* ((fn-82 (functi
  (progn (org-id-goto "cc65d6b3-8e8e-4f9c-94cd-f5a00cdeceb5") (setq to
  (unwind-protect (progn (org-id-goto "cc65d6b3-8e8e-4f9c-94cd-f5a00cd
  (let ((save-match-data-internal (match-data))) (unwind-protect (prog
  (progn (let ((save-match-data-internal (match-data))) (unwind-protec
  (unwind-protect (progn (let ((save-match-data-internal (match-data))
  (let ((wconfig (current-window-configuration))) (unwind-protect (pro
  (unwind-protect (let ((wconfig (current-window-configuration))) (unw
  (let* ((id-location (org-id-find "cc65d6b3-8e8e-4f9c-94cd-f5a00cdece
  (if (executable-find org-babel-D-compiler) (let* ((id-location (org-
  (lambda nil (if (executable-find org-babel-D-compiler) (let* ((id-lo
  ert--run-test-internal(#s(ert--test-execution-info :test #s(ert-test
  ert-run-test(#s(ert-test :name ob-D/list-list-var :documentation "Te
  ert-run-or-rerun-test(#s(ert--stats :selector "\\(org\\|ob\\)" :test
  ert-run-tests("\\(org\\|ob\\)" #f(compiled-function (event-type 
  ert-run-tests-batch("\\(org\\|ob\\)")
  ert-run-tests-batch-and-exit("\\(org\\|ob\\)")
  (let ((org-id-track-globally t) (org-test-selector (if org-test-sele
  org-test-run-batch-tests("\\(org\\|ob\\)")
  eval((org-test-run-batch-tests org-test-select-re))
  command-line-1(("--eval" "(setq vc-handled-backends nil org-startup-
  command-line()
  normal-top-level()
Test ob-D/list-list-var condition:
(ert-test-failed
 ((should
   (equal '...
(org-babel-execute-src-block)))
  :form
  (equal
   ((1 3)
(2 4))
   nil)
  

Re: [O] electric-pair, autopair, smartparens, etc in org-mode

2018-10-25 Thread Samuel Wales
oh i got that slightly wrong.  i meant can you give exmaples of what
yoa re saying.



Re: [O] electric-pair, autopair, smartparens, etc in org-mode

2018-10-25 Thread Samuel Wales
can either of you give examples of code or settings that you had that
made behavior of new modes unpredictable because emacs started
supporting the behavior you made the code or settings for?


On 10/25/18, Eric S Fraga  wrote:
> On Thursday, 25 Oct 2018 at 08:24, Tim Cross wrote:
>> Likewise, started with Emacs 19 and I still have some code which I added
>> back then in my init!
>
> [...]
>
>> The two big benefits from the clean up have been much faster start up
>> (something which never really bothered me as I run emacs for weeks
>> without re-starting anyway) and far more predictable behaviour when I
>> try out or add a new mode (I often found my custom tweaks would not
>> always work well with new modes etc).
>
> The second of these is indeed a benefit of cleaning up initialization
> files.  I have been doing so, in any case, just at a slower pace than I
> should.  I actually have been doing exactly what you suggest: using org
> and tangling.
> --
> Eric S Fraga via Emacs 27.0.50, Org release_9.1.13-894-gf79545
>
>


-- 
The Kafka Pandemic: 

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

"You’ve really gotta quit this and get moving, because this is murder
by neglect." ---
.



Re: [O] org-babel-execute:go crashes on Mac

2018-10-25 Thread Neil Jerram
Mario Martelli  writes:

> Thank you for your answer. 
>
>> If you haven't already, I suggest checking that there isn't a difference in 
>> your Go setup, by working out the "go run ..." command that is being run 
>> below, and running that manually yourself.
>
> My first assumption was - to be honest, still is - that the "go run …” is not 
> executed at all because the call to “go run …”  is within an illegal elisp 
> function. Am I wrong with my assumption?
>
> Kind regards
> Mario
>
> P.S. Would have no idea how to work out what the outcome of the function is ;)

Perhaps I misunderstood the error message, but I thought perhaps it was
about code trying to represent the _result_ of the execution as an elisp
function.  But it is very difficult to tell!

I guess if I had this on my system (which I can't because I don't run on
a Mac), I'd use 'edebug-defun' on some of the functions involved in the
error message, in order to start understanding whether they are actually
being executed.

Best wishes,
   Neil



Re: [O] org-babel-execute:go crashes on Mac

2018-10-25 Thread Mario Martelli
Thank you for your answer. 

> If you haven't already, I suggest checking that there isn't a difference in 
> your Go setup, by working out the "go run ..." command that is being run 
> below, and running that manually yourself.

My first assumption was - to be honest, still is - that the "go run …” is not 
executed at all because the call to “go run …”  is within an illegal elisp 
function. Am I wrong with my assumption?

Kind regards
Mario

P.S. Would have no idea how to work out what the outcome of the function is ;)

Re: [O] Display-level automatic subtree numbering

2018-10-25 Thread Nicolas Goaziou
Hello,

"Garreau, Alexandre"  writes:

> Le 24/10/2018 à 13h40, Nicolas Goaziou a écrit :
>> But you don't need to number the whole buffer, do you?
>
> At least the screen.
>
>> A breadcrumb like feature could be enough. E.g., you hit  at the
>> beginning of a headline and get the numbering in addition to the
>> outline path.
>
> I’d prefer.  I find sad that all export backend supports this while raw
> emacs doesn’t.

Output from export back-ends is static. A currently-edited Org document
isn't.

> It is neat to see, and to, just by looking at the
> screen, which section has which number.

You may be interested in "org-outline-numbering" package, then. It seems
to implement what you want.

HTH,

-- 
Nicolas Goaziou



Re: [O] electric-pair, autopair, smartparens, etc in org-mode

2018-10-25 Thread Eric S Fraga
On Thursday, 25 Oct 2018 at 08:24, Tim Cross wrote:
> Likewise, started with Emacs 19 and I still have some code which I added
> back then in my init!

[...]

> The two big benefits from the clean up have been much faster start up
> (something which never really bothered me as I run emacs for weeks
> without re-starting anyway) and far more predictable behaviour when I
> try out or add a new mode (I often found my custom tweaks would not
> always work well with new modes etc).

The second of these is indeed a benefit of cleaning up initialization
files.  I have been doing so, in any case, just at a slower pace than I
should.  I actually have been doing exactly what you suggest: using org
and tangling.
-- 
Eric S Fraga via Emacs 27.0.50, Org release_9.1.13-894-gf79545



Re: [O] org-mode: Would like to add custom chars as org-list bullets

2018-10-25 Thread Colin Baxter
> Grant Rettke  writes:

> On Sat, Oct 13, 2018 at 1:56 AM Colin Baxter  wrote:
>> 
>> > Tom Burbage  writes:
>> 
>> > When I use simple lists, I would like to be able to mix in '!'
>> and > '?'  with '-' as these are sometimes more expressive of
>> what the > list item represents.  My request is that the list of
>> characters > org-list recognizes as being a valid "bullet" be
>> customizable by > the user.
>> 
>> Have a look at
>> 
https://emacs.stackexchange.com/questions/35626/how-to-make-my-own-org-mode-text-emphasis-work-again.

> Which code are you recommending?

I'm not recommending anything. I'm suggesting that if you want
one or more characters in a list to act as emphasis then perhaps they
could be defined in terms of org-font-lock-extra-keywords, as in 'Answer
2'.

Best wishes,



Re: [O] [feature proposal] Export in foreign buffers - ASCII (ox-ascii)

2018-10-25 Thread Alexander Adolf
Hello Nicolas,

On 2018-10-25, at 16:56 , Nicolas Goaziou  wrote:

> [...]
> I added the functions to "ox-ascii.el", with an autoload cookie,
> a simplified docstring, and an entry in the manual.
> [...]

Wow, many thanks for being so kind as to include them! That was faster and way 
easier than I had anticipated. ;-))

Many thanks again!

  --alexander




Re: [O] [feature proposal] Export in foreign buffers - ASCII (ox-ascii)

2018-10-25 Thread Nicolas Goaziou
Hello,

Alexander Adolf  writes:

> --
> (defun org-ascii-convert-region-to-ascii ()
>   "Assume the current region has Org syntax, and convert it to
> plain ASCII. This can be used in any buffer. For example, you
> could write an itemized list or a table in Org syntax in a mail
> buffer and then use this command to convert it."
>   (interactive)
>   (let ((org-ascii-charset 'ascii))
> (org-export-replace-region-by 'ascii)))
>
> (defun org-ascii-convert-region-to-utf8 ()
>   "Assume the current region has Org syntax, and convert it to
> UTF-8. This can be used in any buffer. For example, you could
> write an itemized list or a table in Org syntax in a mail buffer
> and then use this command to convert it."
>   (interactive)
>   (let ((org-ascii-charset 'utf-8))
> (org-export-replace-region-by 'ascii)))
> --

I added the functions to "ox-ascii.el", with an autoload cookie,
a simplified docstring, and an entry in the manual.

Thank you.

Regards,

-- 
Nicolas Goaziou



[O] org-mime with recent versions of org and emacs

2018-10-25 Thread Matt Price
I had some problems with the MELPA version of org-mime, and wasn't able to
solve my issues using the current version. I've rebased off of a PR
submitted to the upstream repo by John Kitchin. Core org-mime functions
once again work for me and I've added a couple of new features:

- mu4e support
- initial, primitive support for blockquoting paragraphs that start with
">" -- this is pretty ugly right now but maybe it will be possible to
improve later on.

My tree is here: https://github.com/titaniumbones/org-mime/tree/file-eqns
I'm developing against recent git versions of org and emacs.
I'd love to hear comments from others.

On Sun, Oct 21, 2018 at 10:04 PM Matt Price  wrote:

> I'm having a whole bunch of trouble getting org-mime to work, and I
> wondered ifo ther people are using it productively?
>
> Two biggest issues so far, both reproduced with emacs -Q on recent emacs
> git, org-mode git, and org-mime git:
>
> - org-mime-org-subtree-htmlize fails for me with "org-back-to-heading:
> before first heading"
> - org-mime-org-buffer-htmlize runs successfully, but only produces the
> html mime part; the text/plain message part is empty.
>
> org-mime-htmlize, when run in a mail buffer, still seems to work & produce
> a 2-part message with text/plain and text/html working well.
>
> Have folks seen this before & do you have a fix? thank you!
>
>


Re: [O] Bug: org-string-display throws on image display property [9.1.9 (release_9.1.9-65-g5e4542 @ /home/blc/.local/share/emacs/27.0.50/lisp/org/)]

2018-10-25 Thread Nicolas Goaziou
Hello,

"Basil L. Contovounesios"  writes:

> I realise that the 'display' property is a pretty complicated beast, so
> it may be impractical for 'org-string-width' to do this, but I think
> more accurate/useful behaviour would be to calculate the displayed width
> of the image via 'image-size' or 'image-display-size', rather than
> signalling an error.

Fixed. `org-string-width' has now a limited support for images.

Thank you.

Regards,

-- 
Nicolas Goaziou



Re: [O] An Org-based productivity tool

2018-10-25 Thread Ihor Radchenko
FYI

"Note taker and org-clock-in enforcer"
https://github.com/roman/clocker.el

Best,
Ihor

Marcin Borkowski  writes:

> Hi Orgers,
>
> I am making an Org-mode-based tool to help boost my productivity.
>
> I am constantly fighting a losing battle with distractions.  I figured
> out that showing me how much time I spent goofing around would help me
> stay on track (being a math geek and a gamer, my "let's break my
> yesterday's score" and similar instincts kick in immediately, too).  So
> far, I have these in my prototype:
>
> - a notification (recurring every n seconds) that I'm not clocking
>   anything,
>
> - some stats about what I spent my time on and what my efficiency (i.e.,
>   percentage of time I spent working from the point when I started
>   counting to now) is,
>
> - info about how much work I need to do in order to meet my set goal,
>   and how much will it take if my efficiency remains constant,
>
> - a warning when my efficiency is lower than a set value, and info about
>   how much work I need to do to bump it up to that value.
>
> Here's an example output (with some partially faked data):
>
> --8<---cut here---start->8---
> 39min of your workday (10%) has passed, and you have 5h 31min left.
>
> work - 30min spent (12% of your goal of 4h and 75% of your workday so far)
>3h 30min remaining (4h 39min with your current efficiency of 75%).
>You need 9min of uninterrupted work to get back to 80% efficiency.
>
> eating - 4min spent (10% of your workday so far)
>
> bathroom - 2min spent (5% of your workday so far)
>
> unclassified - 0min spent (0% of your workday so far)
>
> Unclocked time so far: 3min.
> --8<---cut here---end--->8---
>
> My questions are:
>
> - is anyone interested in something like this?
>
> - are there any features you would like to have?  (I have some ideas,
>   too.)
>
> - does anyone have an idea of how to /name/ this project?
>
> TIA,
>
> --
> Marcin Borkowski
> http://mbork.pl
>


signature.asc
Description: PGP signature


Re: [O] [PATCH] migrate ob-clojure initiate session code from ob-clojure-literate.el into ob-clojure.el

2018-10-25 Thread Nicolas Goaziou
Hello,

stardiviner  writes:

> Hi, Nicolas. I fixed those warning. I think this should be a feature.
> not a patch.

Applied in "next", then. Thank you.

> And run `make test`. Here is the result:

[...]

> executing Vala source code block
> Code block evaluation complete.
>passed  138/814  ob-vala/static-output
>failed  139/814  org-missing-dependency/test-ob-R
>failed  140/814  org-missing-dependency/test-ob-clojure
>failed  141/814  org-missing-dependency/test-ob-lua
>failed  142/814  org-missing-dependency/test-ob-maxima
>failed  143/814  org-missing-dependency/test-ob-plantuml
>failed  144/814  org-missing-dependency/test-ob-ruby
>failed  145/814  org-missing-dependency/test-ob-scheme
>failed  146/814  org-missing-dependency/test-org-attach-annex
>failed  147/814  org-missing-dependency/test-org-protocol

This is expected.

> 6 unexpected results:
>FAILED  ob-D/inhomogeneous_table
>FAILED  ob-D/list-list-var
>FAILED  ob-D/list-var
>FAILED  ob-D/vector-var
>FAILED  test-org-clock/clocktable/lang
>FAILED  test-org-colview/columns-width

I cannot reproduce it. Could you show the full output of these errors?

Thank you.

Regards,

-- 
Nicolas Goaziou



Re: [O] ob-core.el macro org-babel-comint-with-output has error

2018-10-25 Thread Nicolas Goaziou
Hello,

stardiviner  writes:

> stardiviner  writes:
>
>> When I try to evaluate js src block code with session.
>> I found it is suspended. After edebug, found the problem is on macro 
>> org-babel-comint-with-output.
>>
>> Here is a minimal reproduce code:
>>
>> #+begin_src emacs-lisp
>> (org-babel-comint-with-output
>> ("*skewer-repl*" (format "%S" org-babel-js-eoe) t "x.innerHTML=\"Hello, 
>> Welcome!\";")
>>   (mapc
>>(lambda (line)
>> (insert (org-babel-chomp line))
>> (comint-send-input nil t))
>>(list "x.innerHTML=\"Hello, Welcome!\";" (format "%S" org-babel-js-eoe
>> #+end_src
>>
>> Hope someone can fix it. I can't help on elisp macro
>
> Anyone can help me on this?
>
> Why this email does not have any reply?

Probably because no one could help you. In my case, this is not
a complete example and I don't use javascript, so I cannot try to
reproduce it.

You could try to macroexpand `org-babel-comint-with-output' and see
where the problem is.

Regards,

-- 
Nicolas Goaziou



Re: [O] org-babel-execute:go crashes on Mac

2018-10-25 Thread Neil Jerram
If you haven't already, I suggest checking that there isn't a difference in 
your Go setup, by working out the "go run ..." command that is being run below, 
and running that manually yourself.


On 25 October 2018 05:28:53 BST, Mario Martelli  
wrote:
>Morning,
>
>recently I tried to use ob-go and ran immediately into:
>
>org-babel-execute:go: Invalid function: (results (org-babel-eval
>(format "%s run %s \"%s\" %s" org-babel-go-command (mapconcat (quote
>identity) (org-babel-go-as-list flags) " ")
>(org-babel-process-file-name tmp-src-file) (mapconcat (function (lambda
>(a) (format "%S" (if (symbolp a) (let* (... ...) (if ... ... out))
>a (org-babel-go-as-list args) " ")) ""))
>
>The strange thing is, that this only happens on my Mac. On my CentOS
>machine it works like a charm. Both machines run on Emacs 26.1b1 and
>org mode 9.1.9-65-g5e454. All packages are from Melpa and the machines
>share the same .emacs.
>
>I have no idea how to get to the bottom of this phenomenon. Any hint or
>help would be appreciated very much.
>
>Thank you
>Mario
>
>— 


Re: [O] Inline code block syntax highlighting absence

2018-10-25 Thread Garreau, Alexandre
On 2018-10-25 at 12:12, stardiviner wrote:
> Nicolas Goaziou  writes:
>> Would you want to provide a patch for that?
>>
>> Thank you.
>>
>> Regards,
>
> I did a search of "font-lock-add-keywords", "begin_src", "src_" etc in
> Org Mode source code, but have not found exact place where fontify
> function are. So I don't know where to modify the source code. Now I put
> my current config here:

I found `org-src-font-lock-fontify-block' in the middle of “org-src.el”
(is that the place you wanted?), which I found in “org.el” which I found
after searching with “C-h f” a function containing “org-[POINT]font” and
TAB, so I quickly searched for “font-lock”, “begin_”, and “src”, alone.

I have the impression org doesn’t use `add-keywords' at all and just use
setq in org-set-font-lock-defaults so to bind keywords list.



Re: [O] ob-core.el macro org-babel-comint-with-output has error

2018-10-25 Thread stardiviner


stardiviner  writes:

> When I try to evaluate js src block code with session.
> I found it is suspended. After edebug, found the problem is on macro 
> org-babel-comint-with-output.
>
> Here is a minimal reproduce code:
>
> #+begin_src emacs-lisp
> (org-babel-comint-with-output
> ("*skewer-repl*" (format "%S" org-babel-js-eoe) t "x.innerHTML=\"Hello, 
> Welcome!\";")
>   (mapc
>(lambda (line)
>  (insert (org-babel-chomp line))
>  (comint-send-input nil t))
>(list "x.innerHTML=\"Hello, Welcome!\";" (format "%S" org-babel-js-eoe
> #+end_src
>
> Hope someone can fix it. I can't help on elisp macro

Anyone can help me on this?

Why this email does not have any reply? Maybe because my old invalid
mu4e message sign configuration?

--
[ stardiviner ]
   I try to make every word tell the meaning what I want to express.
   Blog: https://stardiviner.github.io/
   IRC(freenode): stardiviner
   GPG: F09F650D7D674819892591401B5DF1C95AE89AC3



Re: [O] [PATCH 2/4] ob-clojure.el: Add ClojureScript interface

2018-10-25 Thread stardiviner


roberthambr...@gmail.com writes:

> From: Robert Hambrock 
>
> * lisp/ob-clojure.el (org-babel-execute:clojure): Implemented :target,
> which allows selection of connection.
> * lisp/ob-clojure.el (org-babel-execute:clojurescript): New
> ClojureScript interface that uses :target flag to specify `cljs`
> evaluation target.
> ---
>  lisp/ob-clojure.el | 10 +++---
>  1 file changed, 7 insertions(+), 3 deletions(-)
>
> diff --git a/lisp/ob-clojure.el b/lisp/ob-clojure.el
> index 93674b552..7f7c24ff1 100644
> --- a/lisp/ob-clojure.el
> +++ b/lisp/ob-clojure.el
> @@ -129,7 +129,8 @@ using the :show-process parameter."
>(cider
> (require 'cider)
> (let ((result-params (cdr (assq :result-params params)))
> -  (show (cdr (assq :show-process params
> +  (show (cdr (assq :show-process params)))
> +  (connection (cider-current-connection (cdr (assq :target 
> params)
>   (if (member show '(nil "no"))
>;; Run code without showing the process.
>(progn
> @@ -137,7 +138,7 @@ using the :show-process parameter."
>(let ((nrepl-sync-request-timeout
>   org-babel-clojure-sync-nrepl-timeout))
>  (nrepl-sync-request:eval expanded
> - (cider-current-connection
> + connection)))
>  (setq result
>(concat
> (nrepl-dict-get response
> @@ -171,7 +172,7 @@ using the :show-process parameter."
>   (nrepl--merge response resp)
>   ;; Update the status of the nREPL output session.
>   (setq status (nrepl-dict-get response "status")))
> -   (cider-current-connection))
> +   connection)
>
>;; Wait until the nREPL code finished to be processed.
>(while (not (member "done" status))
> @@ -211,6 +212,9 @@ using the :show-process parameter."
>(condition-case nil (org-babel-script-escape result)
>   (error result)
>
> +(defun org-babel-execute:clojurescript (body params)
> +  (org-babel-execute:clojure body (cons '(:target . "cljs") params)))
> +
>  (provide 'ob-clojure)
>
>  ;;; ob-clojure.el ends here

Hi, @roberthambrock. I would like to have ob-clojure support
ClojureScript too. But seems this patch is not merged yet, for a long
time. Can I modify this patch and send to Org Mode? @Nicolas, can I do
this? set Git commit author as "roberthambrock", and commiter as me.

--
[ stardiviner ]
   I try to make every word tell the meaning what I want to express.
   Blog: https://stardiviner.github.io/
   IRC(freenode): stardiviner
   GPG: F09F650D7D674819892591401B5DF1C95AE89AC3