Skip to content

Copy files from multiple sources into a single folder sorted by their modification date while preventing duplicate content.

License

Notifications You must be signed in to change notification settings

xprueg/folderize

Repository files navigation

folderize

The folderize utility copies files from multiple sources into a single destination folder.  In the destination folder the files are sorted in a folder tree created by their last modification time (mtime).

Termial Preview

Synopsis

folderize [-c] --input PATH ... [--output PATH] [--locale LOCALE] [--exclude REGEX]

Options

--input, -i PATH ...
The input folder(s).
--output, -o PATH
The destination folder.  The current folder (./) is used as default.
--dirstruct, -d STRING
Structure that should be constructed in the output directory.  Every slash will create a new subdirectory.  The default is %Y/%B/%e which will result in 2020/February/1.

DayMonthYear
eDay 1mMonth, 2-digit 02YYear 2020
dDay, 2-digit 01bMonth, short FebyYear, 2-digit 20
BMonth, long February
1 February 2020
--locale, -l LOCALE
The locale to be used for folder creation in the destination folder.  Locales other than english need at least node v.13 or node build with full-icu.  The default is en−US.
--exclude, -e REGEX
The files and/or folders names which shall not be copied.  The regex must not be enclosed by slashes.
--cache, -c
Enables the creation/use of the cache file `folderize.cache'.

Tests

There is currently an integration test that should be run with the same options, excluding input and output, like you would intend to run folderize itself.

npx jasmine -- [-c] [--locale LOCALE] [--exclude REGEX]

About

Copy files from multiple sources into a single folder sorted by their modification date while preventing duplicate content.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published