A user-friendly, lightweight TUI for disk imaging

Overview

Caligula Burning Tool

CI

Screenshot of the Caligula TUI verifying a disk.

Caligula is a user-friendly, lightweight TUI for imaging disks.

$ caligula burn -h
Burn an image to a disk

Usage: caligula burn [OPTIONS] <INPUT>

Arguments:
  <INPUT>  Input file to burn

Options:
  -o <OUT>
          Where to write the output. If not supplied, we will search for
          possible disks and ask you for where you want to burn
  -z, --compression <COMPRESSION>
          What compression format the input file is. If `auto`, then we will
          guess based on the extension [default: auto] [possible values:
          auto, none, bz2, gz, xz]
  -s, --hash <HASH>
          The hash of the input file. For more information, see long help
          (--help) [default: ask]
      --hash-of <HASH_OF>
          Is the hash calculated from the raw file, or the compressed file? [possible
          values: raw, compressed]
      --show-all-disks
          If provided, we will show all disks, removable or not
  -f, --force
          If supplied, we will not ask for confirmation before destroying
          your disk
  -h, --help
          Print help (see more with '--help')
  -V, --version
          Print version

How to install

Platform support

  • Automated builds and tests run for amd64 Linux and MacOS.
  • Automated builds (but NOT automated tests) run for arm64 Linux
  • No automated builds or tests for arm64 MacOS, but we usually distribute a pre-compiled binary in releases.

We plan on supporting Windows and FreeBSD eventually. If you would like support for other OSes and architectures, please file an issue!

Features

  • Small, statically-linked binary on the Linux version
  • Cool graphs
  • Listing attached disks, and telling you their size and hardware model information
  • Rich confirmation dialogs so you don't accidentally nuke your filesystem
  • Automatically decompressing your input file for a variety of formats, including gz, bz2, and xz
  • Validating your input file against a hash before burning, with support for md5, sha1, sha256, and more!
  • Running sudo for you if you forgot to run sudo earlier (it happens)
  • Verifying your disk to make sure it was written correctly
  • Did I mention cool graphs?

FAQ

Why did you make this?

Because I wanted a nice, user-friendly wrapper around dd that wasn't like, a 90 MB executable that packages Chromium and eats hundreds of MB of RAM like certain other disk etching softwares do.

Why is it called "Caligula"?

Because there used to be a tool called Nero Burning ROM, so I chose another crazy Roman emperor to name this software after. It's a very uncreative name and I might rename it later.

Why is dd not good enough for you?

I know how dd works. In fact, instead of using caligula, I could just do this:

$ sha256sum some-image-file.iso.gz

I pause here to confirm that the file has the right SHA.

$ gunzip some-image-file.iso.gz
$ lsblk

I pause here to make sure my disk is indeed detected by the OS.

$ dd bs=4M if=some-image-file.iso of=/dev/

I pause here to confirm that I am indeed typing in the correct disk.

$ dd bs=4M if=some-image-file.iso of=/dev/sdb
dd: failed to open '/dev/sdb': Permission denied
$ sudo dd bs=4M if=some-image-file.iso of=/dev/sdb

There is no output, but I'd like to see the progress.

^C^C^C
$ sudo dd bs=4M if=some-image-file.iso of=/dev/sdb status=progress

Or, instead of that whole song and dance, I could just type

$ caligula burn some-image-file.iso.gz

and have it fill in the blanks. It's not that I don't know how to use dd, it's just that after flashing so many SD cards and USBs, I'd rather do something less error-prone.

Why Rust?

Because it's ๐Ÿš€ ๐Ÿš€ ๐Ÿš€ BLAZING FAST ๐Ÿš€ ๐Ÿš€ ๐Ÿš€ and ๐Ÿ’พ ๐Ÿ’พ ๐Ÿ’พ MEMORY SAFE ๐Ÿ’พ ๐Ÿ’พ ๐Ÿ’พ

Why Nix?

It makes the CI more predictable.

Why so many other dependencies?

To be fair, Rust doesn't have a very comprehensive standard library, and I only use one or two functions in most of those dependencies. Thanks to dead code elimination, inlining, and other optimizations, they don't end up contributing much to the overall binary size.

Will the binary ever get bigger?

I want to keep the binary very small. I want to keep the x86_64-linux version under 4MB, with 8MB as an absolute maximum. As of v0.3.0, it's only 2.66MB, which is pretty good!

Comments
  • Suport xz and bz2 on cross-compiled aarch64-linux

    Suport xz and bz2 on cross-compiled aarch64-linux

    I turned it off because the libraries I'm using bind to a C library, and when I cross-compile to it, it uses the host compiler instead of the cross compiler, making the builds fail.

    os: linux cross compilation arch: aarch64 
    opened by ifd3f 0
  • Add support for compressed input files

    Add support for compressed input files

    Closes #4 . This adds support for gz, xz, and bz2 compression formats. Since cross-compiling C using naersk is pain, I'm disabling xz and bz2 on aarch64-linux for the time being.

    feature 
    opened by ifd3f 0
  • Improve CLI flags

    Improve CLI flags

    We should probably have a bunch of flags like so:

    • -f/--force means "yes to everything except sudo escalation"
    • --use-sudo means "yes to specifically sudo escalation, but not necessarily everything else"
    • -i/--interactive is the current behavior, and --non-interactive means "do not ask, and fail if we don't know what to do." If not specified, this condition should be detected via isatty().

    If any arguments are underspecified for any of these conditions (i.e. --hash=ask or no --out) then we should immediately fail.

    This task may require a good amount of refactoring to accomplish.

    feature ux 
    opened by ifd3f 0
  • Write windows media correctly

    Write windows media correctly

    Usually, if you just straight-up dd a Windows ISO to a disk, it will likely not boot. You need to do some other stuff, described here.

    We'll want to auto-detect if we're writing windows and write it.

    feature 
    opened by ifd3f 0
  • More intelligent block sizing

    More intelligent block sizing

    Currently, we always do a block size of 128KiB. But maybe there's a faster block size, and the code should figure that out.

    • For Linux, maybe look under /sys/class/block/nvme0n1/queue/*_block_size?
    • For MacOS, the native bindings already export block size, but perhaps there's a better parameter to use.
    • Maybe we could vary the block size as we write.
    feature 
    opened by ifd3f 0
Releases(v0.3.0)
  • v0.3.0(Mar 15, 2023)

    my gf made me look at a really cute hedgehog video right before this release

    What's Changed

    • Implement hash verification by @ifd3f in https://github.com/ifd3f/caligula/pull/32
    • Improve the CLI help message by @ifd3f in https://github.com/ifd3f/caligula/pull/33
    • Differentiate --compression ask and --compression auto flags by @ifd3f in https://github.com/ifd3f/caligula/pull/34

    Full Changelog: https://github.com/ifd3f/caligula/compare/v0.2.0...v0.3.0

    Source code(tar.gz)
    Source code(zip)
    caligula-aarch64-linux(4.84 MB)
    caligula-x86_64-darwin(2.29 MB)
    caligula-x86_64-linux(2.65 MB)
  • v0.2.0(Mar 10, 2023)

    It's a full release that's actually been somewhat tested! Please file an issue if there's any bugs or if it doesn't work on your machine.

    What's Changed

    • Add support for MacOS by @ifd3f in https://github.com/ifd3f/caligula/pull/7
    • General improvements to logging and TUI state management by @ifd3f in https://github.com/ifd3f/caligula/pull/8
    • Add aarch64-linux cross compilation to CI by @ifd3f in https://github.com/ifd3f/caligula/pull/18
    • Improve performance when target is a file by @ifd3f in https://github.com/ifd3f/caligula/pull/19
    • Add support for compressed input files by @ifd3f in https://github.com/ifd3f/caligula/pull/22
    • Update README by @ifd3f in https://github.com/ifd3f/caligula/pull/25

    Full Changelog: https://github.com/ifd3f/caligula/compare/v0.1.0...v0.2.0

    Source code(tar.gz)
    Source code(zip)
    caligula-aarch64-darwin(2.01 MB)
    caligula-aarch64-linux(4.60 MB)
    caligula-x86_64-darwin(2.06 MB)
    caligula-x86_64-linux(2.41 MB)
  • v0.2.0-pre1(Mar 6, 2023)

    This version is an unstable prerelease version! Please let me know if there's any bugs or if it doesn't work on your machine.

    I yanked the v0.1.0 because it was straight-up broken due to O_DIRECT.

    What's Changed

    • Add support for MacOS by @ifd3f in https://github.com/ifd3f/caligula/pull/7
    • General improvements to logging and TUI state management by @ifd3f in https://github.com/ifd3f/caligula/pull/8
    Source code(tar.gz)
    Source code(zip)
    caligula-aarch64-darwin(2.29 MB)
    caligula-x86_64-darwin(1.88 MB)
    caligula-x86_64-linux(2.23 MB)
Owner
Astrid Yu
allegedly a computer person
Astrid Yu
A user-friendly TUI client for Matrix written in Rust!

Konoha A user-friendly TUI client for Matrix written in Rust! Notice: The client is currently not usable and is only hosted on GitHub for version cont

L3af 9 Jan 5, 2022
A user-friendly TUI for secure file transfers, with arrow-key and VIM-style navigation

gsftp SFTP with an interactive text-based user interface (TUI). Transfer files through an encrypted connection with a visual interface, so you can see

Ben Jiron 3 Jul 7, 2022
Rust Imaging Library's Python binding: A performant and high-level image processing library for Python written in Rust

ril-py Rust Imaging Library for Python: Python bindings for ril, a performant and high-level image processing library written in Rust. What's this? Th

Cryptex 13 Dec 6, 2022
A template for bootstrapping a Rust TUI application with tui-rs & crossterm

rust-tui-template A template for bootstrapping a Rust TUI application with tui-rs & crossterm. tui-rs The library is based on the principle of immedia

Orhun Parmaksฤฑz 72 Dec 31, 2022
fd is a program to find entries in your filesystem. It is a simple, fast and user-friendly alternative to find

fd is a program to find entries in your filesystem. It is a simple, fast and user-friendly alternative to find. While it does not aim to support all of find's powerful functionality, it provides sensible (opinionated) defaults for a majority of use cases.

David Peter 25.9k Jan 9, 2023
A user-friendly re-implementation of existing hex tools in Rust

Hex A project to create alternate (and more user friendly) versions of existing hex tools. The project can be installed as a extension to the github-c

Sohom Datta 6 Sep 27, 2022
OSINT from your favorite services in a friendly terminal user interface

osintui Open Source Intelligence Terminal User Interface Report Bug ยท Request Feature Installation First, install Rust (using the recommended rustup i

Will Sheldon 639 Jan 4, 2023
Estratto is a powerful and user-friendly Rust library designed for extracting rich audio features from digital audio signals.

estratto ใ€œ An Audio Feature Extraction Library estratto is a powerful and user-friendly Rust library designed for extracting rich audio features from

Amber J Blue 5 Aug 25, 2023
Demo Rust Cursive crate for terminal user interface (TUI)

Demo Rust Cursive Demonstration of the Rust programming language and Cursvie crate for terminal user interface (TUI). Setup Create: cargo new demo Add

Joel Parker Henderson 5 Dec 27, 2022
Synthia is a lightweight and beginner-friendly interpreted programming language developed in Rust

Synthia is a lightweight and beginner-friendly interpreted programming language developed in Rust. With a simple, intuitive syntax and a focus on ease of use, Synthia is perfect for both newcomers to programming and experienced developers looking for a flexible scripting language

Shiva 3 Oct 5, 2023
Lemurs - A lightweight TUI display/login manager written in Rust ๐Ÿ’

Lemurs ?? A TUI Display/Login Manager written in Rust WIP: Whilst the project is working and installable, there are still a lot of bugs and limitation

Gijs Burghoorn 136 Jan 1, 2023
ChatGPT-rs is a lightweight ChatGPT client with a graphical user interface, written in Rust

ChatGPT-rs is a lightweight ChatGPT client with a graphical user interface, written in Rust. It allows you to chat with OpenAI's GPT models through a simple and intuitive interface.

null 7 Apr 2, 2023
Zenith - sort of like top or htop but with zoom-able charts, CPU, GPU, network, and disk usage

Zenith - sort of like top or htop but with zoom-able charts, CPU, GPU, network, and disk usage

Benjamin Vaisvil 1.6k Jan 4, 2023
Terminal disk space navigator ๐Ÿ”ญ

Given a path on your hard-drive (which could also be the root path, eg. /). diskonaut scans it and indexes its metadata to memory so that you could explore its contents (even while still scanning!).

Aram Drevekenin 1.6k Dec 30, 2022
A library for loading and executing PE (Portable Executable) from memory without ever touching the disk

memexec A library for loading and executing PE (Portable Executable) from memory without ever touching the disk This is my own version for specific pr

FssAy 5 Aug 27, 2022
garbage-collecting on-disk object store, supporting higher level KV stores and databases.

marble Garbage-collecting disk-based object-store. See examples/kv.rs for a minimal key-value store built on top of this. Supports 4 methods: read: de

Komora 215 Dec 30, 2022
Executables on Disk? Bleh ๐Ÿคฎ

Executables on Disk? Preposterous! Saving executables to disk is like telling EDRs that "Hey! Take a look at this thing I just fetched from the Intern

whokilleddb 87 Dec 18, 2022
๐Ÿ’พSaving Your Hard Disk, One Project at a Time

nodemore ?? Nodemore Recursively Searches Directories for Unused Projects Contents Why? Installation Usage Configuration Why? NodeJS has a horrible wa

Will 13 Apr 16, 2023
A simple disk benchmark tool.

simple-disk-benchmark A simple disk benchmark tool. Operating Systems Currently, macOS and Linux are tested. Windows may work but is not tested. Devel

Jonathan Wight 7 Jul 31, 2023