Hacker News new | past | comments | ask | show | jobs | submit login
TinyTeX: A lightweight and easy-to-maintain LaTeX distribution (yihui.name)
131 points by jaap_w on Oct 7, 2018 | hide | past | favorite | 52 comments



To be honest, when I am using LaTeX, I just want to write without any interruption. That's why I install texlive-full. Since I am (almost) guaranteed that whatever I encountered, I would be able to do it.

Dealing with complexity of LaTeX and CPAN is not something I really want to do, especially when I am meeting (paper submission) deadline.


I agree, in the sense that this comes years too late for me and I would guess most other Linux users. It's easy enough on Linux just to install effectively all of the packages from your package manager, and the couple GBs it takes aren't enough to be a real concern (and I've got my root on an SSD!).

However, I can see this being a real benefit to Windows and OSX users, who don't have a native package manager. If you're going to be in the unfortunate position of managing LaTeX packages manually, it would be great to have a low-friction way to do that and a minimal portable distribution to start with.

My one actual criticism is the name: it should be TinyLaTeX. TeX and LaTeX are two different things.


TeX on Mac is nearly as painless as TeX on linux: you just install MacTeX via your preferred software installation method (I use homebrew, but in the past I've downloaded the 5GB dmg and used that), install it and everything pretty much "Just Works"


I haven't used it in a long time, but MikTeX on Windows was really easy too back in the 2000s.


This would have been useful for me at one point, when I used LaTeX to make formatted pdf output for a program I was writing. (Making a RPG character builder at a time when I had lots of experience with LaTeX, but none with pdfs directly.) I ended up starting with texlive and making my own very stripped down distribution, with only the libraries that were used in the intermediate .tex file.


For 10+ years I've been a big fan of D. Knuth's TeX with Knuth's original macros Plain. I have about 70 TeX macros of my own. That setup is for all my higher quality word processing from ordinary letters to mathematics, and I regard it as fine. For that word processing, that setup is fine, a done deal.

I looked at LaTeX, got the basic books, etc. and concluded that (A) Knuth's documentation in The TeXBook is relatively short, well written, and essentially totally free of bugs, and it is easy to write more macros and (B) the LaTeX documentation is much longer, less well written, for the internal logic much harder to understand, maybe with bugs if only from the length and complexity and being so big and complicated, and much more difficult for me to write more macros. So, I've just stayed with TeX and never used LaTeX except once when I downloaded a paper in LaTeX and wanted to format and read it.

Lesson: TeX itself, the design, documentation, functionality, and code are really quite good, and for some people LaTeX may be less good. Don't rush to give up on TeX.


As someone who prefers TeX- i'd say the comparison goes this way(very roughly)-

TeX:

* Assembly language or C of typesetting. Gives you fine control * useful when you have various differrnt formats and don't want to learn a new latex template for everything.

LaTex:

* Java of typesetting * Amazing set of libraries and very useful if you work on relatively few well defined formats.


TeX people are unsung heroes to me and about as close to magic as software can get.

It's like an ancient secret order that is keeping the world safe from word-processors.

I have no idea of what they do, or how they do it, but I can't argue with the world-class results.


As with most things, it is largely a matter of practice and experience. There was a time when I was fast enough to take lecture notes in LaTeX, in courses where there were many formulas to be typeset. I did get an odd look from a professor one time, where at the end of a one-hour open-everything exam, I turned in a typeset pdf rather than handwritten answers.

Sadly, I am not as proficient with it as I used to be, as it has way too much esoterica in getting the exact layouts you want.


The biggest problem that most of the publishers still do not accept LaTeX submissions. Especially if you want to publish a book.


Hello from the world of math! Very sorry to hear about your sufferings.


That depends on the field and the specific publisher. Since the turn of the millennium some scholarly presses have stopped accepting LaTeX; this is often related to outsourcing typesetting to Indian shops that are not LaTeX-savvy.


> If you create a tarball of TinyTeX on macOS or Ubuntu, it will be only 50MB

This is excellent and has accelerated my long-term dream: an up-to-date TeX distribution that can live in my home directory in an lz4 (hc) squashfs archive (72M) and be mounted on an as-needed basis.

UPDATE: As I had hoped, TinyTeX works in an lz4 squashfs. On my system it's actually a tiny bit faster under squashfs than from my ext4 home partition.


What is the advantage of having LaTeX in a squashfs if it's taking up space on your home partition anyway? I can't think of any reason to do this unless you want your LaTeX to be read-only for some reason.


Yeah, I don't know why I said in home directory and just mounted when I need it. Might as well be mounted all the time and system-wide. It just all came out in some kind of rambling excited nonsense.

The TeX Live packages are by far the largest on my system. Last time I looked there were loads of very small and moderately compressible files that caused space usage to be exaggerated.

The only time the non-user TeX directories need to be writeable is to update or install new packages, so it doesn't matter if it it's read only most of the time.


Yihui Xie has been an incredible boon for the R & Pandoc ecosystems. Turning your R code into pdf or html is so easy I'm surprised language authors aren't scrambling to copy the feature.


It's because other languages like Python and Julia would usually just use something like Jupyter Notebooks, and those can be converted to PDF using nbconvert.


It is notable that LaTeX development moved to GitHub [1] and anyone can send a pull request without much hassle.

[1] https://github.com/latex3


My favorite part about this article is the extra wide space that follows their apostrophe character. It really gives an air of legitimacy to their LaTeX distribution...


It looks like there is something wrong with the 'Microsoft YaHei' font. Removing that from the font-family fixes the huge space.


In the CJK typography quotes are traditionally as wide as other ideographic characters, with left quotes aligned to the right and right quotes aligned to the left. A Western typographical apostrophe is mapped to a right single quote in Unicode, resulting in a collision. They can only be distinguished by the context.


Looks fine for me (Chrome on Android).


Apostrophe?


Some time ago I was trying to include more than one bibliography in a document. After a day or so trying to make it work with the MacTex installation, I checked if it would work with ShareLatex. Worked at the first try, changing nothing in my files. From then, I never looked back.

I only back up the ShareLatex projects in my Dropbox if for whatever reason I need offline access later. Has worked well so far.


I have some projects where the continuous-integration-testing with Travis requires a tex installation. More than 50% of the entire test run is spent installing texlive-full (since Travis doesn't seem interested in including latex in their standard environment). Maybe TinyTeX will be able to speed this up?


I wrote a python package to install texlive without user interaction in a customizable way. Not installing docs and sources already shaves off half.

It takes ~5 minutes on travis when I only install what I need.

https://github.com/MaxNoe/texlive-batch-installation/blob/ma...


In my experience, TeX needs some packaging/distribution love. Also in my experience, overleaf/sharelatex (web based) blows all of the local installation approaches out of the water. Especially with respect to collaboration with coauthors of your documents.


Sharelatex merged with (was bought by?) Overleaf a while ago. Now we're just down to using Overleaf v2.


you can still use v1 (but they don't make easy)


> YEAR: 2017-2018

> COPYRIGHT HOLDER: Yihui Xie and RStudio, Inc.

what license is this? Is this software proprietary?


It's CC BY-NC-SA 4.0, there's a license link on the top of the page.


Shamelessly promoting something that I wrote myself:

https://github.com/ProdriveTechnologies/bazel-latex

These are rules for building LaTeX documents using the Bazel build system. What's pretty nifty is that these download (parts of) TeXLive automatically, meaning that you don't even need to install TeXLive in your home directory. Instead, it's part of your project, meaning that everyone working on it will use exactly the same version of TeXLive.


On a tangential note, I wish there were a single-executable "distribution" of Plain TeX that would simply "do one thing well" - convert a TeX source to more or less nicely typeset PDF.


Have you tried LuaTeX? If you use plain TeX (without requiring extra LaTeX files), you should only need the binary.

LuaTeX is the successor of pdfTeX. Much improved. And it can use your local .ttf/.otf/... font files out of the box.

The install is very minimalistic and should not require more than downloading a binary and maybe a config file.

http://minimals.contextgarden.net/current/bin/luatex/linux-6...


I've found more than several tools that all basically complete this task. latexmk -pdf Foo.tex, being the most common one that I can remember.

It is somewhat annoying that it will create so many temp files. I guess. I've gotten over it pretty heavily. (I actually regret not looking at the log file more often. I feel I should know how to read most of that.)


LaTeXTools in Sublime et al. will erase the temp files with a shortcut, plus you can add more extensions to clean in case you use packages that add more temp files.


I think there is almost a rite of passage for people getting into latex to create their own build tools. :)


Try `latexmk -c` to remove all the temp files.


I can add the help of latexmk to thingsi should read more. :)


On Mac I prefer BasicTex: https://www.tug.org/mactex/morepackages.html

One can install it very simple via

$ brew cask install basictex

And it doesn't take ages to download and install like other TeX-Distributions.

see also https://bilalakil.me/getting-started-and-productive-with-lat...


I grew irritated with texlive and instead just opted to use https://overleaf.com for my LaTeX documents


Overleaf makes you pay for the history feature, and for more than one collaborator. Not good for long term collaborative papers.


They also let you clone a git repo of your project, so you can painlessly move out of Overleaf when you find yourself outgrowing it.


Maybe. The deprecated V1 lets you. I'm not sure whether V2 will, at least without paying $12/month.


Fair, but they use texlive under the hood.


[flagged]


Why? LaTeX is good at what it does, and there are predefined templates for high quality resumes in various layouts (for example see [1] and [2]). I've written more using LaTeX than Word, so it's easier for me (and others I presume) to produce good results for out of the ordinary documents, like a resume, in LaTeX.

[1] https://www.rpi.edu/dept/arc/training/latex/resumes/

[2] https://www.overleaf.com/gallery/tagged/cv


The problem is many employers and headhunters demand MS Word. As a professional resume writer, I love the output of LaTeX which I use with rmarkdown and want to offer a cheap, easy way for DIYers to do their own. Inevitably, I will be asked to convert to the Word version. Still haven't gotten a good styles.docx file setup to do that.


My resume has been in LaTeX (now XeLaTeX) for many years now for my own convenience (separation of format from content) not pretention. Given that I distribute PDFs, I fail to see how its source format is relevant or even visible - not using Computer Modern fonts.


I didn't downvote - there is a substantial number of pretenders in this space. Because latex is surprisingly easy to use. But I keep my resume in the same family of software myself and it's because of ease of editing. I hide the Computer Modern font and use popular Microsoft Office fonts. So nobody knows.


Why? LaTeX is great for typesetting, and let's you focus on the content rather than the formatting. Perfect for resumes really.


I think various flavors of Markdown have largely superseded TeX, at least for stylistic minimalists. I'm not saying that TeX is obsolete, but for the majority of use cases, Markdown is faster and less troublesome. Modernity always triumphs.


Except if you want a PDF version you're likely converting markdown->TeX->PDF




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: