August 2019
Beginner to intermediate
798 pages
17h 2m
English
In this subsection, we are going to create a new version of myModule using a different tag. However, this time there is no need to execute go mod init, as this was done before. You will just need to execute the following commands:
$ vi myModule.go $ git commit -a -m "v1.1.0" [master ddd0742] v1.1.0 1 file changed, 1 insertion(+), 1 deletion(-) $ git push $ git tag v1.1.0 $ git push -q origin v1.1.0
The contents of this version of myModule.go will be as follows:
package myModule
import (
"fmt"
)
func Version() {
fmt.Println("Version 1.1.0")
}
Read now
Unlock full access