gobu

command module
v0.8.1 Latest Latest
Warning

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

Go to latest
Published: Nov 15, 2018 License: MIT Imports: 10 Imported by: 0

README

gobu

Build Status Go Report Card

Painless bootstrapping of GOlang. It downloads and installs GO for your OS and architecture, sets GOROOT, GOPATH and runs default shell or your command.

Usage of gobu:
usage: gobu [<flags>] <command> [<args> ...]

Bootstrap your golang environment

Flags:
  --help     Show context-sensitive help (also try --help-long and --help-man).
  --debug    Verbose mode.
  --version  Show application version.

Commands:
  help [<command>...]
    Show help.

  shell* [<flags>]
    Start a shell with Golang environment.

  versions
    List of all supported Golang releases.

You can find compiled binaries for your platform under "Releases" or if you prefer quick install:

$ curl -L https://github.com/dz0ny/gobu/releases/download/v0.8.0/gobu-`uname -s`-`uname -m` > /usr/local/bin/gobu
$ chmod +x /usr/local/bin/gobu

Example starting new project

$ mkdir -p project/src/hello_world
$ cd project
$ gobu shell --version=1.9.3 or 1.10rc1
2016/08/25 09:55:52 >> You are now in a new GOBU shell. To exit, type 'exit'
2016/08/25 09:55:52 GOPATH /home/dz0ny/project
2016/08/25 09:55:52 GOROOT /home/dz0ny/.gobu/1.7/go
$ nano src/hello_world/main.go

package main

import "fmt"
func main() {
    fmt.Println("hello world")
}

$ go build hello_world
$ tree
.
├── hello_world
└── src
    └── hello_world
        └── main.go

What it does

Downloads latest version from releases and runs it in shell. After the GO is bootstrapped you will end up in shell with "Vendoring" enabled and with fresh env set up for you.

Why

Because I hate setting environment every time for every project(not library).

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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