DEV Community

Discussion on: Microservices with go-kit. Part 1

Collapse
 
nikhilnair profile image
Nikhil Nair

Hi Alex. I am newbie to GoKit. When i run "go get github.com/go-kit/kit", it gets the packages but returns an error "no Go files in /Users/username/go/src/github.com/go-kit/kit" and even after i install gokit CLI. i get the kit command not found issue. Can you help me out here a bit

Collapse
 
plutov profile image
Alex Pliutau
  1. go-kit is a collection of packages, so you should get specific one, like: go get github.com/go-kit/kit/sd, or all packages: go get github.com/go-kit/kit/....
  2. When you install CLI by go get github.com/kujtimiihoxha/kit it installs into $GOPATH/bin, so you should add it to your system $PATH variable.
Collapse
 
nikhilnair profile image
Nikhil Nair • Edited

I have the $GOPATH/bin added to my $PATH variable but still facing the Kit command not found issue. I have pasted below the output of my echo $PATH.

/usr/local/opt/node@8/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/go/bin:/Users/nikhil/Library/Android/sdk/tools:/Users/nikhil/Library/Android/sdk/tools/bin:/Users/nikhil/Library/Android/sdk/platform-tools:/usr/local/opt/go/libexec/bin

Thread Thread
 
plutov profile image
Alex Pliutau

Can you please share how do you install Go Kit CLI?

Thread Thread
 
nikhilnair profile image
Nikhil Nair

Exactly like you mentioned
Go Kit CLI: go get github.com/kujtimiihoxha/kit

Then inside my project directory
And i used glide to install GoKit: glide get github.com/go-kit/kit

My $GOPATH is set to /usr/local/go/bin
My Project is on /Users/username/go/src/project

Thread Thread
 
plutov profile image
Alex Pliutau
  1. You should set GOPATH=/Users/username/go
  2. After go get github.com/kujtimiihoxha/kit you can find kit in $GOPATH/bin/kit
Thread Thread
 
nikhilnair profile image
Nikhil Nair

Hey
I got it running. Thanks a ton Alex :)
Keep you the great work. Looking forward to more Go tutorials.

Thread Thread
 
trungvudang profile image
Trung Vu • Edited

I also got trouble when try to install kit, it is not maintained anymore, but I found this
github.com/GrantZheng/kit