Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The execute path of import is wrong after generated by cobra-cli command #74

Open
cuizhaoyue opened this issue Mar 4, 2023 · 1 comment

Comments

@cuizhaoyue
Copy link

  1. Create a demo
mkdir -p cobra
cd cobra
cobra-cli init --viper demo
  1. Check the generated main.go file
$ cat demo/main.go 
/*
Copyright © 2023 NAME HERE <EMAIL ADDRESS>
*/
package main

import "github.con/cuizhaoyue/go-demo/cobra/cmd"

func main() {
        cmd.Execute()
}
  1. the import in main.go is wrong
    The correct path should be
github.con/cuizhaoyue/go-demo/cobra/demo/cmd

rather than

github.con/cuizhaoyue/go-demo/cobra/cmd
  1. version info
    The cobra-cli version is the latest version as of 2023-03-04
@github-actions
Copy link

github-actions bot commented May 4, 2023

This issue is being marked as stale due to a long period of inactivity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant