I'm developing a go module, let's call it github.com/spyna/mymodule
.
This module is a library and another go project uses it, for example: github.com/spyna/goapp
uses github.com/spyna/mymodule
.
During the development phase, I don't want to push changes in github.com/spyna/mymodule
because they're still under development, but in order to test the changes, I want to use the local version of github.com/spyna/mymodule
as a dependency of github.com/spyna/goapp
.
For example, this file in github.com/spyna/goapp
requires github.com/spyna/mymodule
.
//main.go
package main
import (
"github.com/spyna/mymodule"
)
func main() {
mymodule.doSomething()
}
If I run this code, the dependency is resolved remotely, but I want to use the local one, to test my changes.
Is this possible in go?
thank you.