- Fix #104: Add
--allow-empty
option to successfully exit even when no matches are found. Patch by @roqvist
- Breaking: rename '--preserve_case' to '--preserve-case'
- Breaking: rename 'Query::substring' to 'Query::simple'
- Breaking: rename '--subvert' to '--preserve_case' (the fact that this option is in "snake case" is a bug!)
Hopefully those names are clearer for the user.
- Switch to
cargo-dist
to make releases
- Fix #102: don't write files when not required
- Add missing new line in output when
--dry-run
is used - Update dependencies
- Bump to
clap
4 - Fix using
--type-list
on the command-line (#100)
- Breaking: replace
Replacement::print_self()
withConsole::print_replacement(prefix, replacement)
.
- Add
--quiet
option. Suggested by @kypm - Breaking:
DirectoryPatcher::new()
,FilePatcher::new()
andReplacement::print_self()
now take an additional&Console
argument. - Add a
Console
struct and aVerbosity
enum.
- Add
-V, --version
option. Patch by @homeworkprod
- Fix bug where the printed number of matching files was generally too big.
- Improve documentation for
FilePatcher
- Update dependencies
- Bump to Rust 2021 edition
- Fix regression in ruplacer diff output introduced in 0.6.1.
- Handle trailing newlines consistently. Previously,
ruplacer
would always write file with a trailing new line. Patch by @LawnGnome.
- Fix panic when using incorrect globs for file and type selections.
- Also replace
Ada_Case
(also known asMixed_Case
) variants when using--subvert
The output has changed, going from:
# Using version < 0.6
Patching foo/bar.js
--- old is old
+++ new is new
to:
# Using version >= 0.6
foo/bar.js:3 - old is old
foo/bar.js:3 + new is new
- ruplacer now displays the path and line number of each line that changed
- the coloring of patches is more precise. See #15 for details.
- ruplacer reports the total number of replacements, rather than the number of lines that changed
- Drop dependency on the
difference
crate - Improve public API
- Default branch is now called
main
-
Add support for glob pattern for the
-t, type
and-T, --type-not
options. Patch by @ndtoan96 -
Implement
--hidden
and--ignored
flags, to force patching of hidden and ignored files, respectively. -
If the last argument is
-
, read from stdin and write to stdout.
- Switch to 2018 edition
- Switch to GitHub Actions for CI
- Switch to
anyhow
for error handling - Move out of TankerHQ GitHub organization
- Bump smallvec
- Fix metadata in Cargo.toml
- Fix release scripts
- Add
-w, --word-regex
to match regex only inside words. Note thatruplacer -w old new
is exactly the same asruplacer '\bold\b' new
.
- Implement #18: Add
-t, --type
,-T, --type-not
and--type-list
options. Suggested by @Dowwie.
- Fix deployment from travis
- Improve README and
--help
message.
Deploy Windows pre-compiled binaries as assets.
- Rename
--fixed-strings
option to--no-regex
-
Before exiting, print a helpful message containing stats about replacement and hint about using
--go
to actually write the changes to disk. -
Tweak ruplacer output
-
Print error and exit with error code 2 if no replacement was made
- Implement --subvert option to handle snake_case, CamelCase and so on. Fix #8.
-
In case binary or non-UTF-8 files are found in the path, just skip them instead of aborting the whole process
-
Change algorithm used to display diffs. (Fix #4)
First public release