Home |
About |
Archive
Miscellaneous talk #45 Quarto guy, Overleaf's markdown mode?, Flymake, Mailing lists, CRAN
Posted on Mar 16, 2025
by Chung-hong Chan
- Well, now I am the “Quarto guy” in my work place, thanks to the decision made by the previous Quarto guy, who has left. And therefore, I will need to deliver workshops to my colleagues on how to use Quarto. For the workshop, I thought it would be nice not to teach it like a regular course, which one has to create a document from the beginning. Instead, it would be better to start from a document in Microsoft Word and then try to convert it to Quarto. And in order to do that, one has to use pandoc. I know that Quarto uses pandoc somewhere. But I thought one has to install it as a dependency separately. Only after some more studying with the CLI, I now know that there is the
quarto pandoc
sub-command to expose the included built-in pandoc. And in fact, there is also quarto typst
; meaning typst is also a built-in component. The weirdest is perhaps quarto run
, which exposes deno for running Typescript. After knowing these, they makes the workshop run smoother, as my colleagues can have a suite of useful tools just by installing Quarto.
- Another consequence of becoming the “Quarto guy” is that I have to find a good way to do collaborative writing. This is like the constant theme of this blog, see this and this. The newest experiment is to use Overleaf by exploiting the
markdown
CTAN package. With this method, citations work, image and table placement works. Code execution is still not working. The project can also be clone offline and edit with Emacs.
\documentclass{article}
\usepackage[citations]{markdown}
\title{Whatever title}
\begin{document}
\markdownInput{source.md}
\bibliographystyle{apalike}
\bibliography{references.bib}
\end{document}
- Let’s also talk about Emacs and ESS. Earlier this year I updated Emacs to 30.1. And then strangely, opening R files would have a larger left margin. After some investigation, I found that the local variable
left-margin-width
became 2 for all R buffers. On the official mailing list, I found a person (the original poster) who also had the same problem, but there was no answer. Then, I sent an reply. Finally, the original poster told me the reason for this is that the flymake-model integration might have problem. The solution is to disable ess-flymake integration (setq ess-use-flymake nil)
. I don’t use flymake anymore, so it doesn’t matter. But yeah, it fixed the issue.
- Let’s also talk about mailing lists. In the R community, mailing lists have a bad name. People would prefer, I don’t know, Bluesky now? Or smaller circles, such as, I don’t know, Discord? Slack? Just talking about the technology. I think mailing lists is the most open because one only needs an e-mail address to join. I think now, the people who are still active on R mailing lists are not hostile but instead quite nice. The signal/noise ratio is extremely high. I don’t need to see other social media content, for example.
- The last thing I would like to talk about is CRAN. I read a blog post by Adafruit, a hardware company. The tldr of that is: Adafruit maintains several Arduino (single-board microcontrollers) open source software packages. In 2024, a new company forked their code and added those code to the Arduino Library Registry. The worst part: That new company removed the original open source license, changed the copyright holder to themselves etc.
I did fork some code myself too. minty
is a fork of some code in readr
. Although it is fine to fork open source code, I believe in two things: 1) one still has to respect the original license, and 2) one has to communicate with the original authors to show that forking is done in good faith.
I can’t help but to think about how Arduino Library Registry and CRAN work. Again, CRAN has a bad name. I criticize it sometimes, e.g. this. It is not difficult to find harsher critique of CRAN regularly on blog aggregator rweekly. A few weeks back there was a highlight article entitled Is CRAN Holding R back? Well, every one is entitled to have an opinion and I don’t want to comment whether CRAN is holding R back. But there is a comparison between the semi-automatic and test-free model of package submission (e.g. PyPI) and the manual and constant testing model of CRAN. But the merits of the CRAN model are not discussed.
In my opinion, it is not entirely a technological question, but a political one. Diplomatically speaking, all models have trade offs. While it is true that it is difficult to get a package on CRAN and keeping a package on CRAN one has to do more work, you should at least know what the package is tested on CRAN’s fleet of test servers and should be installable on three major OSes. You should also expect that the e-mail address of the maintainer should still be reachable by CRAN, most likely also by you. Supply chain attack, in principle, should be more difficult. This model is perhaps “outdated” because only some very conservative open source repositories would still use this model, e.g. Debian. PyPI is in fact similarly, but without the constant testing part. Software repositories of newer languages just ask for a Github address. Arduino Library Registry is an extreme version in this school of thinking, where the entire thing is just a text file .
I don’t have a moral of the story for this one. But I believe I sleep slightly better, when CRAN doesn’t operate like Arduino Library Registry.
- Finally, I am moving my private projects to Codeberg. You should too.
Powered by Jekyll and profdr theme