Build from Source
Clone the repository and build Shrinkr locally.
Build from Source
Requirements
- macOS (Apple Silicon or Intel — Intel builds run via Rosetta 2)
- Go 1.21+
libvips(installed via Homebrew)
Steps
# Clone
git clone https://github.com/idrewlong/shrinkr_cli
cd shrinkr_cli
# Install libvips dependency
brew install vips
# Build binary in current directory
make build
# Or install globally to $GOPATH/bin
make install
The Makefile targets:
| Target | Command | Description |
|---|---|---|
build | make build | Builds ./shrinkr binary in the project directory |
install | make install | Runs go install . — installs to $GOPATH/bin |
clean | make clean | Removes the ./shrinkr binary and dist/ folder |
run | make run | Runs go run . ../images for local testing |
