and filePath starts with "~" then set filePath to "./" & filePath -- Cocoa API *always* expands leading "~" character, which it really shouldn't as tilde expansion is a *nix shell-ism, not a POSIX path-ism, so prefix with "./" to prevent that