adamreisnz / replace-in-file

A simple utility to quickly replace contents in one or more files
580 stars 65 forks source link

Replace in hidden files in MacOS not working? #103

Closed Ronald-Diemicke closed 4 years ago

Ronald-Diemicke commented 4 years ago

I'm trying to do a replace in hidden files (starting with a '.') but it's not working. Any ideas?

adamreisnz commented 4 years ago

Do you mean they aren't being found? Probably need to work on your regex for file matching.

adamreisnz commented 4 years ago

Closing this one off now, but let me know if you still run into issues.

butaca commented 2 months ago

I'm experiencing the same issue on macOS

butaca commented 2 months ago

The problem is that by default glob is ignoring paths starting with dots. This can be changed with this configuration: https://www.npmjs.com/package/replace-in-file#specify-glob-configuration

const options = {
  glob: {
    dot: true,
  },
}