dystroy|Canop / blog

Proper conversion from XLS to PDF in Java

3 minute read Published: 2021-06-30

Generating or modifying Excel files in Java is easy with Apache POI.

But when you generate Excel reports, you always end up having to export them in PDF too.

If you look for a library for this conversion, you'll find many ones, most of them expensive, and none of them giving acceptable results.

I explain here the efficient and reliable enough solution I've used in a Java application.

A SQL database and an interactive grapher in a single HTML file

6 minute read Published: 2021-05-04

Glassbench is a Rust micro-benchmark harness. It uses a SQLite database to store bench measurements.

I wanted to give it the option to open an interactive data viewer and grapher, with ability to search the history.

An usual web based solution for that is to run a simple web server.

But Glassbench is executed by cargo and immediately quits and I didn't want it to leave behind anything to clean, especially not daemons. Besides, when you open a single HTML local file, it can't query additional resources, due to browser's security protections.

So I decided to make it a single temporary html page opened in the user's browser.

Why broot switched to Hjson for its configuration files

13 minute read Published: 2020-12-22

TOML was originally the only format for configuring broot.

Here I explain why Hjson is now the preferred one.

Why TUI applications ?

5 minute read Published: 2020-11-22

Twenty years ago, most of us thought TUI applications were going to disappear. TUI were just a vestige of low capabilities computers. There was no reason for TUI not to die with the rise of the personal computer.

This didn't happen. We still love to use TUI applications.

Why can be kind of mysterious.

Broot 1.0

5 minute read Published: 2020-09-02

8 months ago, but it feels like years ago, somebody shared a link to broot on Hacker News. There was some very kind messages and broot gained a few users. But I had more in my TODO list.

A lot was done since.

At first sight, broot didn't change much: It looks the same and what could be done then can still be done the same way, 500 commits and 60 releases later.

For better prompts

5 minute read Published: 2020-07-29

Prompts I see everywhere are very bad in my opinion.

They're sometimes fancy, full of bling which amazes coworkers, but usability nightmares.

Broot content search

4 minute read Published: 2020-07-26

An example of an efficient search workflow based on broot, a general purpose file manager.

Use broot and meld to diff before commit

4 minute read Published: 2020-07-05

Before every commit, I do a short review of what I wrote. And usually there's a few last things to fix, mainly comments.


1 minute read Published: 2020-07-04