Follow the instructions in the error messages: see `go help modules`.

On Monday, October 10, 2022 at 1:35:38 AM UTC-4 princ...@gmail.com wrote:

> I am trying to use this git api(*https://github.com/go-git/go-git 
> <https://github.com/go-git/go-git>*), but before that I tried to run the 
> provided example (i.e. cloning the repo by golang). So I run the program 
> *https://github.com/go-git/go-git/blob/master/_examples/clone/main.go 
> <https://github.com/go-git/go-git/blob/master/_examples/clone/main.go>*
>
> So when I run this program I used to get this error:
> sample.go:7:2: no required module provides package 
> github.com/go-git/go-git/v5: go.mod file not found in current directory 
> or any parent directory; see 'go help modules'
>
> sample.go:8:2: no required module provides package 
> github.com/go-git/go-git/v5/_examples: go.mod file not found in current 
> directory or any parent directory; see 'go help modules'
>
> *Please help me, how I can execute this?*
>
> I am using the following:
> Go version: go version go1.18.1 linux/amd64
> Platform:  Ubuntu 22.04.1 LTS

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/golang-nuts/390f1b49-22d4-44ec-ab6a-79cb6aec83efn%40googlegroups.com.

Reply via email to