Appendix F — Useful tools
I wanted to take this thesis as an opportunity to share some tools that I found particularly useful during my PhD.
F.1 Typesetting this thesis
I decided early on to use Quarto to typeset this thesis. Looking back, I think this was a great choice for multiple reasons:
- I find its (enriched) Markdown syntax to be much nicer to use than LaTeX, and it helped me focus on the content itself.
- Having a live web version that gets instantly updated as you type is incredibly convenient compared to the long compilation time of LaTeX.
- It still provides fine-grained control of figures and references, and supports many themes and extensions.
- Because it is built on top of Pandoc, it can export a wide variety of formats, which is what let me have a web version and a PDF produced with the same sources.
You can find all the sources of this thesis alongside the extensions I tweaked at https://github.com/imartayan/phd.
F.2 Bibliography management and formatting
The main solution I use to manage my collection of articles is Zotero. I find it easy to use, and its built-in PDF annotation tool is very convenient. If you feel limited by its storage sync limit of 300 MB, note that you can actually use any WebDAV server to sync your files instead. For instance, if your institution has a Nextcloud server, you can use it to sync larger collections. They also recently made an iOS/Android app to access your collection, which can be useful if you prefer using a tablet.
While writing this thesis, I very often needed to add BibTeX entries for new articles. At first I was using Google Scholar to do that, but I quickly noticed that its entries were often incomplete and that it systematically stripped DOIs, which is the most important information in my opinion. Thus I decided to write my own tool called bibelot (bib a lot) to do that. It’s a CLI tool that takes DOIs or preprint links as input, fetches up-to-date metadata, and copies the resulting BibTeX entries to a file or to your clipboard.
F.3 CLI tools I use everyday
I spend most of my time working from a terminal, and there are a few tools that I couldn’t live without:
- First for the terminal itself, Ghostty is a very nice piece of software, fast and very polished.
- When working on a remote server, bottom is a great replacement for
topto monitor processes and resource usage. - If you need to monitor disk usage, dust is a great replacement for
du. - When searching for a pattern inside text files, ripgrep is usually much faster than
grep. - Ripgrep can actually be extended with ripgrep-all to search many other formats such as PDF. This allows me to search for a keyword in my entire collection of articles in a couple of seconds.
F.4 Rust toolchain
These days, I write most of my code in Rust and in addition to the built-in toolchain, there are a few more tools that I find very convenient:
- While the warning messages of the compiler are already very useful, clippy provides even more suggestions and can even automatically apply fixes. You can also set up your favorite editor to integrate clippy warnings to your code.
- I don’t always notice when my dependencies are outdated, and cargo-outdated can check for that automatically.
- Similarly, cargo-machete lets you remove unused dependencies.
- Flame graphs are a great way to visualize the trace of your program to identify which functions dominate the running time, you can easily generate them with cargo-flamegraph.
- Sometimes flame graphs are not enough and you want to look at the assembly generated for a specific function, this can be done with cargo-show-asm. This is especially useful to understand what the compiler is doing behind your back.
- Finally, if you end up publishing crates, cargo-release provides many sanity checks before actually doing the release.
You can install all these tools using the following commands:
rustup update
rustup component add clippy
cargo install cargo-outdated cargo-machete flamegraph cargo-show-asm cargo-release