all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Max Nikulin <manikulin@gmail.com>
To: emacs-orgmode@gnu.org
Subject: Re: [patch] Fixes and improvements in org-latex-language-alist (was: ox-latex language handling in Org-9.5 vs 9.6)
Date: Tue, 12 Sep 2023 22:22:00 +0700	[thread overview]
Message-ID: <udpvmr$lt8$1@ciao.gmane.io> (raw)
In-Reply-To: <878r9biwwm.fsf@localhost>

On 12/09/2023 16:05, Ihor Radchenko wrote:
> Max Nikulin writes:
> 
>> Every piece of code accessing this public constant must implement
>> fallback from e.g. "de-ch" (or de_CH) to "de". Or to "en" for an
>> unsupported language.
> 
> Not necessarily. I mostly thought about some unconventional code that
> uses the constant for some reason unexpected to us. We do not want to
> break that.

My point is that direct usage of `org-latex-language-alist' should be 
discouraged.

>> This languange-region identifiers may be written in different way
>> (dash/underscore, case), but they are used specify POSIX locale LANG,
>> LC_* and extensions like LANGUAGE, so in some cases human friendly names
>> may be less convenient.
> 
> Sorry, but I do not follow you about the downsides of "human friendly" names.

I am not against them for the "#+language" keyword (however I am unsure 
concerning e.g. human variant for de_IT). In the code I would prefer 
ll_RR locale identifiers as a widely accepted practice.

>>> Though I am not sure if we can easily handle tricky
>>> cases like weird installation directory for TeXLive or MikTeX.
>>
>> kpsewhich babel-de.ini
> 
> which may not be in the PATH.

 From my point of view it is a call to trouble. E.g. I have no idea how 
to determine if LuaLaTeX is installed. Notice that in Debian the 
executable file is provided by

     texlive-latex-base: /usr/bin/lualatex

while actually texlive-luatex must be installed to make lualatex usable. 
Unsure if there is a better way than

     kpsewhich -engine luahbtex lualatex.fmt

and I am not sure that this particular command is reliable enough.

Moreover kpsewhich may help to detect if some packages are available for 
export or a fallback to less advanced ones should be used instead.

>> /usr/share/texlive/texmf-dist/tex/generic/babel/locale/de/babel-de.ini
> 
> which is not true on Guix, or when installed under /opt via make install.

It is the exact reason to use kpsewhich. Besides install paths it 
respects TEXMF environment variables that may additional user-specific 
directories to search path.

> I did not mean the conventional distros that follow conventional naming
> schemes, but the edge cases - I see no point adding automation just to
> fight various non-standard user installations later. It will not make
> maintenance any easier.

I am considering generating of some locale data on a developer machine 
that has all necessary packages installed. In general I am against 
storing of autogenerated files in git, but in this case it may have sense.




  reply	other threads:[~2023-09-12 16:45 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-09-06 14:55 ox-latex language handling in Org-9.5 vs 9.6 Max Nikulin
2023-09-06 22:20 ` Juan Manuel Macías
2023-09-07 10:38   ` Max Nikulin
2023-09-07 11:50   ` Ihor Radchenko
2023-09-07 14:19     ` Juan Manuel Macías
2023-09-07 14:49       ` Max Nikulin
2023-09-08 10:30         ` Max Nikulin
2023-09-08 14:42           ` Juan Manuel Macías
2023-09-08 19:02             ` [patch] Fixes and improvements in org-latex-language-alist (was: ox-latex language handling in Org-9.5 vs 9.6) Juan Manuel Macías
2023-09-09  9:11               ` Ihor Radchenko
2023-09-09 10:36                 ` [patch] Fixes and improvements in org-latex-language-alist Juan Manuel Macías
2023-09-09 11:33                   ` Ihor Radchenko
2023-09-09 23:59                     ` Juan Manuel Macías
2023-09-10  7:55                       ` Ihor Radchenko
2023-09-10 11:06                         ` Juan Manuel Macías
2023-09-10 13:36                           ` Ihor Radchenko
2023-09-10 16:15                 ` [patch] Fixes and improvements in org-latex-language-alist (was: ox-latex language handling in Org-9.5 vs 9.6) Max Nikulin
2023-09-10 16:52                   ` Ihor Radchenko
2023-09-10 21:15                     ` [patch] Fixes and improvements in org-latex-language-alist Juan Manuel Macías
2023-09-11  8:32                       ` Ihor Radchenko
2023-09-11 17:06                     ` [patch] Fixes and improvements in org-latex-language-alist (was: ox-latex language handling in Org-9.5 vs 9.6) Max Nikulin
2023-09-12  9:05                       ` Ihor Radchenko
2023-09-12 15:22                         ` Max Nikulin [this message]
2023-09-12 18:12                           ` [patch] Fixes and improvements in org-latex-language-alist Juan Manuel Macías
2023-09-15  9:54                             ` Ihor Radchenko
2023-09-15  9:51                           ` [patch] Fixes and improvements in org-latex-language-alist (was: ox-latex language handling in Org-9.5 vs 9.6) Ihor Radchenko

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='udpvmr$lt8$1@ciao.gmane.io' \
    --to=manikulin@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.