util

package
v0.1.0-alpha Latest Latest
Warning

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

Go to latest
Published: Jan 26, 2016 License: AGPL-3.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Printer printer

Printer is deprecated. Prefer tenets/go/dev/tenet/log.Logger.

Functions

func BinTenets

func BinTenets() ([]string, error)

BinTenets returns a list of all installed binary tenets as pathnames.

func DockerClient

func DockerClient() (*goDocker.Client, error)

DockerClient returns a new goDocker client initialised with an endpoint specified by the current config.

func FormatOutput

func FormatOutput(in interface{}, tmplt string) (string, error)

FormatOutput converts arbitrary data into a string using Go's standard template format.

func LingoBin

func LingoBin() (string, error)

LingoBin returns the path to where binary tenets are stored.

func LingoHome

func LingoHome() (string, error)

LingoHome returns the path to the user's lingo config directory.

func MustLingoHome

func MustLingoHome() string

MustLingoHome returns the path to the user's lingo config directory or panics on failure.

func NewBuffer

func NewBuffer(limit int, killc chan struct{}) *buffer

TODO(waigani) limit must be > 0

func OpenFileCmd

func OpenFileCmd(editor, filename string, line int64) (*exec.Cmd, error)

OpenFileCmd launches the specified editor at the given filename and line number.

func Printf

func Printf(format string, args ...interface{}) (int, error)

Printf provides indirection around the standard fmt.Printf function so that the output stream can be globally configured. WARNING: util.Printf is deprecated. Prefer tenets/go/dev/tenet/log.Printf.

func Println

func Println(line string)

Println provides indirection around the standard fmt.Println function so that the output stream can be globally configured. WARNING: util.Println is deprecated. Prefer tenets/go/dev/tenet/log.Println.

func UserHome

func UserHome() (string, error)

UserHome returns the user's OS home directory.

Types

This section is empty.

Jump to

Keyboard shortcuts

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