task/1.11
vendor packing tools
This directory contains two helper scripts to manage a compressed vendor.tar.gz archive of the project’s vendor directory. This keeps the project commits clean from vendor changes, while preserving repeatable builds.
Files
pack.go– Createsvendor.tar.gzfrom the currentvendordirectory.unpack.go– Extractsvendor.tar.gzinto thevendordirectory.
Usage
Run from the project root:
go run tools/vendor/pack.go # Archive the vendor directory
go run tools/vendor/unpack.go # Extract the vendor archive
Design Decisions
- Designed to avoid committing all of the
vendorchanges directly within the repo - Enables reproducible builds with vendored,
git-lfsstoredvendor.tar.gz - No external tools: Pure Go. No make, make-alternatives, no shell dependencies.
- Portable & clean:
go buildstill works if you don’t use this tool