git

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Apr 4, 2018 License: MIT Imports: 7 Imported by: 0

Documentation

Overview

Package git stores changes a in a git repository

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Store

type Store struct {
	Logger   *logrus.Logger
	URL      string
	LocalDir string
	Author   string
	Email    string
	Msg      string
	// contains filtered or unexported fields
}

Store will maintain a git repository off dumped kube objects

func New

func New(config *config.KdnConfig) *Store

New instantiate a new Store

func (*Store) Clone

func (s *Store) Clone() error

Clone does git clone, or git init (when there's no GiURL to clone from)

func (*Store) Commit

func (s *Store) Commit() (changed bool, err error)

Commit git commit all the directory's changes

func (*Store) Git

func (s *Store) Git(args ...string) error

Git wraps the git command

func (*Store) Push

func (s *Store) Push() error

Push git push to the origin

func (*Store) Start added in v0.2.0

func (s *Store) Start() (*Store, error)

Start maintains a directory content committed

func (*Store) Status

func (s *Store) Status() (changed bool, err error)

Status tests the git status of a repository

func (*Store) Stop added in v0.2.0

func (s *Store) Stop()

Stop stops the git goroutine

Jump to

Keyboard shortcuts

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