func resolveSymlinkedRoot(rootPath string) (string, error) {
	info, err := os.Lstat(rootPath)
	if err == nil && info.Mode()&os.ModeSymlink != 0 {
		rootPath, err = filepath.EvalSymlinks(rootPath)
		if err != nil {
			return "", fmt.Errorf("cannot read path symlink at %q: %v", rootPath, err)
		}
	}
	return rootPath, nil
}
// resolveSymlinkedRoot returns the target destination of a
// charm root directory if the root directory is a symlink.
resolveSymlinkedRoot returns the target destination of a
charm root directory if the root directory is a symlink.
// resolveSymlinkedRoot returns the target destination of a // charm root directory if the root directory is a symlink .
func resolveSymlinkedRoot(rootPath string) (string, error) {
	info, err := os.Lstat(rootPath)
	if err == nil && info.Mode()&os.ModeSymlink != 0 {
		rootPath, err = filepath.EvalSymlinks(rootPath)
		if err != nil {
			return "", fmt.Errorf("cannot read path symlink at %q: %v", rootPath, err)
		}
	}
	return rootPath, nil
}
func resolveSymlinkedRoot ( rootPath string ) ( string , error ) { info , err := os . Lstat ( rootPath ) if err == nil && info . Mode ( ) & os . ModeSymlink != 0 { rootPath , err = filepath . EvalSymlinks ( rootPath ) if err != nil { return " " , fmt . Errorf ( " " , rootPath , err ) } } return rootPath , nil }
resolveSymlinkedRoot returns the target destination of a
charm root directory if the root directory is a symlink.
resolveSymlinkedRoot returns the target destination of a charm root directory if the root directory is a symlink .