All changes are non-functional - there are no changes to the API or app behaviour.
Published by 75lb about 3 years ago
All changes are non-functional - there are no changes to the API or app behaviour.
require
to load renamer..mjs
to .js
require
should not upgrade to v4 - stick with versions 1, 2 or 3 until able to load ECMAScript modules.Published by 75lb over 3 years ago
Renamer
class is no longer an EventEmitter
. Rather than listen for replace-result
events you now async iterate over renamer.results
.
renamer.rename
API method is now asynchronous, returning a Promise
. Previously it was synchronous.--plugin
option has been renamed to --chain
--view
plugins are now accepted, making the previous name --plugin
ambiguous.--silent
mode--view one-line
which outputs just a summary line, nothing more. #492 of 3 files renamed
) to the built-in viewsrenamer.results
async iterator to the core API.Published by 75lb over 4 years ago
Published by 75lb almost 6 years ago
--index-root
.By default, the {{index}}
value begins at 1. You can override this by specifying an --index-root
value.
$ renamer -d --replace "Image{{index}}.jpg" --index-root 10 *
Published by 75lb over 6 years ago
Renamer has been completely rewritten but retains its core behaviour and "feel".
--regex
and --insensitive
options removed, you now specify a regular expression literal. For example, --find '/something/ig'
.{{index}}
token is now incremented per file-renamed-successfully, rather than per file.--path-element
should be renamed.--force
mode added, fixes #17.--view long
and --view diff
added.stdin
, facilitating use of tools like find
to build the input file list. Users now have control over the input file order and therefore {{index}}
value. Fixes #31.Quite a lot has changed so it's worth reading the new documentation. Nevertheless, the core user-experience remains largely the same: you set a --find
, --replace
, some files, check the --dry-run
then rename.