mkmerge command
The mkmerge command parses generated source files and merges common consts, funcs, and types into a common source file, per GOOS.
Usage:
$ mkmerge -out MERGED FILE [FILE ...]
Example:
# Remove all common consts, funcs, and types from zerrors_linux_*.go # and write the common code into zerrors_linux.go $ mkmerge -out zerrors_linux.go zerrors_linux_*.go
mkmerge performs the merge in the following steps:
- Construct the set of common code that is identical in all architecture-specific files.
- Write this common code to the merged file.
- Remove the common code from all architecture-specific files.
- Version
- v0.30.0 (latest)
- Published
- Jan 31, 2025
- Platform
- linux/amd64
- Imports
- 16 packages
- Last checked
- 4 days ago –
Tools for package owners.