All Projects → innocenzi → rename

innocenzi / rename

Licence: MIT license
Batch-rename files from your preferred editor

Programming Languages

typescript
32286 projects
javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to rename

rename.nvim
Rename plugin for neovim
Stars: ✭ 16 (-67.35%)
Mutual labels:  rename
ue4-kopiarka
This is a little util that lets me copy and rename projects from one directory to another
Stars: ✭ 24 (-51.02%)
Mutual labels:  rename
VIDEOconvertor
A stable and Fast telegram video convertor bot which can encode into different libs and resolution, compress videos, convert video into audio and other video formats, rename with thumbnail support, generate screenshot and trim videos.
Stars: ✭ 180 (+267.35%)
Mutual labels:  rename
TorrentLeechBot
A powerful telegram mirror bot..
Stars: ✭ 94 (+91.84%)
Mutual labels:  rename
FileRenamerDiff
A File Renamer App featuring a difference display before and after the change.
Stars: ✭ 32 (-34.69%)
Mutual labels:  rename
React Native Rename
Rename react-native app with just one command
Stars: ✭ 2,033 (+4048.98%)
Mutual labels:  rename
Subconverter
Utility to convert between various subscription format
Stars: ✭ 4,912 (+9924.49%)
Mutual labels:  rename
Mesh-RenameBot
One of the best Rename bot for telegram. Heroku deployable and many features.
Stars: ✭ 72 (+46.94%)
Mutual labels:  rename
Episode-ReName
电视剧/番剧自动化重命名工具
Stars: ✭ 89 (+81.63%)
Mutual labels:  rename
UniBorg
Pluggable Telegram bot and userbot based on Telethon
Stars: ✭ 196 (+300%)
Mutual labels:  rename
rename-keys
Modify/rename the keys of the own enumerable properties of an object.
Stars: ✭ 28 (-42.86%)
Mutual labels:  rename
rename-tool
一个基于 .NET Core 2.x 实现的项目重命名工具
Stars: ✭ 16 (-67.35%)
Mutual labels:  rename
filename-simplifier
☄ Simplify your library
Stars: ✭ 14 (-71.43%)
Mutual labels:  rename

Renamer

Status   npm

A command line utility to batch-rename files via your editor.

npm i -g @innocenzi/rename

 

Usage

In a directory, use rn to open your configured editor. Each line corresponds to a file:

  • If you change a line, the corresponding file will be renamed accordingly.
  • If you erase the line while keeping the line jump, the file will be deleted.

Note the following scenarios:

  • If you completely delete a line, all operations will be canceled.
  • If you rename multiple files with the exact same name, the last one will take over and the previous ones will be deleted.
  • If you are deeply renaming paths and have renamed a shared base directory, you need to update other related paths accordingly.

 

Options

Argument Description
--dry Prints the output to the console without actually applying the changes
--silent Prevents from printing to the console
--dirs Only match directories
--files Only match files
--base <dir> Defines the base directory in which the rename will be performed
--depth <depth> Defines the maximum depth in case a globstar is used (**)

 

Configuration

Your RENAME_EDITOR or EDITOR environment variable will be used to determine your editor of choice. If none of these are defined, Visual Studio Code will be used instead. If Code is not installed either, or if the configured editor can not be opened, the program will fail.

The following table is a reference from the Git documentation that can be used to set up your editor.

Editor Environment variable value
Atom atom --wait
BBEdit (Mac, with command line tools) bbedit -w
Emacs emacs
Gedit (Linux) gedit --wait --new-window
Gvim (Windows 64-bit) 'C:\Program Files\Vim\vim72\gvim.exe' --nofork '%*'
Kate (Linux) kate
nano nano -w
Notepad (Windows 64-bit) notepad
Notepad++ (Windows 64-bit) 'C:\Program Files\Notepad\notepad.exe' -multiInst -notabbar -nosession -noPlugin
Scratch (Linux) scratch-text-editor
Sublime Text (macOS) /Applications/Sublime\ Text.app/Contents/SharedSupport/bin/subl --new-window --wait
Sublime Text (Windows 64-bit) 'C:\Program Files\Sublime Text 3\sublime_text.exe' -w
TextEdit (macOS) open --wait-apps --new -e
Textmate mate -w
Textpad (Windows 64-bit) 'C:\Program Files\TextPad 5\TextPad.exe' -m
UltraEdit (Windows 64-bit) Uedit32
Vim vim
Visual Studio Code code --wait
VSCodium (Free/Libre Open Source Software Binaries of VSCode) codium --wait
WordPad "C:\Program Files\Windows NT\Accessories\wordpad.exe"
Xi xi --wait

 



·

Demonstration of the CLI

Demonstration of the CLI

·

Built with ❤︎ by Enzo Innocenzi

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].