Introduction
Freight is a professional, zero-dependency Git hook manager built for modern development teams.
The Problem
Most Git hook managers force a specific runtime on your entire team. If you use Husky, everyone needs Node.js. If you use pre-commit, everyone needs Python. This creates "it works on my machine" friction and bloats your environment.
The Solution: Freight
Freight is different. It ships as a single, static Go binary with zero runtime dependencies.
- Static Portability: Works everywhere without requiring a language runtime.
- Declarative manifest: Manage every hook in your project via one
railcar.jsonfile. - Non-Invasive: Freight doesn't own your repo; it just conducts the traffic.
Architecture: Conductor & Railcar
Freight operates using a high-performance 'Conductor/Railcar' architecture:
- The Conductor: When you run
freight init, a specializedconductorbinary is placed at your repository root. - The Railcar: A
railcar.jsonmanifest is created to define your hook logic. - Execution: When a Git hook (like
pre-commit) is triggered, the Conductor binary immediately executes the logic defined in the Railcar.
This ensures that your hooks are fast, version-controlled, and completely portable across your entire team.