Categorygithub.com/nousefreak/go-vembed
repositorypackage
0.0.0-20190924200302-0a945ec137cf
Repository: https://github.com/nousefreak/go-vembed.git
Documentation: pkg.go.dev

# Packages

No description provided by the author

# README

Vembed

Vembed simplifies embedding a version into a binary.

Example

This example show how to use vembed.

package main

import (
	"fmt"

	"github.com/NoUseFreak/go-vembed"
)

func main() {
	fmt.Printf(
		"%s, build %s",
		vembed.Version.GetGitSummary(),
		vembed.Version.GetGitCommit(),
	)
}

Build

go get github.com/NoUseFreak/go-vembed/vembed
go build -ldflags="`vembed`" main.go