git

package
v1.0.0-rc9 Latest Latest
Warning

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

Go to latest
Published: Mar 30, 2018 License: Apache-2.0 Imports: 3 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

View Source
const Unspecified = "unspecified"

Variables

This section is empty.

Functions

func CmdOutput

func CmdOutput(gitDir string, args ...string) (string, error)

func ProjectVersion

func ProjectVersion(gitDir string) (string, error)

ProjectVersion returns the version string for the git repository that the provided directory is in. The output is the output of "git describe --tags --first-parent" followed by "-dirty" if the repository currently has any uncommitted changes (including untracked files) as determined by "git status --porcelain". If the output starts with the character 'v' followed by a digit (0-9), then the leading 'v' is trimmed. Returns "unspecified" if the repository does not contain any tags.

func Tags

func Tags(gitDir string) (string, error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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