Skip to content
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

Fully implement GlobMatches starting with / #2

Open
kmsquire opened this issue Aug 30, 2014 · 3 comments
Open

Fully implement GlobMatches starting with / #2

kmsquire opened this issue Aug 30, 2014 · 3 comments

Comments

@kmsquire
Copy link

#1 implements this for strings only, by stripping off the leading / before creating the GlobMatch object. Ideally, support would be in the GlobMatch object directly.

@kmsquire kmsquire changed the title Fully implement GlobMatch starting with / Fully implement GlobMatches starting with / Aug 30, 2014
@Alexander-Barth
Copy link

I think that this would be great if Glob.jl would support absolute path.
Or is there any reason for not supporting this?

@vtjnash
Copy link
Owner

vtjnash commented Feb 4, 2019

Not really—I just didn't have an idea at the time for representing them (and, for a variety of reasons, didn't consider it as an expected use case initially). It's also a case where Windows is more than a bit wonky, making this less innocent that it might at first appear. (long story short, currently a "glob" is explicitly not a file path, but is more nearly a URI wildcard pattern fragment which returns a set of file paths when acted upon.)

@diegozea
Copy link

Hi!

First, thanks for this useful package :)

I think this is related to this issue. I think that the error message Glob pattern cannot be empty or start with a / character for glob could suggest trying using "/" as the second argument instead (and deleting it from the first):

glob("/home/diego")
glob("home/diego", "/")

image

A docstring for the function could be useful in the meantime.

Best,

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants