-
Notifications
You must be signed in to change notification settings - Fork 17
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add isAbsolute field to path and treat relative/absolute/~ paths correctly in adaptors #519
Comments
This is fixed by the pull request #524 |
The adaptors don't treat non-absolute paths themselves, they just pass them on their respective clients. For example passing in a '.' to the file adaptor will return a listing of '/', instead of the expected listing of fs.getEntryPath(). In xenon-cli I now have to use: public static Path getAbsolutePath(Path pathRelativeOrAbsolute, FileSystem fs) {
if (pathRelativeOrAbsolute.isAbsolute()) {
return pathRelativeOrAbsolute;
} else {
return fs.getEntryPath().resolve(pathRelativeOrAbsolute);
}
} I expected that adaptors would do this relative 2 absolute conversion for me. @jmaassen Should Xenon adaptors or the users of Xenon do this? |
Fixed in 0b622b1 Added working directory and support for relative paths (resolved against this working directory) to all adaptors. |
No description provided.
The text was updated successfully, but these errors were encountered: