Do things the "Go" way
This commit is contained in:
parent
629435282e
commit
642a4586b2
2
Makefile
2
Makefile
|
@ -1,5 +1,5 @@
|
||||||
all:
|
all:
|
||||||
@mkdir -p bin/
|
@mkdir -p bin/
|
||||||
go build -o bin/packer packer/bin-packer
|
go build -o bin/packer
|
||||||
|
|
||||||
.PHONY: all
|
.PHONY: all
|
||||||
|
|
|
@ -2,11 +2,7 @@
|
||||||
package main
|
package main
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"fmt"
|
|
||||||
"os"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
fmt.Printf("%#v\n", os.Args)
|
|
||||||
fmt.Println("Hello, world.")
|
|
||||||
}
|
}
|
11
setup.sh
11
setup.sh
|
@ -1,11 +0,0 @@
|
||||||
#!/usr/bin/env bash
|
|
||||||
|
|
||||||
# Get the full path to the directory where this script is, because
|
|
||||||
# GOPATH prefers full paths.
|
|
||||||
SOURCE="${BASH_SOURCE[0]}"
|
|
||||||
while [ -h "$SOURCE" ] ; do SOURCE="$(readlink "$SOURCE")"; done
|
|
||||||
DIR="$( cd -P "$( dirname "$SOURCE" )" && pwd )"
|
|
||||||
|
|
||||||
# Setup our GOPATH
|
|
||||||
echo "Setting GOPATH to: ${DIR}"
|
|
||||||
export GOPATH="${DIR}"
|
|
Loading…
Reference in New Issue