forgepb

package module
v0.0.7 Latest Latest
Warning

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

Go to latest
Published: Nov 30, 2024 License: GPL-3.0 Imports: 15 Imported by: 0

README

protobuf definition files for forge

Documentation

Overview

Example

This example is copied from rill to understand golang docs

package main

import (
	"fmt"
)

func main() {
	fmt.Println("nothing here yet")
}
Output:

Example (Batching)

This example is copied from rill to understand golang docs

package main

import (
	"fmt"
)

func main() {
	fmt.Println("nothing batching here yet")
}
Output:

Index

Examples

Constants

This section is empty.

Variables

View Source
var FORGEPB *log.LogFlag
View Source
var FORGEPBWARN *log.LogFlag

Functions

func FindGoSrc added in v0.0.5

func FindGoSrc() (string, error)

look for a go.work file otherwise use ~/go/src

func IsGitDir added in v0.0.7

func IsGitDir(dir string) bool

IsGitDir checks if a .git directory exists inside the given directory

Types

type Forge added in v0.0.7

type Forge struct {
	Config  *ForgeConfigs // config repos for readonly, private, etc
	Repos   *gitpb.Repos
	Machine *zoopb.Machine
	// contains filtered or unexported fields
}

maybe an interface someday?

func Init added in v0.0.7

func Init() *Forge

func (*Forge) ConfigPrintTable added in v0.0.7

func (f *Forge) ConfigPrintTable()

print a human readable table to STDOUT

func (*Forge) ConfigSave added in v0.0.7

func (f *Forge) ConfigSave() error

write to ~/.config/forge/ unless ENV{FORGE_HOME} is set

func (*Forge) DebName added in v0.0.7

func (f *Forge) DebName(gopath string) string

returns the deb package name this let's you check a git tag version against a package .deb version allows gopath's to not need to match the .deb name this is important in lots of cases! It is normal and happens often enough.

func (*Forge) GetGoSrc added in v0.0.7

func (f *Forge) GetGoSrc() string

func (*Forge) IsFavorite added in v0.0.7

func (f *Forge) IsFavorite(thing string) bool

IsFavorite() -- fun option for the config file that lets you set things as favorites so you can just go-clone a bunch of common things on a new box or after you reset/delete your ~/go/src dir

func (*Forge) IsPrivate added in v0.0.7

func (f *Forge) IsPrivate(thing string) bool

is this a non-publishable repo? matches package names from apt

IsPrivate("foo") will match anything in the config file ending in "foo"

IsPrivate("go.foo.com/jcarr/foo") returns true if private IsPrivate("foo") also returns true if "go.bar.com/jcarr/foo" is private

func (*Forge) IsReadOnly added in v0.0.7

func (f *Forge) IsReadOnly(gopath string) bool

returns true if gopath is readonly() will attempt to match IsWritable("foo") against anything ending in "foo"

func (*Forge) ScanGoSrc added in v0.0.7

func (f *Forge) ScanGoSrc() (bool, error)

func (*Forge) SortByPath added in v0.0.7

func (f *Forge) SortByPath() *ForgeConfigIterator

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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