This must have been answered somewhere, but Google as I might, I cannot find the answer.
According to the find manual, you can use -P (which is default anyway) to prevent it from following symlinks.
But, this applies only to flies. What I want is for find to not follow any folders that are symlinks.
For example, suppose the folder structure is as follows.
Code:
. ├── folderA │ ├── folderAA │ └── folderAB ├── folderB │ ├── folderBA │ └── folderBB └── linkToOutside -> /somewhere/else/outsideA/
I have tried the following options but to no avail:
Code:
find -P -xdev '!' -type l
How do I tell 'find' to skip all symlink folders?
Aucun commentaire:
Enregistrer un commentaire