Skip to content

Blobfolio/guff

Repository files navigation

Guff

ci deps.rs
license contributions welcome

Guff is an x86-64 Linux CLI tool providing both SASS/SCSS compilation and CSS parsing/minification. It is a faster, lighter, compressier alternative to chaining together multiple tools like sassc and csso.

Under the hood, it merely marries the SCSS functionality of grass with the compressive capabilities of Lightning CSS. If Guff is too opinionated for you or incompatible with your platform, take a look at those projects; they both have frontends of their own. ;)

Usage

It's easy; just give it a source and, optionally, a destination:

guff [FLAGS] [OPTIONS]

Flags:

-h, --help        Print help information and exit.
-V, --version     Print version information and exit.

Options:

-b, --browsers <STR>  A comma-separated list of specific browser/version pairs
                      to target for CSS compatibility, like 'firefox 90, ie
                      11'. Specifying versions released after guff was built
                      has no effect.
-i, --input <FILE>    The path to an SCSS or CSS source file.
-o, --output <FILE>   The path to save the minified output to. If omitted,
                      the result will be printed to STDOUT instead.

If the input is SCSS, it will be compiled into CSS and then minified; if it is already CSS, it will just be minified.

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/guff.git

# Go to it.
cd guff

# Build as usual. Specify additional flags as desired.
cargo build \
    --bin guff \
    --all-features \
    --release

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

License

See also: CREDITS.md

Copyright © 2024 Blobfolio, LLC <hello@blobfolio.com>

This work is free. You can redistribute it and/or modify it under the terms of the Do What The Fuck You Want To Public License, Version 2.

DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004

Copyright (C) 2004 Sam Hocevar <sam@hocevar.net>

Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.

DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION

0. You just DO WHAT THE FUCK YOU WANT TO.