mkmerge

command
v0.21.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 17, 2024 License: BSD-3-Clause Imports: 16 Imported by: 0

Documentation

Overview

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:

  1. Construct the set of common code that is identical in all architecture-specific files.
  2. Write this common code to the merged file.
  3. Remove the common code from all architecture-specific files.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL