-
-
Notifications
You must be signed in to change notification settings - Fork 476
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 support to pass in fs interface #280
Comments
That would be exactly what I was looking for! Currently It would be great if implementers of custom vinyl adapters, such as purely in-memory ones, would not have to do their own globbing (or disallow glob patterns completely) -- but instead just provide the needed subset of At this time, our call to glob can't be transplanted to @isaacs I'd be willing to spend some time on a PR, unless of course you don't like the idea to begin with? |
EDIT Scratch that last bit, I just found #71. |
@Auxolust I've submitted a PR that would address my use case... And yours, I believe? Sorry about the repeated references above, I cleaned up the accompanying test a little bit and force-pushed to override the previous commit. But since it already had the issue number in there, this happened. |
@erikkemperman there are reasons to use |
I've got a small patch too so I can use glob with dat and hyperdrive and it seems to work for me so far. Basically, I can now use glob like this:
|
I was looking at this issue exactly because of how to use it with hyperdrive and plan to use the small patch by @millette . Total 👍 by me for having this. Would it be okay to publish a PR based on this prior work? |
To anyone who also wants to use a custom Caveat: it only works with synchronous IO. |
Wow, this has been here for a while. |
If this is added to https://github.com/isaacs/path-scurry, then glob will pass the requisite options along. Glob doesn't actually touch the file system directly any more, everything goes through PathScurry. |
I enjoy node-glob, but I need its use on a virtual file system which is separate from the node fs, but with the same interface. If we modify fs.realpath and add in a fs parameter in the options which falls back to the default native fs t should be quite easy
The text was updated successfully, but these errors were encountered: