Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Creating cmd directory, vendoring packages #1

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions Gopkg.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

34 changes: 34 additions & 0 deletions Gopkg.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# Gopkg.toml example
#
# Refer to https://golang.github.io/dep/docs/Gopkg.toml.html
# for detailed Gopkg.toml documentation.
#
# required = ["github.com/user/thing/cmd/thing"]
# ignored = ["github.com/user/project/pkgX", "bitbucket.org/user/project/pkgA/pkgY"]
#
# [[constraint]]
# name = "github.com/user/project"
# version = "1.0.0"
#
# [[constraint]]
# name = "github.com/user/project2"
# branch = "dev"
# source = "github.com/myfork/project2"
#
# [[override]]
# name = "github.com/x/y"
# version = "2.4.0"
#
# [prune]
# non-go = false
# go-tests = true
# unused-packages = true


[[constraint]]
branch = "master"
name = "github.com/percona/go-mysql"

[prune]
go-tests = true
unused-packages = true
File renamed without changes.
12 changes: 6 additions & 6 deletions script/build
Original file line number Diff line number Diff line change
Expand Up @@ -5,28 +5,28 @@ set -e
cd "$(dirname "$0")/.."

log() {
echo -e "\e[32m==> $*...\e[0m"
echo -e "\\e[32m==> $*...\\e[0m"
}

log2() {
echo -e "\e[32m====> $*...\e[0m"
echo -e "\\e[32m====> $*...\\e[0m"
}

ok() {
echo -e " \e[1mOK\e[0m"
echo -e " \\e[1mOK\\e[0m"
}

fail() {
echo -e "\e[1m\e[41m!!! $*\e[0m"
echo -e "\\e[1m\\e[41m!!! $*\\e[0m"
exit 1
}

mkdir -p build/{linux,darwin}

log "Building (slow_log_parse) for darwin"
GOOS=darwin go build -o build/darwin/slow_log_parse main.go || fail
GOOS=darwin go build -o build/darwin/slow_log_parse cmd/main.go || fail
ok

log "Building (slow_log_parse) for linux"
GOOS=linux go build -o build/linux/slow_log_parse main.go || fail
GOOS=linux go build -o build/linux/slow_log_parse cmd/main.go || fail
ok
1 change: 1 addition & 0 deletions vendor/github.com/percona/go-mysql
Submodule go-mysql added at ccc6f5