ChannelZ v0.5.1
License: WTFPL
Released: 2021-03-25

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

This application is written in Rust and can be installed using Cargo.

For stable Rust (>= 1.51.0), run:

RUSTFLAGS="-C link-arg=-s" cargo install \
    --git https://github.com/Blobfolio/channelz.git \
    --bin channelz \
    --target x86_64-unknown-linux-gnu

Pre-built .deb packages are also added for each release. They should always work for the latest stable Debian and Ubuntu.

Usage

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

The following flags and options are available:

    --clean          Remove all existing *.gz *.br files before starting.
-h, --help           Prints help information
-l, --list <list>    Read file paths from this list.
-p, --progress       Show progress bar while minifying.
-V, --version        Prints version information

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. :)