Hey everyone,
I’d like to share a little side project I’ve been working on: Disk View.
It’s a pretty simple Linux desktop app that shows all your drives, partitions, and their disk usage in one compact overview.
I wasn’t really happy with GNOME’s default Disks app when all I wanted was a quick overview of how much space was used across my drives. So I ended up building my own little tool. Nothing particularly fancy, but it does exactly what I was looking for.
The app is written in Crystal using GTK4 and libadwaita.
What might actually be more interesting to the Crystal community than the app itself is the project setup. It could serve as a starting point or reference for anyone interested in building native GTK4 desktop applications with Crystal. Especially the GitHub workflow and setup for AppImage and Flatpak.
It includes:
-
GTK4/libadwaita integration using Crystal bindings
-
A fairly typical GNOME desktop app structure
-
Translations for multiple languages
-
A GitHub Actions workflow that automatically builds AppImage and Flatpak packages and attaches them to GitHub releases
The project was AI-agent-engineered and took only a few days, as i already had ported another experimental project, that i originally wrote with Ruby and GTK4. But after it was running well, it did not do well on other systems … this was one of my main reasons to finally spend more time and interest on Crystal. But the original problem that brought me to Crystal was another NodeJS (CLI) project, that i will port soon to crystal, after i have released a stable release of my Crystal Language Plugin for Jetbrains IDEs.
A big thanks to Hugo Parente Lima (@hugopl) for his work on the GTK4 bindings and GI-Crystal. Without projects like these, building native GTK applications in Crystal would be a lot harder. Really appreciate the effort!
Anyway, I thought I’d share it here in case someone finds either the app or parts of its implementation useful.
GitHub: GitHub - magynhard/disk-view.cr: Simple disk overview with usage for Linux (Gnome/GTK) · GitHub
Feedback is always welcome!
