-
Notifications
You must be signed in to change notification settings - Fork 18
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
Should readdir
return a path?
#71
Comments
This seems related to #20. I think the current behaviour of
To do what you're proposing you probably want to write.
Better support for directory walking and globbing would probably help with these kinds of operations though. |
I agree it alighs with Base julia, but can we do better? One option we could have that I alluded to is
returned by
This could be pretty cool, I think. |
Hmmm, I did want to do something similar for a restricted/sandboxed path type which would essentially work like a chroot:
It would have special rules to prevent you from operating outside of the parent path. Would it make sense for |
I was thinking that, but didn't want to complicate the example. |
This kind of reminds me of Haskell's path library http://hackage.haskell.org/package/path (not that I've used it). which divides path types into |
|
For now, I think I'm gonna support
Since |
It is kind of annoying that I can't do
readdir.(readdir(somepath))
to exact the 2 level hierachy.One solution to this would be for
readdir
to always return a path type.Wether this is a fully qualified path of the same type as its input,
or wether it is some kind of
PathPart{<:AbstractPath} <:AbstractPath
type thatboth
Strings
into just the last component,but
readdir
s as a fully path using a remembered parent,or some other solution
I am not sure.
The text was updated successfully, but these errors were encountered: