Golang os.Symlink() function examples

package os

Golang os.Symlink() function usage examples

Example 1:

 if err := os.Symlink(cwd, dir); err != nil {
 return err
 }

Example 2:

 err := os.Symlink(to, from)

Reference :

http://golang.org/pkg/os/#Symlink

Advertisement