24 Commits

Author SHA1 Message Date
Adam Reis
4f4991cfe5 Add sync unit test for ignored files 2017-08-25 07:38:33 +12:00
Adam Reis
dae627324e Update readme, fix line length 2017-08-25 07:34:56 +12:00
Kodie Grantham
508ad44b09 Added ignore option (#27)
Ability to ignore files, since Glob doesn't take negated globs anymore since version 4 or 5.
2017-08-25 07:28:43 +12:00
Adam Reis
eee947e744 Add test to prove substring replacement is working 2017-03-12 12:44:20 +13:00
Adam Reis
49b41fe41e Avoid destructuring to support Node 4 & 5 2017-02-15 07:27:43 +13:00
Adam Reis
db4b760d9e CLI functionality 2017-02-13 18:29:46 +13:00
Adam Reis
ec82c43774 Default config, specify encoding, validate config 2017-01-25 13:02:21 +13:00
Adam Reis
cee2844886 Allow multiple replacements at once 2017-01-19 10:10:30 +13:00
Adam Buczynski
83d53e732b Promise API, initial cut 2016-08-10 21:13:29 +12:00
Adam Buczynski
057463396c Arrow functions, drop lower node versions from tests, move helper function out of scope 2016-08-10 20:07:15 +12:00
RyanZim
e0492367b5 Add glob functionality & allowEmptyPaths option
files option can be passed as a glob

When allowEmptyPaths is true, replace-in-file will not throw an error
due to invalid file paths in `files`. Default is false.

Fixes #7
2016-08-09 09:29:00 -04:00
Adam Buczynski
f48a5ce354 Update dependencies, use ESLint, fix line length issues 2016-08-06 16:31:34 +12:00
Fyodor
ef88fda659 remove useless recursion 2016-06-04 03:22:16 +03:00
Adam Buczynski
6759960e10 Add sync replacement 2016-06-03 23:33:19 +12:00
Adam Buczynski
d3aaedf10f Update packages 2016-06-02 16:28:34 +12:00
Adam Buczynski
f90249e9ea Test change to trigger travis 2016-02-16 15:25:00 +13:00
Max Rittmüller
d4f220bee2 Fixed behaviour for passing back array with changed files 2015-11-19 16:44:07 +01:00
Adam Buczynski
f3b9580c75 Replace with new contents, unit tests 2015-07-02 14:50:34 +12:00
Adam Buczynski
d4990715f5 Add return for unchanged contents cb 2015-07-02 13:41:39 +12:00
Adam Buczynski
b1aa42180a Fix #2: return array of changed files in callback 2015-07-02 13:34:58 +12:00
Dave Jeffery
093a6a31ae Don't write a new file if contents are the same as existing file 2015-07-02 02:25:01 +01:00
Adam Buczynski
9c639b70ea Code styling 2015-06-27 11:42:09 +12:00
Adam Buczynski
f5532852b6 Update interface, split in two functions 2015-06-26 06:46:51 +12:00
Adam Buczynski
ee1d1db18c Add gitignore, move to lib 2015-06-25 20:42:53 +12:00