ChannelZ v0.9.4
License: WTFPL
Released: 2024-11-28

ChannelZ

ChannelZ is a CLI tool for x86-64 Linux machines that simplifies the common task of encoding static web assets with Gzip and Brotli for production environments.

Features

The "appropriate" file types are:

Installation

Debian and Ubuntu users can just grab the pre-built .deb package from the latest release.

This application is written in Rust and can alternatively be built from source using Cargo:

# Clone the source.
git clone https://github.com/Blobfolio/channelz.git

# Go to it.
cd channelz

# Build as usual. Specify additional flags as desired.
cargo build \
    --bin channelz \
    --release

(This should work under other 64-bit Unix environments too, like MacOS.)

Usage

It's easy. Just run channelz [FLAGS] [OPTIONS] <PATH(S)>….

The following flags and options are available:

Short Long Value Description
--clean Remove all existing *.gz *.br files before starting.
-h --help Print help information and exit.
-l --list <FILE> Read (absolute) file and/or directory paths from this text file, one entry per line.
-p --progress Show progress bar while minifying.
-V --version Print program version and exit.

For example:

# Generate app.js.gz and app.js.br:
channelz /path/to/app.js

# Tackle a whole folder at once with a nice progress bar:
channelz -p /path/to/assets

# Do the same thing, but clear out any old *.gz or *.br files first:
channelz --clean -p /path/to/assets

# Or load it up with a lot of places separately:
channelz /path/to/css /path/to/js …

Benchmarks

ChannelZ's compression is a little bit stronger than brotli -q 11 and gzip -9, but not by much.

Timing-wise, though, it's no competition. :)