What\'s the best way to check if two paths are equal in Bash? For example, given the directory structure
~/ Desktop/ Downloads/ (symlink to ~/Downloads
Bash's test commands have a -ef operator for this purpose
-ef
if [[ ./ -ef ~ ]]; then ... if [[ ~/Desktop -ef /home/you/Desktop ]]; then ...
etc...
$ help test | grep -e -ef FILE1 -ef FILE2 True if file1 is a hard link to file2.