Fix tidyPath to work as specified in Javadoc

See @Nakomis and @ahgittin comments on https://github.com/brooklyncentral/brooklyn/pull/1161#discussion-diff-9047224R375, plus the following:

- Method strips trailing slashes from paths beginning with `~` only
- Method only works on current JVM `File#separator` definition, not both types
- Does not collapse multiple separators
- Does not handle embedded `.` org `..` usefully

Changed to canonicalise using Guava `Files#simplifyPath(String)` which does most of what we want, and then perform the `~` substitution afterwards.