Skip to main content

Rename files by editing their paths directly in Vi (or in any other editor)

Project description

Github PyPi Python


Renames files by editing their paths directly in Vi (or in any other editor).



Simply using pip

$ sudo apt install python3-pip 
$ pip3 install --user virenamer 

Clone the repository

$ git clone
$ cd virenamer
$ ./ install --user --prefix=


To rename files, run virenamer with some files as arguments.

$ virenamer folderA/* 

It will open your favorite editor if the EDITOR env variable is set) or Vi by default. You can also select a custom editor using the -e, --editor arguments, for example --editor nano.

You can edit the paths as you want but the line count has to be the same. If you add or remove a line, virenamer will end with an error.

After the content saved and the editor closed, file will be processed:

  • if -n, --dryrun is given, nothing will be moved, only messages will be displayed
  • if the new file already exists, the file won't be overwritten, unless you specify -f, --force
  • if the new file is empty (ie blank line), the file will be deleted is you specified -d, --delete
  • if the new file is in a folder that does not exists, it will be created


$ virenamer --help
usage: virenamer [-h] [-e EDITOR] [-f] [-d] [-n] files [files ...]

File renamer

positional arguments:
  files                 files to rename

optional arguments:
  -h, --help            show this help message and exit
  --version             show program's version number and exit
  -e EDITOR, --editor EDITOR
                        Editor used to edit file list
  -f, --force           Overwrite if target file already exists
  -d, --delete          Delete file if line is empty
  -n, --dryrun          Dryrun mode, don't rename any file

Project details

Release history Release notifications

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for virenamer, version 0.1.0
Filename, size File type Python version Upload date Hashes
Filename, size virenamer-0.1.0-py3-none-any.whl (9.5 kB) File type Wheel Python version py3 Upload date Hashes View hashes
Filename, size virenamer-0.1.0.tar.gz (720.5 kB) File type Source Python version None Upload date Hashes View hashes

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page