tectonic icon indicating copy to clipboard operation
tectonic copied to clipboard

Installing packages from a file

Open vlad-ivanov-name opened this issue 7 years ago • 3 comments

I must say I'm really impressed by this project — mostly by how it's user-friendly and hassle-free.

There is a package for LaTeX that is quite popular among users in Russia and eastern Europe — pscyr [pdf link]. It contains a number of fonts used by publishers in USSR, for instance, Literaturnaya. Some of these fonts were digitized and edited during 90s and their source and license status is unclear. Because of that, pscyr package is not included in any distribution.

For Texlive, installation includes copying files from archive to texmf directory and running mktexlsr && updmap-sys. Could it be possible to integrate an "external" package into tectonic?

vlad-ivanov-name avatar Jun 19 '17 21:06 vlad-ivanov-name

Ah, an interesting problem! Thanks for raising this issue.

For the near future I'm afraid that Tectonic is not going to have a very good solution for this. If you really need to make something work, the current recommendation is just to unpack all of the source files in the same directory as your input file. Obviously this is not optimal.

For the same reason that the TeX distributions won't include pscyr, I don't feel comfortable including it in the default "bundle" of TeXLive files. But an ambitious person could make their own "bundle" file that was based on the default one and included pscyr, and then configure their Tectonic install to use it. This bundle could be served over HTTP or just stored locally on the filesystem. (Well, the configuration setup doesn't actually support the latter yet, but that's a much more tractable problem to solve.) Unfortunately, this both requires a fairly substantial amount of work, and involves a process that is essentially undocumented at this time. (Some of the relevant code is here in the tectonic-staging repo).

I am trying to write up some real documentation for the novel parts of Tectonic — if you think you might want to take a stab at making your own "bundle", please let me know, so that I can prioritize the task of writing the relevant docs.

Looking at the bigger picture, it seems that there's a real need to have some way to include extra TeX packages at finer granularity than that of whole bundles. Ideally we would do this in a way that kept things reproducible ... which I think would end up basically involving replicating CTAN with more stringent versioning guidelines :-(

I'm going to copy this thread on the Tectonic forums that I've set up since I think it's an interesting discussion topic.

pkgw avatar Jun 20 '17 02:06 pkgw

I have to admit I'm not very familiar with LaTeX font package structure. Installing "bundles" from file would be fine. I think this is a quite special problem which is definitely not a priority for now — I just wanted to put it on the map.

Thank you for your answer.

vlad-ivanov-name avatar Jun 20 '17 07:06 vlad-ivanov-name

Tectonic can use external .sty file provided with full path (but without extension):

\documentclass{article}
\usepackage{/Users/user/Library/texmf/tex/latex/external_sty_file}

\begin{document}
1 + 1 = 2
\end{document}

I hope this will help someone

vsheg avatar Apr 16 '23 07:04 vsheg