Documentation
¶
Index ¶
- Constants
- func EnsureModMeta(modFile string, pkg string) (err error)
- func GenMakeHelperAndHook(modDir, makeFile, version string, modFiles ...string) error
- func ModDirectPackage(modFile string, r io.Reader) (pkg string, version string, err error)
- func ModHasMeta(modFile string, r io.Reader) (bool, error)
- func NameFromModFile(modFile string) (name string, oneOfMany bool)
- func RemoveMakeHelper(modDir string) error
Constants ¶
const (
MakefileBinVarsName = "Variables.mk"
)
Variables ¶
This section is empty.
Functions ¶
func EnsureModMeta ¶
EnsureModMeta comment on given module file to make sure users knows it's autogenerated. It also ensures that sub package path is recorded, which is required for package-level versioning.
func GenMakeHelperAndHook ¶
GenMakeHelper generates helper Makefile variables to allows reliable binaries use. Regenerate if needed. It is expected to have at least one mod file.
func ModDirectPackage ¶
ModDirectPackage returns buildable package we encoded in the bingo controlled go module. We encode it as single direct module with end of line comment containing relative package path if any. If r is nil, modFile will be read.
func ModHasMeta ¶
ModHasMeta returns true if given mod file contains metadata in comments we are adding in `EnsureModMeta`. If r is nil, modFile will be read.
func NameFromModFile ¶
NameFromModFile returns binary name from module file path.
func RemoveMakeHelper ¶
RemoveMakeHelper deletes Variables.mk from mod directory.
Types ¶
This section is empty.