Only emit *-symlink with -v set
This commit is contained in:
@@ -322,12 +322,16 @@ func ReadDirEntries(dirPath string, opts *Options) ([]FileEntry, error) {
|
||||
entry.Size = -1
|
||||
entry.SizePretty = "—"
|
||||
entry.IconType = "folder-symlink"
|
||||
if opts.Verbose {
|
||||
fmt.Printf("dir-symlink %s\n", fullPath)
|
||||
}
|
||||
} else if !file.IsDir() && entry.IsSymlink {
|
||||
entry.Size = info.Size()
|
||||
entry.SizePretty = PrettySize(entry.Size)
|
||||
entry.IconType = "symlink"
|
||||
if opts.Verbose {
|
||||
fmt.Printf("file-symlink %s\n", fullPath)
|
||||
}
|
||||
} else {
|
||||
entry.Size = info.Size()
|
||||
entry.SizePretty = PrettySize(entry.Size)
|
||||
|
||||
Reference in New Issue
Block a user