diff --git a/.gitignore b/.gitignore index 3968c15..3da81d3 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,2 @@ /github-nippou /pkg -/vendor diff --git a/.travis.yml b/.travis.yml index a41ea67..6eae0e2 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,7 +1,7 @@ language: go go: - - 1.10.x + - 1.12.x os: - linux diff --git a/Gopkg.lock b/Gopkg.lock deleted file mode 100644 index fb5097f..0000000 --- a/Gopkg.lock +++ /dev/null @@ -1,126 +0,0 @@ -# This file is autogenerated, do not edit; changes may be undone by the next 'dep ensure'. - - -[[projects]] - digest = "1:bcb38c8fc9b21bb8682ce2d605a7d4aeb618abc7f827e3ac0b27c0371fdb23fb" - name = "github.com/golang/protobuf" - packages = ["proto"] - pruneopts = "" - revision = "925541529c1fa6821df4e44ce2723319eb2be768" - version = "v1.0.0" - -[[projects]] - branch = "master" - digest = "1:deffa1949bb382121a8d38a7540feeb80122a9e74103e0195fff6a1ca4088ecb" - name = "github.com/google/go-github" - packages = ["github"] - pruneopts = "" - revision = "b1658317c4f5c8dd7000d94ab8a9b56039412cc6" - -[[projects]] - branch = "master" - digest = "1:9abc49f39e3e23e262594bb4fb70abf74c0c99e94f99153f43b143805e850719" - name = "github.com/google/go-querystring" - packages = ["query"] - pruneopts = "" - revision = "53e6ce116135b80d037921a7fdd5138cf32d7a8a" - -[[projects]] - digest = "1:870d441fe217b8e689d7949fef6e43efbc787e50f200cb1e70dbca9204a1d6be" - name = "github.com/inconshreveable/mousetrap" - packages = ["."] - pruneopts = "" - revision = "76626ae9c91c4f2a10f34cad8ce83ea42c93bb75" - version = "v1.0" - -[[projects]] - digest = "1:79c3c0b8805e9331a87c459b37dd007d4389cc511dfa2beeae1d6f35986cd4a4" - name = "github.com/rakyll/statik" - packages = ["fs"] - pruneopts = "" - revision = "3bac566d30cdbeddef402a80f3d6305860e59f12" - version = "v0.1.6" - -[[projects]] - branch = "master" - digest = "1:50b5be512f924d289f20e8b2aef8951d98b9bd8c44666cf169514906df597a4c" - name = "github.com/skratchdot/open-golang" - packages = ["open"] - pruneopts = "" - revision = "75fb7ed4208cf72d323d7d02fd1a5964a7a9073c" - -[[projects]] - branch = "master" - digest = "1:3432164f2ad1188a576d877969c092967a777c79f0020e0dd95b62cb89fb8f35" - name = "github.com/spf13/cobra" - packages = ["."] - pruneopts = "" - revision = "a1e4933ab784095895e33dbe9f001ba10cfe2060" - -[[projects]] - digest = "1:261bc565833ef4f02121450d74eb88d5ae4bd74bfe5d0e862cddb8550ec35000" - name = "github.com/spf13/pflag" - packages = ["."] - pruneopts = "" - revision = "e57e3eeb33f795204c1ca35f56c44f83227c6e66" - version = "v1.0.0" - -[[projects]] - branch = "master" - digest = "1:b4ba046df563f56fe42b6270b20039107a37e1ab47c97aa47a16f848aa5b6d9a" - name = "golang.org/x/net" - packages = [ - "context", - "context/ctxhttp", - ] - pruneopts = "" - revision = "cbe0f9307d0156177f9dd5dc85da1a31abc5f2fb" - -[[projects]] - branch = "master" - digest = "1:dd57134ebff8e1a1a77c9f145a28cad8470da6bb9053d6ff2bc552ecd7f8bc92" - name = "golang.org/x/oauth2" - packages = [ - ".", - "internal", - ] - pruneopts = "" - revision = "543e37812f10c46c622c9575afd7ad22f22a12ba" - -[[projects]] - digest = "1:934fb8966f303ede63aa405e2c8d7f0a427a05ea8df335dfdc1833dd4d40756f" - name = "google.golang.org/appengine" - packages = [ - "internal", - "internal/base", - "internal/datastore", - "internal/log", - "internal/remote_api", - "internal/urlfetch", - "urlfetch", - ] - pruneopts = "" - revision = "150dc57a1b433e64154302bdc40b6bb8aefa313a" - version = "v1.0.0" - -[[projects]] - branch = "v2" - digest = "1:60ccede33d50c82c86e907255319a6f40dca4ac395e5ee143638176d3b871069" - name = "gopkg.in/yaml.v2" - packages = ["."] - pruneopts = "" - revision = "7b8349ac747c6a24702b762d2c4fd9266cf4f1d6" - -[solve-meta] - analyzer-name = "dep" - analyzer-version = 1 - input-imports = [ - "github.com/google/go-github/github", - "github.com/rakyll/statik/fs", - "github.com/skratchdot/open-golang/open", - "github.com/spf13/cobra", - "golang.org/x/oauth2", - "gopkg.in/yaml.v2", - ] - solver-name = "gps-cdcl" - solver-version = 1 diff --git a/Gopkg.toml b/Gopkg.toml deleted file mode 100644 index 7756e6c..0000000 --- a/Gopkg.toml +++ /dev/null @@ -1,46 +0,0 @@ - -# Gopkg.toml example -# -# Refer to https://github.com/golang/dep/blob/master/docs/Gopkg.toml.md -# 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" - - -[[constraint]] - branch = "master" - name = "github.com/google/go-github" - -[[constraint]] - branch = "master" - name = "github.com/skratchdot/open-golang" - -[[constraint]] - branch = "master" - name = "github.com/spf13/cobra" - -[[constraint]] - branch = "master" - name = "golang.org/x/oauth2" - -[[constraint]] - branch = "v2" - name = "gopkg.in/yaml.v2" - -[[constraint]] - name = "github.com/rakyll/statik" - version = "0.1.6" diff --git a/Makefile b/Makefile index f37d14c..7db9ae5 100644 --- a/Makefile +++ b/Makefile @@ -4,6 +4,9 @@ CONFIGS := $(wildcard config/*) VERSION := v$(shell grep 'const Version ' lib/version.go | sed -E 's/.*"(.+)"$$/\1/') PACKAGES := $(shell go list ./...) +# If go-1.13 releases, I can remove this. +export GO111MODULE := on + ifeq (Windows_NT, $(OS)) NAME := $(NAME).exe endif @@ -12,14 +15,8 @@ all: $(NAME) # Install dependencies for development .PHONY: deps -deps: dep statik - dep ensure - -.PHONY: dep -dep: -ifeq ($(shell command -v dep 2> /dev/null),) - go get github.com/golang/dep/cmd/dep -endif +deps: statik + go mod download .PHONY: statik statik: @@ -54,13 +51,13 @@ test: statik/statik.go test-all: deps-test-all vet lint test .PHONY: deps-test-all -deps-test-all: dep statik golint statik/statik.go - dep ensure +deps-test-all: statik golint statik/statik.go + go mod download .PHONY: golint golint: ifeq ($(shell command -v golint 2> /dev/null),) - go get github.com/golang/lint/golint + go get golang.org/x/lint/golint endif .PHONY: vet diff --git a/go.mod b/go.mod new file mode 100644 index 0000000..92d2ded --- /dev/null +++ b/go.mod @@ -0,0 +1,18 @@ +module github.com/masutaka/github-nippou + +go 1.12 + +require ( + github.com/golang/protobuf v1.0.0 + github.com/google/go-github v0.0.0-20180223213941-b1658317c4f5 + github.com/google/go-querystring v0.0.0-20170111101155-53e6ce116135 + github.com/inconshreveable/mousetrap v1.0.0 + github.com/rakyll/statik v0.1.6 + github.com/skratchdot/open-golang v0.0.0-20160302144031-75fb7ed4208c + github.com/spf13/cobra v0.0.0-20180221175153-a1e4933ab784 + github.com/spf13/pflag v1.0.0 + golang.org/x/net v0.0.0-20180218175443-cbe0f9307d01 + golang.org/x/oauth2 v0.0.0-20180207181906-543e37812f10 + google.golang.org/appengine v1.0.0 + gopkg.in/yaml.v2 v2.0.0-20190319135612-7b8349ac747c +) diff --git a/go.sum b/go.sum new file mode 100644 index 0000000..6a12652 --- /dev/null +++ b/go.sum @@ -0,0 +1,22 @@ +github.com/golang/protobuf v1.0.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= +github.com/google/go-github v0.0.0-20180223213941-b1658317c4f5 h1:vofPH6xG0sIqsrKetTD6DsYZJpLvRDEK4ohecZ3gHlo= +github.com/google/go-github v0.0.0-20180223213941-b1658317c4f5/go.mod h1:zLgOLi98H3fifZn+44m+umXrS52loVEgC2AApnigrVQ= +github.com/google/go-querystring v0.0.0-20170111101155-53e6ce116135 h1:zLTLjkaOFEFIOxY5BWLFLwh+cL8vOBW4XJ2aqLE/Tf0= +github.com/google/go-querystring v0.0.0-20170111101155-53e6ce116135/go.mod h1:odCYkC5MyYFN7vkCjXpyrEuKhc/BUO6wN/zVPAxq5ck= +github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= +github.com/rakyll/statik v0.1.6 h1:uICcfUXpgqtw2VopbIncslhAmE5hwc4g20TEyEENBNs= +github.com/rakyll/statik v0.1.6/go.mod h1:OEi9wJV/fMUAGx1eNjq75DKDsJVuEv1U0oYdX6GX8Zs= +github.com/skratchdot/open-golang v0.0.0-20160302144031-75fb7ed4208c h1:fyKiXKO1/I/B6Y2U8T7WdQGWzwehOuGIrljPtt7YTTI= +github.com/skratchdot/open-golang v0.0.0-20160302144031-75fb7ed4208c/go.mod h1:sUM3LWHvSMaG192sy56D9F7CNvL7jUJVXoqM1QKLnog= +github.com/spf13/cobra v0.0.0-20180221175153-a1e4933ab784 h1:I6Gja8SUbC12v3wjn/hN2o2swQR8gz62VTKKALMv+7Y= +github.com/spf13/cobra v0.0.0-20180221175153-a1e4933ab784/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ= +github.com/spf13/pflag v1.0.0 h1:oaPbdDe/x0UncahuwiPxW1GYJyilRAdsPnq3e1yaPcI= +github.com/spf13/pflag v1.0.0/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= +golang.org/x/net v0.0.0-20180218175443-cbe0f9307d01 h1:po1f06KS05FvIQQA2pMuOWZAUXiy1KYdIf0ElUU2Hhc= +golang.org/x/net v0.0.0-20180218175443-cbe0f9307d01/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= +golang.org/x/oauth2 v0.0.0-20180207181906-543e37812f10 h1:ztZz7pTbygSoJgnsO6TYI8nOvZp3HowfTtpGeFuSu5g= +golang.org/x/oauth2 v0.0.0-20180207181906-543e37812f10/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= +google.golang.org/appengine v1.0.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= +gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= +gopkg.in/yaml.v2 v2.0.0-20190319135612-7b8349ac747c h1:nsJYChHWxeFA6+48RmvBXEvQNanNyh933kZYWiu2HBE= +gopkg.in/yaml.v2 v2.0.0-20190319135612-7b8349ac747c/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=