lilypond-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: where (if anywhere) does lilypond look for locally shared files?


From: David Wright
Subject: Re: where (if anywhere) does lilypond look for locally shared files?
Date: Mon, 12 Apr 2021 23:35:15 -0500
User-agent: Mutt/1.10.1 (2018-07-13)

On Mon 12 Apr 2021 at 23:00:53 (-0500), stefano franchi wrote:
> On Mon, Apr 12, 2021 at 4:39 PM Federico Bruni wrote:
> > On Mon, Apr 12 2021 at 15:45:26 -0500, stefano franchi wrote:
> >
> > Where am I supposed to store my templates, functions, snippets, etc?
> >
> > Otherwise put, in  (La)TeX terms is there a lilypond equivalent of ~/texmf
> > ?
> >
> > There's no standard directory. Just use what you want and then use
> > --include=/PATH/TO/DIR to let lilypond find your files.
> >
> So there is no way to indicate a system-wide or user-dependent location.
> Too bad. I'm sure I'll  forget the --include directive every other time...

You could use an alias, or a shell function, or a script.

> > On linux, there seems to be no equivalents, at least as far as I can tell.
> > It thought
> > ~/.local/share/lilypond would be it, but it is not created at installation
> > time. Is there an environment variable that could be set? The docs make
> > reference to LILYPOND_DATADIR, but that seems to indicate the global
> > location, as far as I can tell from the following description:
> >
> > LILYPOND_DATADIR
> >
> > This specifies a directory where locale messages and data files are looked
> > up by default, overriding locations defined either at compile-time or
> > computed dynamically at run-time (see Relocation
> > <https://lilypond.org/doc/v2.22/Documentation/usage/command_002dline-usage#relocation>).
> > The directory should contain subdirectories called ‘ly’, ‘ps’, ‘tex’,
> > etc.
> > Or is "locale" a typo for "local"?
> >
> > I'm confused
> >
> > Locale refers to localization, i.e. translation files (PO files).
> >
> So "locale messages" = "localized messages", I take it. Thanks for
> clarifying. That's not the most common use  of "locale" in (techy) English,
> that's what confused me I guess.
> Now I know.

Locale, per se, covers more than just messages. Here's mine:

$ locale
LANG=C.UTF-8
LANGUAGE=
LC_CTYPE=en_GB.UTF-8
LC_NUMERIC="C.UTF-8"
LC_TIME="C.UTF-8"
LC_COLLATE="C.UTF-8"
LC_MONETARY="C.UTF-8"
LC_MESSAGES="C.UTF-8"
LC_PAPER="C.UTF-8"
LC_NAME="C.UTF-8"
LC_ADDRESS="C.UTF-8"
LC_TELEPHONE="C.UTF-8"
LC_MEASUREMENT="C.UTF-8"
LC_IDENTIFICATION="C.UTF-8"
LC_ALL=
$ 

> > On my current 2.23.0 installation from lilypond.org package, I see this:
> >
> > $ ls .local/lilypond/usr/share/lilypond/current/
> > fonts  ly  ps  python  scm  vim
> >
> > Locale files are in another directory:
> >
> > $ ls .local/lilypond/usr/share/
> > bash-completion  emacs  fontconfig  gdb  ghostscript  glib-2.0  guile
> >  lilypond  locale  xml
> >
> > $ ls .local/lilypond/usr/share/locale/
> > af   az        bs           de           en@quot  fa  he  is  ko   mk
> >  nds  or     ro  sq        te  ug  zh_CN
> > am   be        ca           dz           en@shaw  fi  hi  it  ku   ml  ne
> >   pa     ru  sr        tg  uk  zh_HK
> > an   be@latin  ca@valencia  el           eo       fr  hr  ja  lt   mn  nl
> >   pl     rw  sr@ije    th  vi  zh_TW
> > ar   bg        cs           en@boldquot  es       ga  hu  ka  lv   mr  nn
> >   ps     si  sr@latin  tl  wa
> > as   bn        cy           en_CA        et       gl  hy  kk  mai  ms  no
> >   pt     sk  sv        tr  xh
> > ast  bn_IN     da           en_GB        eu       gu  id  kn  mg   nb  oc
> >   pt_BR  sl  ta        tt  yi
> >
> >
> Interesting. Neither directory exists on my system (Archlinux official
> package installation). Instead I have a bunch of
> /usr/share/locale/ca/LC_MESSAGES/lilypond.mo
> for various locales.

Same here for my Debian system. But that's because we are looking at
the locale files for the system, including an "official" installation
of lilypond. My /usr/share/locale/ca/LC_MESSAGES/ directory contains
123 files for a variety of programs.

If you install lilypond with a downloaded file from the LilyPond website,
you'd typically install it somewhere under your home directory. So I also
have ~/lilypond-2.22.0-1.linux-64/ containing version 2.22, and its locale
files are in ~/lilypond-2.22.0-1.linux-64/lilypond/usr/share/locale/.

$ ls ~/lilypond-2.22.0-1.linux-64/lilypond/usr/share/locale/ca/LC_MESSAGES/
flex.mo  gettext-runtime.mo  gettext-tools.mo  glib20.mo  lilypond.mo
$ 

The reason I don't use a bare ~/.local directory myself is
because of having multiple versions:

$ ls -d1 lilypond*/
lilypond-2.18.2-1.linux-64/
lilypond-2.19.83-1.linux-64/
lilypond-2.21.0-1.linux-64/
lilypond-2.21.80-1.linux-64/
lilypond-2.22.0-1.linux-64/
$ 

Cheers,
David.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]