/ Published in: Bash
This is useful if you have some optional functionality being done which is quite slow on nfs. For example, I have a script that adds scm (svn/git/etc) info to my prompt, but I wouldn't want that when I'm in a repository on an nfs mount.
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
if [ "$(stat -f -c "%T" $path)" = "nfs" ]; then # $path is in an nfs mount fi