[Q] How to italicize without introducing a space?

2023-03-28 Thread General discussions about Org-mode.
Hello,

I am working on a piece of CJK text, which requires italicization.

--8<---cut here---start->8---
任何一个章节可以通过增加例如 =TODO= 或者 =HOLD= 等关键词来被设置成 /待办/ 。
--8<---cut here---end--->8---

Note the spaces before and after the pair of `?/'.  Without these
spaces, the HTML export does not show "待办" as italicized, but instead
treat them as inline literal `?/' characters, which is expected in
current Org implementation.

Also note that -- unlike English -- Chinese sentences rarely use spaces
(if at all), so showing the space simply because the Org grammar needs
it seems unnatural.

However, I don't immediately see how to resolve the issue natively in
Org.  If we allow `?/' to italicize regardless of spaces, then things
like Unix paths would no longer work.

So, I came up with using LaTeX like this:

--8<---cut here---start->8---
任何一个章节可以通过增加例如 =TODO= 或者 =HOLD= 等关键词来被设置成\(\textit{待办}\)。
--8<---cut here---end--->8---

This has two drawbacks:
1. (network-related?) Delay.  Apparently HTML uses MathJax to render
LaTeX, and my browser experiences a 1-second delay due to it needing to
download JS code from MathJax and doing some processing.
2. Transferability.  This only resolves the issue of /italicization/.
What if I need to underscore or bold a piece of text (likely), or to add
an inline code block with CJK characters (unlikely)?  I would have to
search for how to do each in LaTeX and write the workaround accordingly,
instead of simply using the Org markup syntax for each of them.

Are there any other solutions than what I have currently?

-- 
Best,


RY



[BUG] No font lock in src blocks for shells in org-babel-shell-names (was Re: Font lock for org-babel shell scripts?)

2023-03-28 Thread Matt
Of the shells given in `org-babel-shell-names' (that is, "sh" "bash" "zsh" 
"fish" "csh" "ash" "dash" "ksh" "mksh" "posh"), only "sh" and "bash" have font 
locking in source blocks.

For example,

#+begin_src sh
  if [ -z $TEST ]; then
  echo Fontified
  fi
#+end_src

#+begin_src bash
  if [ -z $TEST ]; then
  echo Fontified
  fi
#+end_src

#+begin_src zsh
  if [ -z $TEST ]; then
  echo No fontification
  fi
#+end_src

#+begin_src fish
  if [ -z $TEST ]; then
 echo No fontification
  fi
#+end_src

#+begin_src csh
  if [ -z $TEST ]; then
  echo No fontification
  fi
#+end_src

#+begin_src ash
  if [ -z $TEST ]; then
  echo No fontification
  fi
#+end_src

#+begin_src dash
  if [ -z $TEST ]; then
  echo No fontification
  fi
#+end_src

#+begin_src ksh
  if [ -z $TEST ]; then
  echo No fontification
  fi
#+end_src

#+begin_src mksh
  if [ -z $TEST ]; then
  echo No fontification
  fi
#+end_src

#+begin_src posh
  if [ -z $TEST ]; then
  echo No fontification
  fi
#+end_src

 Does anyone know which function is responsible for re-fontifing source blocks?



Re: Font lock for org-babel shell scripts?

2023-03-28 Thread Matt


  On Tue, 28 Mar 2023 13:24:39 -0400  Derek Chen-Becker  wrote --- 

 > I'm trying to figure out whether there's a bug or just a misconfiguration on 
 > my end with font lock for org-babel shell source blocks. If I run emacs 28.2 
 > (with -q) and open the following org file, I can evaluate both source blocks 
 > but only the "bash" block has syntax highlighting. I've confirmed that 
 > opening a zsh script (e.g. with a zsh shebang) highlights correctly. If this 
 > list isn't the right place to ask about this issue, does someone know where 
 > I could look for help?

This is the right place to ask.  And thanks for asking!

I'm able to reproduce it.

I'm not familiar with how Org handles the font lock.  However, I notice that 
calling C-c ' (`org-edit-special') results in the error:  No such language 
mode: zsh-mode

I suspect that without a language mode, Org has no way to know how to color the 
block.

As a quick work around, you can define zsh-mode as shell-script-mode to get 
coloring:

(defalias 'zsh-mode 'shell-script-mode)



Font lock for org-babel shell scripts?

2023-03-28 Thread Derek Chen-Becker
Hi,

I'm trying to figure out whether there's a bug or just a misconfiguration
on my end with font lock for org-babel shell source blocks. If I run emacs
28.2 (with -q) and open the following org file, I can evaluate both source
blocks but only the "bash" block has syntax highlighting. I've confirmed
that opening a zsh script (e.g. with a zsh shebang) highlights correctly.
If this list isn't the right place to ask about this issue, does someone
know where I could look for help?

Thanks,

Derek

#+begin_src bash
  if [ -z $TEST ]; then
  echo Good
  fi
#+end_src

#+begin_src zsh
  if [ -z $TEST ]; then
  echo Good
  fi
#+end_src

# Local Variables:
# org-babel-load-languages: ((shell . t))
# End:



-- 
+---+
| Derek Chen-Becker |
| GPG Key available at https://keybase.io/dchenbecker and   |
| https://pgp.mit.edu/pks/lookup?search=derek%40chen-becker.org |
| Fngrprnt: EB8A 6480 F0A3 C8EB C1E7  7F42 AFC5 AFEE 96E4 6ACC  |
+---+


Re: Table not expanded as I expect upon

2023-03-28 Thread Alain . Cochard
Ihor Radchenko writes on Mon 27 Mar 2023 11:19:
 > alain.coch...@unistra.fr writes:
 > 
 > > Maybe it is normal, but if I put the cursor anywhere in the 1st line
 > > (say) of this table
 > >
 > > ||---+---|
 > > || x | x |
 > >
 > > and press , it becomes
 > >
 > > |   | ---+--- |   |
 > > |   | x   | x |
 > >
 > > which is not what I would expect.
 > 
 > This is expected.
 > Only |- at the beginning of the line is seen by Org as horizontal rule.
 > ||-... is an empty cell || followed by a cell |-...|.

Yeah... I should have figured it out by myself.  Thanks a lot for your
time. 

But this got me thinking: I wonder if there is a reasonable/meaningful
use of  either in my above example (with one '|' on the left of
each row) or after inserting a single '|' on the top left position of
the following table

|---+---|
| x | x |

which gives

|   | ---+--- |
| x | x   |

At 1st sight, it does not seem so to me (in particular, LaTeX export
does not turn '---+---' into an horizontal rule for the 2
corresponding columns).  So then one could imagine that '|' at
the beginning of a line starting by '|-' would be interpreted just as
'|-'.  (Not a dramatic improvement, I admit :-)

-- 
EOST (École et Observatoire des Sciences de la Terre) 
ITE (Institut Terre & Environnement) | alain.coch...@unistra.fr
5 rue René Descartes   [bureau 110]  | Phone: +33 (0)3 68 85 50 44 
F-67084 Strasbourg Cedex, France | [ slot available for rent ]




Re: How to suppress generation in export

2023-03-28 Thread Ihor Radchenko
David Diem  writes:

> is there a way to suppress the generation of a ... tag 
> when exporting to html?

That would generate invalid html document.

The relevant comment in our code:

 ;; Set title to an invisible character instead of leaving it
 ;; empty, which is invalid.
 (title (if (org-string-nw-p title) title ""))

See https://lists.gnu.org/archive/html/emacs-orgmode/2017-08/msg6.html

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at .
Support Org development at ,
or support my work at 



[BUG] Shifting timestamp hours around daylight transition (was: Clock dates - org-shiftdown not working)

2023-03-28 Thread Ihor Radchenko
Tebe Nigrelli  writes:

> On a clean configuration, applying org-shiftdown does not work for the
> following date format, written as a clock. I want to reduce the number of
> hours
> on the second date from "03:" to "02:". This is what happens if I apply
> org-shiftdown:
>
> Instructions to reproduce the bug:
> Try doing org-shiftdown on the minutes "05" or the hours "03".
> Result:
> CLOCK: [2023-03-25 Sat 21:40]--[2023-03-26 Sun 03:05] =>  4:25

At least in some parts of Europe, the time from 2023-03-26 2:00 to
2023:03-26 2:59 does not exist. It is the hour-forward daylight
transition.

So, when Org is trying to change the data to 2023-03-26 2:05, Emacs date
library refuses and instead sets the closes valid time.

I am not sure would be the best course of action here.
1. We can jump over the invalid hours in the direction requested by user
2. We can throw an error, making the user aware about the daylight
   thing.

I am more in favour of (2) because things like this are easy to overlook.

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at .
Support Org development at ,
or support my work at 



Re: [BUG] columnview result depends on org-tags-match-list-sublevels [9.5.5 (release_9.5.5 @ /usr/share/emacs/28.2/lisp/org/)]

2023-03-28 Thread Ihor Radchenko
Martin Jambor  writes:

> I have found out that whether sub-headers are included in a columnview
> table depends on org-tags-match-list-sublevels which I hope is a bug
> because it is unexpected and interferes with the columnview
> configuration.

Yes, it does affect columnview and anything that uses tag matching.

Please do not use this variable.
As the docstring of `org-tags-match-list-sublevels' states:

 This variable is semi-obsolete and probably should always be true.  It
 is better to limit inheritance to certain tags using the variables
 org-use-tag-inheritance and org-tags-exclude-from-inheritance.

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at .
Support Org development at ,
or support my work at 



Re: Slightly OT

2023-03-28 Thread Ihor Radchenko
Henrik Frisk  writes:

> I've been having trouble with the deprecated function
> consult-completing-read-multiple being undefined. This happens when I try
> C-c C-c in org-mode to add a tag to a header. I know I fixed this issue on
> my old computer, but not how.

Check your org-ctrl-c-ctrl-c-hook

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at .
Support Org development at ,
or support my work at 



Slightly OT

2023-03-28 Thread Henrik Frisk
IHi,

I've been having trouble with the deprecated function
consult-completing-read-multiple being undefined. This happens when I try
C-c C-c in org-mode to add a tag to a header. I know I fixed this issue on
my old computer, but not how.

Any ideas?

Thanks
/Henrik


Re: File generation from LaTeX src fails due to temporary PDF in wrong directory

2023-03-28 Thread Ihor Radchenko
Christian Moe  writes:

> I'm trying and failing to export images from TikZ code, apparently
> because the temporary PDF is misplaced. Here is a minimal example just
> exporting the PDF:
>
>   #+LATEX_HEADER: \usepackage{tikz}
>
>   #+header: :fit yes
>   #+begin_src latex :exports results :file ./test-tikz-triangle.png
> \begin{tikzpicture} %
>   \draw[draw=black, fill=blue!10] (0,4) -- (3,0) -- (-3,0) -- cycle;
> \end{tikzpicture}
>   #+end_src
>
> Execution fails with an error message like this:
>
>   org-compile-file: File "/tmp/babel-Tay2kl/latex-IJVI84.pdf" wasn’t
>   produced.  See "*Org PDF LaTeX Output*" for details

I cannot reproduce.

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at .
Support Org development at ,
or support my work at 



Re: [Pre-PATCH] Overhaul of the LaTeX preview system

2023-03-28 Thread Tony Zorman
Hi,

> After months of work, Karthink and I have prepared a rather large
> patch-set completely overhauling the LaTeX preview system. I hope to
> have a patch set shortly, but in the mean time it would be good to get
> some more people testing this.

thank you for this!  I've been testing it (from purely a user
perspective) for about a week, and I haven't run into any significant
problems so far.

One nice-to-have thing that I would personally like to see is a
`preview-auto-reveal`-like feature from AUCTeX's preview.el: one can
very precisely control when preview.el unprettifies a rendered LaTeX
fragment.  This is very convenient when, for example, going through a
rendered document by pressing C-n or , as unprettifying in this
case is (at least in my case) a mistake more often than not.

Thanks!
  Tony

-- 
Tony Zorman | https://tony-zorman.com/



Re: [PATCH] Async evaluation in ob-shell

2023-03-28 Thread Ihor Radchenko
Matt  writes:

> -(session (assq :session params)))
> +(sessionp (not (member (cdr (assq :session params)) '("no" 
> "none")
> +(if (and async (not sessionp))
> +  (error (org-babel-eval-error-notify 1 "ERROR: must use 'async' 
> with 'session'")))

This is reasonable, but please do not use `org-babel-eval-error-notify'.
Just a simple `user-error'.

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at .
Support Org development at ,
or support my work at 



Source blocks are indented

2023-03-28 Thread c.buhtz
Hello,

#+begin_src python
  import sys
#+end_src

This example shows a python source block in an org(roam) file. Org
always does an indention here of two spaces.

Is there a way to turn this of?

It seems to me this is not the default behavior because I saw some
youtube videos where there is no indention in such blocks.

I'm using Emacs 27 (from Debian 11) with latest org and org-roam. I
minimized my init.el and still can reproduce it.

;; -*- lexical-binding: t; -*-
(require 'package)
(setq package-archives '(("melpa" . "https://melpa.org/packages/;)
 ("elpa" . "https://elpa.gnu.org/packages/;)))
;; Initializes the package infrastructure
(package-initialize)

;; === use-package ==
;; use-package to simplify the config file
(unless (package-installed-p 'use-package)
  (package-refresh-contents)
  (package-install 'use-package))

(require 'use-package)
(setq use-package-always-ensure 't)

;; === BASIC setup
(set-default-coding-systems 'utf-8)

;; === EVIL
(use-package evil
  :init
  (setq evil-want-integration t)
  (setq evil-want-keybinding nil)
  (setq evil-want-C-i-jump nil)
  :config
  (evil-mode 1)
  ;; Use visual line motions even outside of visual-line-mode buffers
  (evil-global-set-key 'motion "j" 'evil-next-visual-line)
  (evil-global-set-key 'motion "k" 'evil-previous-visual-line)
  ;; Set "normal" vi-mode in specific buffers
  (evil-set-initial-state 'messages-buffer-mode 'normal)
  (evil-set-initial-state 'dashboard-mode 'normal)
  )

(use-package org)



Re: Source blocks are indented

2023-03-28 Thread c.buhtz
I did more research reducing my init.el and looking which line in it
does cause that behavior.

> (package-initialize)

That is the one and only line in my init.el. The behavior is
reproducible with this. Removing the line (init is empty then) the
behavior is not there.

I'm not sure what this command/function does. But I assume something
happens implicit with the packages installed.

What could it be?



Clock dates - org-shiftdown not working

2023-03-28 Thread Tebe Nigrelli
On a clean configuration, applying org-shiftdown does not work for the
following date format, written as a clock. I want to reduce the number of
hours
on the second date from "03:" to "02:". This is what happens if I apply
org-shiftdown:
- On the minutes :: from ":XX" minutes, there is a decrease by the usual
"default" amount (5 minutes), but after reaching "00", the count decreases
to 55 without decreasing the number of hours to "02"
- On the hours   :: "03" does not roll back to "02", but can roll up to "04"
or "05"
- Minutes / Days / Years all work as intended

This bug appears in a scratch buffer in org-mode.
Manually editing the date and applying C-c C-c reverts the "02:" date to
"03:"

Instructions to reproduce the bug:
Try doing org-shiftdown on the minutes "05" or the hours "03".
Result:
CLOCK: [2023-03-25 Sat 21:40]--[2023-03-26 Sun 03:05] =>  4:25

Emacs : GNU Emacs 28.2 (build 2, x86_64-apple-darwin22.1.0, NS
 appkit-2299.00 Version 13.0.1 (Build 22A400)) of 2023-02-05 Package:
 Org mode version 9.5.5 (release_9.5.5 @
 /usr/local/Cellar/emacs-plus@28/28.2/share/emacs/28.2/lisp/org/)

current state:
==
(setq
 org-link-elisp-confirm-function 'yes-or-no-p
 org-bibtex-headline-format-function #[257 "\300\236A\207" [:title] 3
"\n\n(fn ENTRY)"]
 org-export-before-parsing-hook '(org-attach-expand-links)
 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-mode-hook '(#[0 "\300\301\302\303\304$\207"
  [add-hook change-major-mode-hook org-show-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-confirm-shell-link-function 'yes-or-no-p
 outline-isearch-open-invisible-function 'outline-isearch-open-invisible
 org-agenda-before-write-hook '(org-agenda-add-entry-text)
 org-src-mode-hook '(org-src-babel-configure-edit-buffer
org-src-mode-configure-edit-buffer)
 org-confirm-elisp-link-function 'yes-or-no-p
 org-speed-command-hook '(org-speed-command-activate
 org-babel-speed-command-activate)
 org-tab-first-hook '(org-babel-hide-result-toggle-maybe
 org-babel-header-arg-expand)
 org-link-shell-confirm-function 'yes-or-no-p
 org-babel-pre-tangle-hook '(save-buffer)
 org-agenda-loop-over-headlines-in-active-region nil
 org-occur-hook '(org-first-headline-recenter)
 org-metadown-hook '(org-babel-pop-to-session-maybe)
 org-link-parameters '(("attachment" :follow org-attach-follow :complete
org-attach-complete-link)
  ("id" :follow org-id-open)
  ("eww" :follow org-eww-open :store org-eww-store-link)
  ("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
:export org-irc-export)
  ("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)
  ("doi" :follow org-link-doi-open :export
org-link-doi-export)
  ("file+sys") ("file+emacs")
  ("shell" :follow org-link--open-shell)
  ("news" :follow
#[514 "\301\300\302Q\"\207"
 ["news" browse-url ":"] 6 "\n\n(fn URL ARG)"]
)
  ("mailto" :follow
#[514 "\301\300\302Q\"\207"
 ["mailto" browse-url ":"] 6 "\n\n(fn URL ARG)"]
)
  ("https" :follow
#[514 "\301\300\302Q\"\207"
 ["https" browse-url ":"] 6 "\n\n(fn URL ARG)"]
)
  ("http" :follow
#[514 "\301\300\302Q\"\207"
 ["http" browse-url ":"] 6 "\n\n(fn URL ARG)"]
)
  ("ftp" :follow
#[514 "\301\300\302Q\"\207" ["ftp" browse-url ":"]
 6 "\n\n(fn URL ARG)"]
)
  ("help" :follow org-link--open-help :store
org-link--store-help)
  ("file" :complete org-link-complete-file)
  ("elisp" :follow org-link--open-elisp))
 org-metaup-hook '(org-babel-load-in-session-maybe)
 )


Re: Source blocks are indented

2023-03-28 Thread c.buhtz
It is solved.

  (setq org-edit-src-content-indentation 0)

In the first place I used the help system wrong and couldn't find that
variable in my system.



[BUG] columnview result depends on org-tags-match-list-sublevels [9.5.5 (release_9.5.5 @ /usr/share/emacs/28.2/lisp/org/)]

2023-03-28 Thread Martin Jambor
Hello,

I have found out that whether sub-headers are included in a columnview
table depends on org-tags-match-list-sublevels which I hope is a bug
because it is unexpected and interferes with the columnview
configuration.

Please have a look at the attached file which demonstrates the problem.

No configuration necessary, the bug manifests itself when emacs is
executed with -Q.  I was able to observe this with Org mode version
9.5.5 bundled with openSUSE Emacs 28.2 (when invoked as emacs -Q) but
not with Org mode version 9.3 bundled with Emacs 27.1 bundled with
debian bullseye.

Thank you very much for looking at this, please consider CCing me when
discussing the issue because I am not subscribed to the org-mode list.

Martin Jambor




Emacs  : GNU Emacs 28.2 (build 1, x86_64-suse-linux-gnu, GTK+ Version 3.24.35, 
cairo version 1.17.6)
Package: Org mode version 9.5.5 (release_9.5.5 @ 
/usr/share/emacs/28.2/lisp/org/)

#+TITLE:Test for org-tags-match-list-sublevels bug

Use M-x set-variable to set org-tags-match-list-sublevels to nil and
then position the cursor over the BEGIN columnview line and press C-c C-c.
Three lines corresponding to sub-headers of the table will disappear.

I was able to observe this with Org mode version 9.5.5 bundled with
openSUSE Emacs 28.2 (when invoked as emacs -Q) but not with Org mode
version 9.3 bundled with Emacs 27.1 bundled with debian bullseye.


* Header 1
:PROPERTIES:
:COLUMNS:  %40ITEM(Name) %NUM(Number) %2TIME(Time){+}
:ID:   some_tasklist
:END:
#+BEGIN: columnview :hlines 1 :id "some_tasklist" :maxlevel 3 :indent nil
| Name | Number | Time |
|--++--|
| Header 1 ||   20 |
| First|  1 |5 |
| Second   |  2 |5 |
| Third|  3 |   10 |
#+END:
** First
:PROPERTIES:
:NUM:  1
:TIME: 5
:END:
Stuff
** Second
:PROPERTIES:
:NUM:  2
:TIME: 5
:END:
More stuff
** Third
:PROPERTIES:
:NUM:  3
:TIME: 10
:END:
even more stuff


How to suppress generation in export

2023-03-28 Thread David Diem

Hi,

is there a way to suppress the generation of a ... tag 
when exporting to html?


The title of the subtrees I am exporting is not set, the org file-wide 
title is not set either. Setting the file title to nothing (like so: 
#+title: ) does not help either.


I tried setting org-export-with-title to nil and org-html-meta-tags to 
nil, but there remain three lines which I seemingly cannot suppress:


1. 
2. I wish to suppress 1. in order to manually add my  otherwise. 
This question of mine is *not* about the Title


Best wishes
David

Re: [POLL] Should we accept breaking changes to get rid of Org libraries that perform side effects when loading?

2023-03-28 Thread Ihor Radchenko
Max Nikulin  writes:

> On 26/03/2023 00:45, Ihor Radchenko wrote:
>> I am then CCing Bastien, as, despite the Elisp convention, following it
>> will break https://bzg.fr/en/the-software-maintainers-pledge/
>
> I hope, it may be mitigated to some degree, e.g. loading of 
> `org-modules' and `org-babel-load-languages' may include their 
> activation. Perhaps `org-require-package' should activate the loaded 
> package as well.

We often promise in the manual that simple `require' is sufficient.
Not everybody is using `org-modules' mechanism.

Also, `org-require-package' is unrelated. It is specifically designed to
handle third-party packages where we have no control about side effects.

> If it is possible to avoid user prompt in org-ctags then migration may 
> be done in 2 steps separated by a year: add new require helper and do 
> not activate by default. Unsure if it is possible to add some warnings 
> on first step that activate function is not called.

There is no point discussing how to introduce the breaking change.
Making the transition longer will not make it non-breaking.
We first need to decide if we want to go ahead at all.

>> (defun enable-feature (feature  filename noerror)
>>"Load and enable FEATURE.
>> FILENAME and NOERROR arguments are the same as in `require'."
>>(when (require feature filename noerror)
>>  (let ((enabler-cmd (intern (format "%s-enable-function" feature
>>(and (fboundp enabler-cmd) (funcall enabler-cmd)
>
> I would prefer activating on first call only, subsequent calls should be 
> no op.

Sure. I just wanted to point out that it is an easy part to implement
such functionality.

>> (defun disable-feature (feature)
>
> I had a hope that existing `unload-feature' is enough.

`unload-feature' serves different purpose, no?
I am not sure if mixing the two will be welcome by Emacs devs, if we
really want to pursue inclusion this into Emacs.

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at .
Support Org development at ,
or support my work at 



Re: [POLL] Should we accept breaking changes to get rid of Org libraries that perform side effects when loading? (was: org-ctags land grab)

2023-03-28 Thread Ihor Radchenko
"Dr. Arne Babenhauserheide"  writes:

>> This is convincing.
>> I am then CCing Bastien, as, despite the Elisp convention, following it
>> will break https://bzg.fr/en/the-software-maintainers-pledge/
>
> Isn’t the problem that the behavior changed — so that org-ctags gets
> loaded in Emacs 30 but not in Emacs 28 is already an incompatible
> change?

It is a secondary problem.
In earlier Emacs you would get the same side effects if, for example,
you try C-h f org-ctags- .
`help-enable-autoload' is there since Emacs 24.

The root cause of this and similar reported issues (like with org-mouse,
see https://orgmode.org/list/87iliie0j1.fsf@localhost) is optional Org
modules having side effects when loaded.

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at .
Support Org development at ,
or support my work at 



File generation from LaTeX src fails due to temporary PDF in wrong directory

2023-03-28 Thread Christian Moe
Hi,

I'm trying and failing to export images from TikZ code, apparently
because the temporary PDF is misplaced. Here is a minimal example just
exporting the PDF:

  #+LATEX_HEADER: \usepackage{tikz}

  #+header: :fit yes
  #+begin_src latex :exports results :file ./test-tikz-triangle.png
\begin{tikzpicture} %
  \draw[draw=black, fill=blue!10] (0,4) -- (3,0) -- (-3,0) -- cycle;
\end{tikzpicture}
  #+end_src

Execution fails with an error message like this:

  org-compile-file: File "/tmp/babel-Tay2kl/latex-IJVI84.pdf" wasn’t
  produced.  See "*Org PDF LaTeX Output*" for details

It turns out, however, that the missing temporary file, here
latex-IJVI84.pdf, is in fact correctly produced. The problem is that it
is produced in the same directory as the source org file, not in the
temp directory.

I've had a quick look at org-compile-file, but don't understand what is
going wrong.

I'm running Org 9.6.2 on GNU Emacs 27.2 under Linux Mint, all very
vanilla.

Any suggestions?

Yours,
Christian