when I try to check the type of an executable file, I always get this:
symbolic link to <another_file>
Then I have to dig further and run file <another_file>. Sometimes this could take 5 or 6 rounds. I'm wondering whether there is a way to let file to recursively go to the original file and tell me the file type.
Specifying -L to file should make it follow symlinks. From the man page:
-L, --dereference
option causes symlinks to be followed, as the like-named option
in ls(1) (on systems that support symbolic links). This is the
default if the environment variable POSIXLY_CORRECT is defined.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With