Address PR comments and add clean makefile target

This commit is contained in:
Jack Zampolin 2018-07-11 09:15:39 -07:00
parent 36a2214519
commit cc0f9bdd5b
2 changed files with 83 additions and 45 deletions

82
Gopkg.lock generated
View File

@ -3,44 +3,57 @@
[[projects]]
branch = "master"
digest = "1:6eda2de1e829809525d87a6bec9187a7dc08094310203b1f5ba3ddaa257ef522"
name = "github.com/aristanetworks/goarista"
packages = ["monotime"]
pruneopts = "T"
revision = "2c5933638c5ef1bc320b01486100788c81d57b99"
[[projects]]
branch = "master"
digest = "1:cafb561ce87d0eaa309ad6853380d437df3c1142561c5afa700311825aa38df1"
name = "github.com/btcsuite/btcd"
packages = ["btcec"]
pruneopts = "T"
revision = "fdfc19097e7ac6b57035062056f5b7b4638b8898"
[[projects]]
branch = "master"
digest = "1:20d11bf9fd5c6d8f7bb393229fdd981db8b4350aa9a05f28856b64640851c9b8"
name = "github.com/btcsuite/btcutil"
packages = ["bech32"]
pruneopts = "T"
revision = "ab6388e0c60ae4834a1f57511e20c17b5f78be4b"
[[projects]]
digest = "1:45d4124e3668b1c41750bef89e53d29cafcc5c67ad5793d08dfa34a6edbd21e0"
name = "github.com/cosmos/cosmos-sdk"
packages = [
"store",
"types",
"wire"
]
pruneopts = "T"
revision = "0d6f99d6d514916974a7cc1a7e4577c650e987e1"
[[projects]]
digest = "1:3aa953edddec96fd00285789ccd4a31efaff0a2979a3e35b77f5c19d5eaa37f7"
name = "github.com/davecgh/go-spew"
packages = ["spew"]
pruneopts = "T"
revision = "346938d642f2ec3594ed81d874461961cd0faa76"
version = "v1.1.0"
[[projects]]
branch = "master"
digest = "1:67d0b50be0549e610017cb91e0b0b745ec0cad7c613bc8e18ff2d1c1fc8825a7"
name = "github.com/edsrzf/mmap-go"
packages = ["."]
pruneopts = "T"
revision = "0bce6a6887123b67a60366d2c9fe2dfb74289d2e"
[[projects]]
digest = "1:68ab6afdca4a2b711034ccb97ba084e05de6e4469ae9969ce7a855954db54551"
name = "github.com/ethereum/go-ethereum"
packages = [
"common",
@ -72,32 +85,40 @@
"rpc",
"trie"
]
pruneopts = "T"
revision = "37685930d953bcbe023f9bc65b135a8d8b8f1488"
version = "v1.8.12"
[[projects]]
digest = "1:b18534450f89f7007960ff1804d63fb0cc6e7d1989446fcb05d77fb24afc51fc"
name = "github.com/go-kit/kit"
packages = [
"log",
"log/level",
"log/term"
]
pruneopts = "T"
revision = "4dc7be5d2d12881735283bcab7352178e190fc71"
version = "v0.6.0"
[[projects]]
digest = "1:31a18dae27a29aa074515e43a443abfd2ba6deb6d69309d8d7ce789c45f34659"
name = "github.com/go-logfmt/logfmt"
packages = ["."]
pruneopts = "T"
revision = "390ab7935ee28ec6b286364bba9b4dd6410cb3d5"
version = "v0.3.0"
[[projects]]
digest = "1:c4a2528ccbcabf90f9f3c464a5fc9e302d592861bbfd0b7135a7de8a943d0406"
name = "github.com/go-stack/stack"
packages = ["."]
pruneopts = "T"
revision = "259ab82a6cad3992b4e21ff5cac294ccb06474bc"
version = "v1.7.0"
[[projects]]
digest = "1:2a1db9bae44464f781d3637b67df38e896c6e1b9c902e27d24ee9037cb50f23b"
name = "github.com/gogo/protobuf"
packages = [
"gogoproto",
@ -107,10 +128,12 @@
"sortkeys",
"types"
]
pruneopts = "T"
revision = "1adfc126b41513cc696b209667c8656ea7aac67c"
version = "v1.0.0"
[[projects]]
digest = "1:6f3df7b8eccb559fa1bda8dae71fdb5f24da5e9aec2696e21f19e6d24062602f"
name = "github.com/golang/protobuf"
packages = [
"proto",
@ -119,50 +142,64 @@
"ptypes/duration",
"ptypes/timestamp"
]
pruneopts = "T"
revision = "925541529c1fa6821df4e44ce2723319eb2be768"
version = "v1.0.0"
[[projects]]
branch = "master"
digest = "1:968462840e6d86b12990015ac6ab297c022ccde102953040724be1df0e9e6c96"
name = "github.com/golang/snappy"
packages = ["."]
pruneopts = "T"
revision = "2e65f85255dbc3072edf28d6b5b8efc472979f5a"
[[projects]]
branch = "master"
digest = "1:cf296baa185baae04a9a7004efee8511d08e2f5f51d4cbe5375da89722d681db"
name = "github.com/hashicorp/golang-lru"
packages = [
".",
"simplelru"
]
pruneopts = "T"
revision = "0fb14efe8c47ae851c0034ed7a448854d3d34cf3"
[[projects]]
branch = "master"
digest = "1:14f2079ea27e7c67ecdab4f35e774463abc4f9d1806b5d674c0594b52127ab1d"
name = "github.com/jmhodges/levigo"
packages = ["."]
pruneopts = "T"
revision = "c42d9e0ca023e2198120196f842701bb4c55d7b9"
[[projects]]
branch = "master"
digest = "1:a64e323dc06b73892e5bb5d040ced475c4645d456038333883f58934abbf6f72"
name = "github.com/kr/logfmt"
packages = ["."]
pruneopts = "T"
revision = "b84e30acd515aadc4b783ad4ff83aff3299bdfe0"
[[projects]]
digest = "1:40e195917a951a8bf867cd05de2a46aaf1806c50cf92eebf4c16f78cd196f747"
name = "github.com/pkg/errors"
packages = ["."]
pruneopts = "T"
revision = "645ef00459ed84a119197bfb8d8205042c6df63d"
version = "v0.8.0"
[[projects]]
digest = "1:540558c17f78ee4f056aa043cf3389c283b56754db79112a2d64172e80e685db"
name = "github.com/rs/cors"
packages = ["."]
pruneopts = "T"
revision = "ca016a06a5753f8ba03029c0aa5e54afb1bf713f"
version = "v1.4.0"
[[projects]]
branch = "master"
digest = "1:9c39a878048f4a5468675b814fb7d2528d622f8c3612511ff0b5e2a48d451ad2"
name = "github.com/syndtr/goleveldb"
packages = [
"leveldb",
@ -178,31 +215,39 @@
"leveldb/table",
"leveldb/util"
]
pruneopts = "T"
revision = "c4c61651e9e37fa117f53c5a906d3b63090d8445"
[[projects]]
branch = "master"
digest = "1:8403202d034640f399279a4f735faabefeb6ee64bbcb03c9c93be1d4c7230382"
name = "github.com/tendermint/ed25519"
packages = [
".",
"edwards25519",
"extra25519"
]
pruneopts = "T"
revision = "d8387025d2b9d158cf4efb07e7ebf814bcce2057"
[[projects]]
digest = "1:4431caadcd2cc6a245bf0f6f61884029f5cc70833a8cc458cd1ba4a578b18c71"
name = "github.com/tendermint/go-amino"
packages = ["."]
pruneopts = "T"
revision = "2106ca61d91029c931fd54968c2bb02dc96b1412"
version = "0.10.1"
[[projects]]
digest = "1:d1d1de05d356e22e1b5b54159b31a22c869c94d94e9858d53b4577166a433237"
name = "github.com/tendermint/iavl"
packages = ["."]
pruneopts = "T"
revision = "9e5dc3e61f70b285bb25414452d47aca1ff34c1d"
version = "v0.8.2-rc0"
[[projects]]
digest = "1:d9e63f455b3a667e3960de2ce030d7fb59cb86bb222fea718fa9735a7a073beb"
name = "github.com/tendermint/tendermint"
packages = [
"abci/types",
@ -217,11 +262,13 @@
"libs/pubsub/query",
"types"
]
pruneopts = "T"
revision = "5923b6288fe8ce9581936ee97c2bf9cf9c02c2f4"
version = "v0.22.0-rc2"
[[projects]]
branch = "master"
digest = "1:2c4971d2da7bb27fa225a119dc96af2119dd096869c1228438a0b5fda5f6fe15"
name = "golang.org/x/crypto"
packages = [
"internal/subtle",
@ -232,10 +279,12 @@
"ripemd160",
"salsa20/salsa"
]
pruneopts = "T"
revision = "a49355c7e3f8fe157a85be2f77e6e269a0f89602"
[[projects]]
branch = "master"
digest = "1:2899a80c1fb88f3d6c0d82873176b22ae7dc89c615f27b848b2fdb662b3afc5a"
name = "golang.org/x/net"
packages = [
"context",
@ -247,9 +296,11 @@
"trace",
"websocket"
]
pruneopts = "T"
revision = "c21de06aaf072cea07f3a65d6970e5c7d8b6cd6d"
[[projects]]
digest = "1:24db346d9931fe01f1e9a02aba78ba22c1ecd55bf0f79dd10ba5169719cf002d"
name = "golang.org/x/text"
packages = [
"collate",
@ -267,15 +318,19 @@
"unicode/norm",
"unicode/rangetable"
]
pruneopts = "T"
revision = "f21a4dfb5e38f5895301dc265a8def02365cc3d0"
version = "v0.3.0"
[[projects]]
digest = "1:cfa1bbb9ee86ade0914bd5f8e8516386cf7d573957191ecb5163d8f6e023ca0c"
name = "google.golang.org/genproto"
packages = ["googleapis/rpc/status"]
pruneopts = "T"
revision = "7fd901a49ba6a7f87732eb344f6e3c5b19d1b200"
[[projects]]
digest = "1:1faab7c2380bc84698a62531c4af8c9475fbc7b3b1b2696f2f94feff97c47a49"
name = "google.golang.org/grpc"
packages = [
".",
@ -302,30 +357,55 @@
"tap",
"transport"
]
pruneopts = "T"
revision = "d11072e7ca9811b1100b80ca0269ac831f06d024"
version = "v1.11.3"
[[projects]]
digest = "1:3ccd10c863188cfe0d936fcfe6a055c95362e43af8e7039e33baade846928e74"
name = "gopkg.in/fatih/set.v0"
packages = ["."]
pruneopts = "T"
revision = "57907de300222151a123d29255ed17f5ed43fad3"
version = "v0.1.0"
[[projects]]
branch = "v2"
digest = "1:35056a4c53d0b725735422545c3c11bdc9007da2fdb644fee96f3a6b7c42c69f"
name = "gopkg.in/karalabe/cookiejar.v2"
packages = ["collections/prque"]
pruneopts = "T"
revision = "8dcd6a7f4951f6ff3ee9cbb919a06d8925822e57"
[[projects]]
branch = "v2"
digest = "1:3d3f9391ab615be8655ae0d686a1564f3fec413979bb1aaf018bac1ec1bb1cc7"
name = "gopkg.in/natefinch/npipe.v2"
packages = ["."]
pruneopts = "T"
revision = "c1b8fa8bdccecb0b8db834ee0b92fdbcfa606dd6"
[solve-meta]
analyzer-name = "dep"
analyzer-version = 1
inputs-digest = "6bd7ad37cf8a53408eeb32265fbc699bf2cc4e7a15b0b98182bcebb5c887cea1"
input-imports = [
"github.com/cosmos/cosmos-sdk/store",
"github.com/cosmos/cosmos-sdk/types",
"github.com/ethereum/go-ethereum/common",
"github.com/ethereum/go-ethereum/common/math",
"github.com/ethereum/go-ethereum/consensus",
"github.com/ethereum/go-ethereum/consensus/ethash",
"github.com/ethereum/go-ethereum/consensus/misc",
"github.com/ethereum/go-ethereum/core",
"github.com/ethereum/go-ethereum/core/state",
"github.com/ethereum/go-ethereum/core/types",
"github.com/ethereum/go-ethereum/core/vm",
"github.com/ethereum/go-ethereum/ethdb",
"github.com/ethereum/go-ethereum/params",
"github.com/ethereum/go-ethereum/rlp",
"github.com/ethereum/go-ethereum/rpc",
"github.com/ethereum/go-ethereum/trie",
"github.com/tendermint/tendermint/libs/db"
]
solver-name = "gps-cdcl"
solver-version = 1

View File

@ -1,5 +1,4 @@
PACKAGES=$(shell go list ./... | grep -v '/vendor/')
PACKAGES_NOCLITEST=$(shell go list ./... | grep -v '/vendor/' | grep -v github.com/cosmos/ethermint/cmd/gaia/cli_test)
COMMIT_HASH := $(shell git rev-parse --short HEAD)
BUILD_FLAGS = -tags netgo -ldflags "-X github.com/cosmos/ethermint/version.GitCommit=${COMMIT_HASH}"
@ -25,15 +24,8 @@ GOCYCLO_CHECK := $(shell command -v gocyclo 2> /dev/null)
all: get-tools get-vendor-deps install
########################################
### CI
ci: get-tools get-vendor-deps install
########################################
### Build
# This can be unified later, here for easy demos
build:
ifeq ($(OS),Windows_NT)
go build $(BUILD_FLAGS) -o build/ethermint.exe ./*.go
@ -44,8 +36,8 @@ endif
install:
go install $(BUILD_FLAGS) ./*.go
########################################
### Tools & dependencies
clean:
rm -rf ./build ./vendor
update-tools:
@echo "Updating golang dependencies"
@ -112,42 +104,8 @@ get-vendor-deps:
@echo "--> Running dep ensure"
@dep ensure -v
########################################
### Documentation
godocs:
@echo "--> Wait a few seconds and visit http://localhost:6060/pkg/github.com/cosmos/ethermint"
godoc -http=:6060
########################################
### Testing
# # TODO: FILL IN THE TESTING THINGS
# test: test_unit
#
# test_cli:
# @go test -count 1 -p 1 `go list github.com/cosmos/ethermint/cmd/gaia/cli_test`
#
# test_unit:
# @go test $(PACKAGES_NOCLITEST)
#
# test_race:
# @go test -race $(PACKAGES_NOCLITEST)
#
# test_cover:
# @bash tests/test_cover.sh
#
# test_lint:
# gometalinter.v2 --config=tools/gometalinter.json ./...
# !(gometalinter.v2 --disable-all --enable='errcheck' --vendor ./... | grep -v "client/")
# find . -name '*.go' -type f -not -path "./vendor*" -not -path "*.git*" | xargs gofmt -d -s
#
# format:
# find . -name '*.go' -type f -not -path "./vendor*" -not -path "*.git*" | xargs gofmt -w -s
# find . -name '*.go' -type f -not -path "./vendor*" -not -path "*.git*" | xargs misspell -w
#
# benchmark:
# @go test -bench=. $(PACKAGES_NOCLITEST)
.PHONY: build install update-tools get-tools get-vendor-deps godocs