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

Glob error with windows UNC Paths #32

Closed
Ebsy opened this issue Sep 13, 2017 · 4 comments
Closed

Glob error with windows UNC Paths #32

Ebsy opened this issue Sep 13, 2017 · 4 comments
Assignees

Comments

@Ebsy
Copy link

Ebsy commented Sep 13, 2017

Hi, trying to use a Windows UNC path in 'files' e.g.
{'files': '//SERVER/share/directory/file.txt'}

replace-in-file returns an error that no file exists with this glob pattern.
using fs.access for this path is no problem. I believe it is an issue with node-glob.

Would it be possible for replace-in-file to contain an option to not use glob if the file doesn't contain regex wildcards?

@adamreisnz
Copy link
Owner

Sure, I'll look into that later today!

@adamreisnz
Copy link
Owner

adamreisnz commented Sep 14, 2017

I'll implement this in 3.0.0 under a flag. That seems the safest way to disable globs, instead of testing the strings.

@adamreisnz adamreisnz self-assigned this Sep 14, 2017
@adamreisnz
Copy link
Owner

@Ebsy could you give 3.0.0-beta.1 a try using the disableGlobs: true parameter?

See https://github.com/adamreisnz/replace-in-file/releases/tag/v3.0.0-beta.1

@Ebsy
Copy link
Author

Ebsy commented Sep 14, 2017

Perfect! working as expected.
Thanks Adam. I'll go ahead and close it.

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

No branches or pull requests

2 participants