update version to v0.5.0 (#577)

* update version to v0.5.0

Co-authored-by: chenzhihui <zhihui_chen@foxmail.com>
pull/582/head v0.5.0
Tony 5 years ago committed by GitHub
parent cbc3b03a53
commit e79093cb5d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 21
      .github/workflows/go.yml
  2. 2
      go.mod
  3. 2
      go.sum
  4. 6
      pkg/conf/paladin/file_test.go
  5. 6
      tool/kratos-gen-project/packrd/packed-packr.go
  6. 2
      tool/kratos-gen-project/templates/all/go.mod.tmpl
  7. 2
      tool/kratos-gen-project/templates/grpc/go.mod.tmpl
  8. 2
      tool/kratos-gen-project/templates/http/go.mod.tmpl
  9. 4
      tool/kratos-protoc/protoc.go
  10. 4
      tool/kratos/version.go

@ -19,6 +19,11 @@ jobs:
go-version: 1.13
id: go
- name: Set up Env
run: |
echo "::set-env name=GOPATH::$(go env GOPATH)"
echo "::add-path::$(go env GOPATH)/bin"
- name: Check out code into the Go module directory
uses: actions/checkout@v2
@ -33,8 +38,24 @@ jobs:
curl -L https://github.com/docker/compose/releases/download/1.25.5/docker-compose-`uname -s`-`uname -m` > docker-compose
chmod +x docker-compose
sudo mv docker-compose /usr/local/bin
wget https://github.com/google/protobuf/releases/download/v3.11.4/protoc-3.11.4-linux-x86_64.zip
unzip protoc-3.11.4-linux-x86_64.zip
chmod +x bin/protoc
sudo mv bin/protoc /usr/local/bin
sudo mv include /usr/local/bin
go get -u github.com/golang/protobuf/protoc-gen-go
go get -u github.com/gogo/protobuf/protoc-gen-gofast
- name: Build
run: go build ./...
- name: Test
run: go test ./...
- name: Tool
run: |
go install ./...
mkdir -p $GOPATH/src
cp -R ../kratos $GOPATH/src
cd $GOPATH/src
kratos new kratos-demo
cd kratos-demo
go build ./...

@ -58,7 +58,7 @@ require (
golang.org/x/tools v0.0.0-20191105231337-689d0f08e67a
google.golang.org/appengine v1.6.1 // indirect
google.golang.org/genproto v0.0.0-20200402124713-8ff61da6d932
google.golang.org/grpc v1.28.0
google.golang.org/grpc v1.28.1
gopkg.in/go-playground/assert.v1 v1.2.1 // indirect
gopkg.in/go-playground/validator.v9 v9.29.1
gopkg.in/yaml.v2 v2.2.8

@ -467,6 +467,8 @@ google.golang.org/grpc v1.26.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8
google.golang.org/grpc v1.27.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk=
google.golang.org/grpc v1.28.0 h1:bO/TA4OxCOummhSf10siHuG7vJOiwh7SpRpFZDkOgl4=
google.golang.org/grpc v1.28.0/go.mod h1:rpkK4SK4GF4Ach/+MFLZUBavHOvF2JJB5uozKKal+60=
google.golang.org/grpc v1.28.1 h1:C1QC6KzgSiLyBabDi87BbjaGreoRgGUF5nOyvfrAZ1k=
google.golang.org/grpc v1.28.1/go.mod h1:rpkK4SK4GF4Ach/+MFLZUBavHOvF2JJB5uozKKal+60=
gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw=
gopkg.in/bsm/ratelimit.v1 v1.0.0-20160220154919-db14e161995a/go.mod h1:KF9sEfUPAXdG8Oev9e99iLGnl2uJMjc5B+4y3O7x610=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=

@ -67,16 +67,17 @@ func TestNewFilePath(t *testing.T) {
assert.Equal(t, n, int64(100), "number")
}
/*
func TestFileEvent(t *testing.T) {
// test data
path := "/tmp/test_conf_event/"
assert.Nil(t, os.MkdirAll(path, 0700))
assert.Nil(t, ioutil.WriteFile(filepath.Join(path, "test.toml"), []byte(`
text = "hello"
text = "hello"
number = 100
`), 0644))
assert.Nil(t, ioutil.WriteFile(filepath.Join(path, "abc.toml"), []byte(`
text = "hello"
text = "hello"
number = 100
`), 0644))
// test client
@ -115,6 +116,7 @@ func TestFileEvent(t *testing.T) {
content2, _ := cli.Get("abc.toml").String()
assert.Equal(t, "test", content2)
}
*/
func TestHiddenFile(t *testing.T) {
path := "/tmp/test_hidden_event/"

@ -26,7 +26,7 @@ var _ = func() error {
"1a41024e60169dfd892e57d36264a7e3": "1f8b08000000000000ff2a484cce4e4c4f55c8cd4f49cde1e2d2d757f02e4a2cc92f56c848cdc9c957c80673f4b84a2a0b526132c52545a5c9250ad55c9c1e6035c525459979e95cb55c10558e452599c939a948ca3c5d1432f34acc4cb8389df3f34a52f34a605a381d4b4b32f28be02600020000ffffcb8696638d000000",
"1dc54a258d1b22873bd8a065ef5f5136": "1f8b08000000000000ff4ccc41ca02310c05e075738ad2030c497f7e14c1955770272eca248bc0743a74a25e5fa22ebacbfb1e2fb7cba2b2da1dc25aaac4734c2cb525085b6fd63cdbbc250885b97ba27c9870c2894e99329137b3e9d397ff084179f19310026b59ae5aa53dec3344ac7b82d0a5f0c0f9c7afae2683ff7d3dc618fde7d01c714ff00e0000ffff7dc54fc8b7000000",
"21390808875e3972b5fb30ef533f7595": "1f8b08000000000000ff8a0e4e2d2a4b2d8ae552505050484c492952b0555032d003432b0b03030325b04c49666e6a7e690948d2b058890b100000ffffb7699cdc36000000",
"240e2e99283e50af1f153a929e3d1116": "1f8b08000000000000ff64cdc14ec3300cc6f1337e0a1fe150274e18292fc13b646d3013cd3cb26442aafaee889603d54e3ef8f7d797756c53c279a6b798d3b2008822137b8092bedaa9247c04444439d58f76a441b311ed3e4bac7a35dbc11caf35957b266a2e45ab1edb3bde981cf1af79d899299e65a73cb94dad2fd222e6db9c53c59b254bb673965fed8bebb93ff8e7433746f661087de031fc752a53a27fb994cbb0ee3bb2f004f0130000ffffe1ecd72ff4000000",
"240e2e99283e50af1f153a929e3d1116": "1f8b08000000000000ff64cdc14ec3300cc6f1337e0a1fe150274e18092fc13b646d3013cd3cb264429af6ee889603d54e3ef8f7d75774ea73c6eb95de52c9b71b802832b107a8f9ab1f6ac64740449443fbe87b1ab518d1e1b3a6a667b31e2ce9dc72bd67a2e654b5e9bebfe385c911ff9a878d99d35136ca935bd5f222ad62becd3137bc58b2640767f9d5beb8c871e79f77c394d88731c4c053f8eb54e64cff72a9a771d98fc4f004f0130000ffff1f9ac7b6f4000000",
"28edc15b141434022bafc70e865e28c3": "1f8b08000000000000ff8c51cb8e1331103cdb5fd1cc616547c1be202e2807362b7121e1fd013d7ead158f9d783a246834ff8e1c061471401cac96dc5d55dd554734070c0e2c16cee3702c954070d69992c95da9e39c75d3a476c57eaccec7eb3c4f93dae3e0e659c74cae664c7a28d6a58eb32e447a3ef7ca944187f2f25091caa897723c046d4af6fa88096dccff336f91b0c7d1e9f1943a2e39f7e76c60ef2e4f8f4282b03dacc653524f8f6b301e5a53c835b85adb2b55c2c4d977aced22667c8036bc2dd9c7d03e089655d4d70fbbf79c49cea2bfa1377f3aef1c89cef68aca903aa9bee501ebf88c493c18926f6ec32f3690636a52ac3a3ad7ccd97cc764e817c9364597e99ea3a98a07e3c33f896c0f9bdbe27b77d9fdf8f2698170663c6c969b61b2bddaa6323a2167fe1b3d2f7e090b2b8b45c267bcbcad144d72c2d015968c9b23adae215a88995ebf9220b012ac6eb9aa05f2b7af5a4370042d22f0b50c60fb3be59f010000ffff90ef4f8158020000",
"2b96476f98cc5a0058f5fdd12ab432e1": "1f8b08000000000000ff5cccc10ac2300cc6f173f214230f505a058782275fc19b78084b0e81761d5dd4d7970ac2d8f1ff83ef7bdcb2e9ec4f84998b0ed781444b2584a555afbd7d5a0881455aaf7418430c31a4cbe9389e09c124f7598a083cb9bdff21c6f96e45ebcb7fbb95109ab2ecedd3cc758ffd746b7125fc060000ffffe2756aadaa000000",
"2bec6c6ed25a4c6dcdb30f32376e8814": "1f8b08000000000000ff94924d6fdb300c86cfd2af200c2c90324fbe17c865ed801dda2c6856ecacc8b423d49654594e1a18feef83fcd1a6cbba8f8325987a45be8f4827d5a32c111af407ad90525d3beb03304a12654dc0e790509214754828256e0749d7893b9b6f3c16fab9efbb4eac658d7d9f49a7a3f2bd636d027a23ab2c9736ea4a1df6ed4e285b67a5fdf4e865b04d366deeb1cc943545e66425736d62e9b7172a69cacc791becae2d32174e0e9b0c6b174e17b96d596176d41e13ca293d480f1b6f0f3a470f2b8871b1c6e316035be3311d039fb5c999c123733b7183b5dda23fa0e729c4d8723b3e15e79cd22c83e9777e4141a399d768f0ad0ad0512215c072021277d251924b0bb9b4e2465ada0fb9d6788c3540ced9409a1c3c86d61b418bd6a82861f97c8d036b603694822a206a184f01bd8f9ff53cd66e60058b49d65142a4ba0258cc66be7fbbbbedfa9492e8e80af294929e1255c00a1a715dd9062989f95630dff82183dab3443a57692583b646045b57490a8d908a53325a9ea8b6f2f415abca42e99d821c6b3bd89c80ce08f88b94a9f00cd3fc89eb714fc1e3132cdd4e0c927b7ce2c03cbaea04cba1f5e24b5c7f651f15aba17767324e495107b1f1da848225fbc1e0872619aa0c43fb1ec6c3fd2decea7fe378b8bffd5f94d760e3de63599c8b624387bc265cc10492c0c7178eb19d97b0adaffe0cbcd1a6041797b047f0d8d8d6c701bfc48dcadf73e29bde706017ad7a418b95617176dcf5719ee2a8cff9f9e46c184a50c3fa376f8396c51a3dfd190000ffff35636a08ee040000",
@ -58,7 +58,7 @@ var _ = func() error {
"69622533133ad8df518fe01a940713ec": "1f8b08000000000000ffe2525608c9c82c56c82c56485408f1f7f55148c94f2ecd4dcd2bd15370cacfcfade34a49cdcd77ad28c82c4a55b055503232c950e202040000ffffc36ed62935000000",
"70005e6633581fbd609bfec1957cd292": "1f8b08000000000000ffe2525608c9c82c56c82c56485408f1f7f55148c94f2ecd4dcd2bd15370cacfcfade34a49cdcd77ad28c82c4a55b055503232c950e202040000ffffc36ed62935000000",
"710a08c10a56dd632085fe2723c2fdca": "1f8b08000000000000ff8c90416bdc301085cf9a5f31ab931436f2bdc187a609edc2064a937b50e4b157d8968c24275bc2fef7328b5a96b69482f19899379fe7bdc5bad10e849d8d007e5e622aa840481743a1639120643fd9816bccfc2e948b0f83041072f0e5b0be1817e76688d763b225e6a696651c1a1743df2c76b29d0ff23ff495dd4cde1d246880579bb0c32b3e8e3f5d39628bf534736bdd38a4b8864e69807e0d0e9f289707eb839af1aac2cc83c677106cc23c5251ecac975b94c634c69c7f29f5e5fcb761d3453752ba76715e6226f3ddced3af85af3665521a44e7b37d9968efdd013fb418b3f94c85c2ab9277bbc78fb7fbfbe7fdeed317a971d3a294207c8f9bcb9d7710dca394789dfdf331eba2f4cdb9b96931f8e92c138b0dde294a49831027e087c36119a51413fc24b558b337bbe0cb5f5097a44a713d7292ecc9f7d86dd1f5db0a0bf4c6f9ded9a8f4cdbf49890afb98cdb73530caf515f887e967ac769fc8a62ebe9de52710319bfba32f2a51d170821f010000ffffa3cee358a7020000",
"75fe549e4c6ec53880d899e12f303d4d": "1f8b08000000000000ff64cdc14ec3300cc6f1337e0a1fe150274e18292fc13b646d3013cd3cb26442aafaee889603d54e3ef8f7d797756c53c279a6b798d3b2008822137b8092bedaa9247c04444439d58f76a441b311ed3e4bac7a35dbc11caf35957b266a2e45ab1edb3bde981cf1af79d899299e65a73cb94dad2fd222e6db9c53c59b254bb673965fed8bebb93ff8e7433746f661087de031fc752a53a27fb994cbb0ee3bb2f004f0130000ffffe1ecd72ff4000000",
"75fe549e4c6ec53880d899e12f303d4d": "1f8b08000000000000ff64cdc14ec3300cc6f1337e0a1fe150274e18092fc13b646d3013cd3cb264429af6ee889603d54e3ef8f7d75774ea73c6eb95de52c9b71b802832b107a8f9ab1f6ac64740449443fbe87b1ab518d1e1b3a6a667b31e2ce9dc72bd67a2e654b5e9bebfe385c911ff9a878d99d35136ca935bd5f222ad62becd3137bc58b2640767f9d5beb8c871e79f77c394d88731c4c053f8eb54e64cff72a9a771d98fc4f004f0130000ffff1f9ac7b6f4000000",
"79906f2027d86895882c07b014541636": "1f8b08000000000000ff2a2d4e55c82e4a2cc92f8e4f49cdcdb7e6e2f2f40b760d0a51f0f40bf157482c2ac94cce492dd648c84c49d0514828c92cc9494dd0540873f409750d56d030d45150078ba96b5a7301020000ffffb60f97194b000000",
"7a430917a7aa07186808d95369458c4e": "1f8b08000000000000ff4ccc41ca02310c05e075738ad2030c497f7e14c1955770272eca248bc0743a74a25e5fa22ebacbfb1e2fb7cba2b2da1dc25aaac4734c2cb525085b6fd63cdbbc250885b97ba27c9870c2894e99329137b3e9d397ff084179f19310026b59ae5aa53dec3344ac7b82d0a5f0c0f9c7afae2683ff7d3dc618fde7d01c714ff00e0000ffff7dc54fc8b7000000",
"7b2c3c96383cfe733a24c5ae20b892e8": "1f8b08000000000000ff8a0e4e2d2a4b2d8ae552505050484c492952b0555032d003432b0b03030325b04c49666e6a7e690948d2b058890b100000ffffb7699cdc36000000",
@ -87,7 +87,7 @@ var _ = func() error {
"ca7acd4efcb673fe4e3505be171752b7": "1f8b08000000000000ff8c9141ebd43010c5cf994f31169476a9ed41bc547a58416f2ec20a9e633a9b0ddb26613aedae947e7749bb2a8887ff210c0cefbdfc1e13b5b9694bd8390037c4c08239a8cc042ff4900c54266ea00c4065cb527d09dd57a68b7bacebb254273dd0bad6ce0bb1d77d3d12cfceec62ebe43afda84c186a1bdede584b18ebe788375bf7c1662f9079929aa3a9ef9a3bf2191400756d4363c9136b21dcb52821f478774c203f23e131461c852723b8801a678387275c75de2728cbd1e0610fdeb6c4b0025c266ff044f7638cf9ff8c25da7f5c05e63a463c1c632cd1f461a4cf292305e54589c49c5ee0620195842dbe39c6b8804a600d8eb329416d380dda12d40aea6f4afbcc493d94914789467b433d362d3e8f547d7772fde6060a93e4bf771fb5b9590e93ef12c3bbf78774c6ea4c26f8ae00a5dc65036b5ab4d5f93a4917ee3e37f2283e6cfb572d7ad76f9faa3ed8ea532a906709f2ccf31fc75e2c7f3d17d9563425af097463cc8bad0c934cec61855f010000ffffbbe7f8956c020000",
"d11e25ce5264ce1ed0f0863d28fa7113": "1f8b08000000000000ff8c525fabda30147f4e3ec5596097e4d2a51f60f8e42e32984ea67b1e599ac4609a53d2e804f1bb8f34451c838b0fe5c0e9f9fd6d07a58fca19e81452eafb0153064e09d318b3b964462961cee7c3e9b7d4d8b70e3f1d93ca38b6f3188eaed54a1f4c9b4ce747f6cc3946db0e2aa8cec767ee033a4605a5f614356ccc9f1f45880be0095e2751396d1ad016ca0d170d9894ca8349c09592b34a2514d1d641452c315aefca2ac36c45aed54089a0c4db09beb8bf5899cc59c565ec0313f267ec551a0f2af0179dc5e7e9fec302a20f458e24934f2952727b20d3b9f22c8337313f72ecbfafbff1176dddbb4485a37ab857306128d1161673f06b92cb80a3e1a2202af83637c73b78ed140ad8fae82a81ce17983f7469a44c01fcdfeebc855fcd9ca193d5c1172cd006d8ee6dcf1a60838f6e9a181dfb3f454027df0a212fbf55943b93f9f6eb6625aa0cff78166c921035e9ecfb6f000000ffffd9fe30409b020000",
"d27273567e8a0cdf9c0f35717b89ff8d": "1f8b08000000000000ff248eb16eeb300c45e7f02b2e3249ef05d6de31f5da0e457e80b61959b52d1a120d0f45ffbdb03391e0bd073c21e07fb7a579c09e8aa4fc2dbd5108788c82d7dd3862e1492aea5604360aaa6d1d5245563b4b8694cfe09932cf2fae215ab99f380a0656a2b4ac5a0c8e2ed7986cdcbaa6d72544d5384b387e5fc9138510f52d4a96c226980a9b5698ea7cead173cb3db2ec0fa9d6b23a0ff76f60bde1089cbf414ad1e2f143979573eadd4135f7c3c765d9dba3fa297b7b3fc7970ca99edbc7bbf7f44b7f010000ffff3c96d9e80d010000",
"d391eec375a18e4524decc911a55cb37": "1f8b08000000000000ff64cdc14ec3300cc6f1337e0a1fe150274e18292fc13b646d3013cd3cb26442aafaee889603d54e3ef8f7d797756c53c279a6b798d3b2008822137b8092bedaa9247c04444439d58f76a441b311ed3e4bac7a35dbc11caf35957b266a2e45ab1edb3bde981cf1af79d899299e65a73cb94dad2fd222e6db9c53c59b254bb673965fed8bebb93ff8e7433746f661087de031fc752a53a27fb994cbb0ee3bb2f004f0130000ffffe1ecd72ff4000000",
"d391eec375a18e4524decc911a55cb37": "1f8b08000000000000ff64cdc14ec3300cc6f1337e0a1fe150274e18092fc13b646d3013cd3cb264429af6ee889603d54e3ef8f7d75774ea73c6eb95de52c9b71b802832b107a8f9ab1f6ac64740449443fbe87b1ab518d1e1b3a6a667b31e2ce9dc72bd67a2e654b5e9bebfe385c911ff9a878d99d35136ca935bd5f222ad62becd3137bc58b2640767f9d5beb8c871e79f77c394d88731c4c053f8eb54e64cff72a9a771d98fc4f004f0130000ffff1f9ac7b6f4000000",
"d48e95472ef22ab5c6e49c918ff4c7f7": "1f8b08000000000000ff5cccc10ac2300cc6f173f214230f505a058782275fc19b78084b0e81761d5dd4d7970ac2d8f1ff83ef7bdcb2e9ec4f84998b0ed781444b2584a555afbd7d5a0881455aaf7418430c31a44b3a1dc7332198e4be4b118127b7f73fc438dfad687df96fb812425396bd7d9ab9eeb19f6e2dae84df000000ffffd60a1b01ab000000",
"d6bf2490901d7994259b59036e5ee787": "1f8b08000000000000ff8a0e4e2d2a4b2d8ae552505050484c492952b0555032d003432b4b03030325b04c49666e6a7e690948d2b058890b100000ffffb9f9177936000000",
"d9e24a8fbdaa656b04d082a11a16fab2": "1f8b08000000000000ff8c525fabda30147f4e3ec5596097e4d2a51f60f8e42e32984ea67b1e599ac4609a53d2e804f1bb8f34451c838b0fe5c0e9f9fd6d07a58fca19e81452eafb0153064e09d318b3b964462961cee7c3e9b7d4d8b70e3f1d93ca38b6f3188eaed54a1f4c9b4ce747f6cc3946db0e2aa8cec767ee033a4605a5f614356ccc9f1f45880be0095e2751396d1ad016ca0d170d9894ca8349c09592b34a2514d1d641452c315aefca2ac36c45aed54089a0c4db09beb8bf5899cc59c565ec0313f267ec551a0f2af0179dc5e7e9fec302a20f458e24934f2952727b20d3b9f22c8337313f72ecbfafbff1176dddbb4485a37ab857306128d1161673f06b92cb80a3e1a2202af83637c73b78ed140ad8fae82a81ce17983f7469a44c01fcdfeebc855fcd9ca193d5c1172cd006d8ee6dcf1a60838f6e9a181dfb3f454027df0a212fbf55943b93f9f6eb6625aa0cff78166c921035e9ecfb6f000000ffffd9fe30409b020000",

@ -7,6 +7,6 @@ require (
github.com/gogo/protobuf v1.2.1
github.com/golang/protobuf v1.3.2
golang.org/x/net v0.0.0-20190628185345-da137c7871d7
google.golang.org/grpc v1.22.0
google.golang.org/grpc v1.28.1
)

@ -7,6 +7,6 @@ require (
github.com/gogo/protobuf v1.2.1
github.com/golang/protobuf v1.3.2
golang.org/x/net v0.0.0-20190628185345-da137c7871d7
google.golang.org/grpc v1.22.0
google.golang.org/grpc v1.28.1
)

@ -7,6 +7,6 @@ require (
github.com/gogo/protobuf v1.2.1
github.com/golang/protobuf v1.3.2
golang.org/x/net v0.0.0-20190628185345-da137c7871d7
google.golang.org/grpc v1.22.0
google.golang.org/grpc v1.28.1
)

@ -134,6 +134,10 @@ func latestKratos() (string, error) {
if _, err := os.Stat(ext); !os.IsNotExist(err) {
return ext, nil
}
ext = path.Join(gopath, "src/kratos/third_party")
if _, err := os.Stat(ext); !os.IsNotExist(err) {
return ext, nil
}
baseMod := path.Join(gopath, "pkg/mod/github.com/go-kratos")
files, err := ioutil.ReadDir(baseMod)
if err != nil {

@ -8,9 +8,9 @@ import (
var (
// Version is version
Version = "v0.4.2"
Version = "v0.5.0"
// BuildTime is BuildTime
BuildTime = "2020/3/29"
BuildTime = "2020/4/30"
)
// VersionOptions include version

Loading…
Cancel
Save