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

Is it possible to find in file using full path? #7

Open
jmona789 opened this issue Sep 28, 2017 · 1 comment
Open

Is it possible to find in file using full path? #7

jmona789 opened this issue Sep 28, 2017 · 1 comment

Comments

@jmona789
Copy link

jmona789 commented Sep 28, 2017

I'm trying to write a script where you pass a full path to a file and it will search it but when i run the search I get

{ Error: ENOENT: no such file or directory, lstat '/Users/username/Development/internal/test.html '
  errno: -2,
  code: 'ENOENT',
  syscall: 'lstat',
  path: '/Users/username/Development/internal/test.html ' }

Can I find a file using the full path or does it need to be in the same directory as the script?

@kaesetoast
Copy link
Owner

Hi @jmona789,

sorry for the long response times, I don't find that much time these days to keep an eye on GitHub. In theory, what you are trying to do should be possible. The filename ist directly passed to fs.readFile, which should accept a full path as well. I'll try to reproduce your issue as soon as I find the time, maybe there is a glitch in the logic :)

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

2 participants