dolt_builder

package
v0.40.4 Latest Latest
Warning

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

Go to latest
Published: May 19, 2022 License: Apache-2.0 Imports: 11 Imported by: 1

README

Dolt builder is a tool for more easily installing dolt binaries.

It takes Dolt commit shas or tags as arguments and builds corresponding binaries to a path specified by $DOLT_BIN

If $DOLT_BIN is not set ./doltBin will be used

(Optional) set $DEBUG=true to run in debug mode

Example usage:

$ dolt-builder dccba46 4bad226
$ dolt version 0.1
$ dolt version 0.2
$ dolt-builder v0.19.0 v0.22.6
$ dolt version 0.19.0
$ dolt version v0.22.6

Documentation

Index

Constants

View Source
const (
	GithubDolt = "https://github.com/dolthub/dolt.git"
)

Variables

View Source
var Debug bool

Functions

func CommitArg

func CommitArg(c string) string

func ExecCommand

func ExecCommand(ctx context.Context, name string, arg ...string) *exec.Cmd

func GitCheckoutTree

func GitCheckoutTree(ctx context.Context, repoDir string, toDir string, commit string) error

GitCheckoutTree checks out `commit` from the Git repo at `repoDir` into `toDir`. It does it without copying the entire git repository. First we run `git read-tree` with a GIT_INDEX_FILE set to `$toDir/.buildindex`, which gets an index for the commit fully populated into the file. Then we run `git checkout-index -a` referencing the same INDEX_FILE, which populates the current working directory (`toDir`) with the contents of the index file.

func GitCloneBare

func GitCloneBare(ctx context.Context, dir string) error

GitClone clones the dolt repo into `${dir}/dolt.git`

func GitVersion

func GitVersion(ctx context.Context) error

GitVersion runs git version

func IsCommit

func IsCommit(commit string) bool

IsCommit returns true if a commit is not a tag

func Run

func Run(commitList []string) error

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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