I filed an issue here first https://github.com/spf13/cobra/issues/432 and it could be the problem is on gotype itself.
I tried to use cobra package then it created to files the main.go and cmd/root.go
but gotype was not able to find the imported files and spit an error, until you do a go install.
Thanks.