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

Help installing this on ubuntu 22.04 #119

Open
eliander30 opened this issue Apr 10, 2024 · 3 comments
Open

Help installing this on ubuntu 22.04 #119

eliander30 opened this issue Apr 10, 2024 · 3 comments
Labels
documentation Improvements or additions to documentation

Comments

@eliander30
Copy link

Hi I'm trying install it on ubuntu 22.04 but when i execute the command to install it i see the following error

go get -u github.com/AfterShip/email-verifier

go: go.mod file not found in current directory or any parent directory.
	'go get' is no longer supported outside a module.
	To build and install a command, use 'go install' with a version,
	like 'go install example.com/cmd@latest'
	For more information, see https://golang.org/doc/go-get-install-deprecation
	or run 'go help get' or 'go help install'.

NOTE: i also used the gollowing command but is not working neither

go install github.com/AfterShip/email-verifier@latest
package github.com/AfterShip/email-verifier is not a main package

@zakirkun
Copy link

can you provide go version on your device?

@tunecrew
Copy link

Same issue on macOS - go 1.22.6.

I understand that go get has been deprecated in favour of go install but it still doesn't work.

go install github.com/AfterShip/email-verifier@latest

package github.com/AfterShip/email-verifier is not a main package

@lryong
Copy link
Contributor

lryong commented Sep 10, 2024

Hi @tunecrew @eliander30 .
After the go version is upgraded, it no longer supports the go get installation, but the email-verifier is only a library, so it does not support the go install.

For a library package in Go, you can install it and manage dependencies using Go Modules. Here are the steps:

  1. Initialize Go Modules:
    Open your terminal in the project directory and run the following command to initialize Go Modules:
    go mod init example.com/myproject

  2. Install the email-verifier Package:
    Use the following command to download and install email-verifier package along with its dependencies:
    import "github.com/AfterShip/email-verifier"

  3. Install the Package:
    Use the following command to download and install the email-verifier package along with its dependencies:
    go get github.com/AfterShip/email-verifier@latest

  4. Write Your Code:
    Utilize the library in your code as needed, referring to the library's documentation for proper usage instructions.

  5. Build and Run:
    Finally, build or run your program using go build or go run.

@lryong lryong added the documentation Improvements or additions to documentation label Sep 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

No branches or pull requests

4 participants