yeisonqb
(Yeisonqb)
August 24, 2020, 5:07pm
1
Good morning, I would like to know how you can call functions that I have in a different document, inside the main.go
groups
-----controllers
-------usersControllers.go
main.go
file main.go
package main
import (
"./groups/controllers"
"github.com/gorilla/mux"
"log"
"net/http"
"time"
)
terminal debug
build command-line-arguments: cannot find module for path /C /Users/YeisonQ/Documents/Yeison/Backup_Yeison/Trabajos/Api_fullrest_scim_go/groups/controllers
thanks for your attention
1 Like
connerj70
(Conner Jensen)
August 24, 2020, 6:18pm
2
I believe if you are using go modules then you need to start the import path with the module name. For example, if the name of your module was module github.com/yeisonqb/cool_application then your import path would be github.com/yeisonqb/cool_application/groups/controllers
if you are not using modules then your import path will start at your $GOPATH/src directory. You will then need to traverse down to the root folder of your application.
I hope that helps.
system
(system)
Closed
November 22, 2020, 9:12pm
4
This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.