If you don’t want to push your dependencies and tag them all the time
and just want to use whatever the local version of code you have to speed up local
development and also not break anyone’s code by merging unstable stuff to main
,
then you can use replace
in your go.mod
.
The replace
line goes above your require statements, as follows:
module github.com/zerotohero-dev/sample-go-app
replace github.com/zerotohero-dev/potato => /Users/volkan/Desktop/WORKSPACE/potato
require (
github.com/zerotohero-dev/potato v1.0.0
)
Just don’t forget to remove the replace
before pushing your final pull request.