Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

bitbucket.org/_metalogic_/build

Package Overview
Dependencies
Alerts
File Explorer
Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

bitbucket.org/_metalogic_/build

  • v1.0.2
  • Source
  • Go
  • Socket score

Version published
Created
Source

README

build implements a simple library for capturing build time details, including git branch and commit hash and time

Usage

import "bitbucket.org/metalogic/build"

This import will create a build.Info object containing build information:

// Info represents project build information extracted from Git and Go debug.BuildInfo
type Info struct {
	Project      string     `json:"project"`
	Command      string     `json:"command"`
	Revision     string     `json:"revision"`
	Version      string     `json:"version"`
	LastCommit   time.Time  `json:"lastCommit"`
	DirtyBuild   bool       `json:"dirtyBuild"`
	Dependencies []string   `json:"dependencies"`
	GoVersion    string     `json:"goVersion"`
}

The String() method may be used to print a project summary:

info: = build.Info
...
fmt.Printf("Project %s\n\n", info)
Project github.com/EducationPlannerBC/applications-api (version refs/heads/info, release c1ebd2bb7f1d10d0d4c1b28a9fc01c7e72616fbd) built at Thu, 23 Dec 2021 08:14:00 PST)

FAQs

Package last updated on 21 Mar 2022

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc