This is a tool to modify the file name or extension.
option | alias | description |
---|---|---|
--name | -n | file or directory name |
--extension | -e | file's extension name |
eg1: modify a file name.
rn -n ./test.txt abc
test.txt
will be renamed abc.txt
in the current directory.
eg2: modify the extension
rn -e ./test.txt js
test.txt
will be renamed test.js
in the current directory.
eg3: modify a directory name
rn -n ./test/ abc
./test/
will be renamed ./abc/
in the current directory.