Skip to content

Latest commit

 

History

History
37 lines (32 loc) · 1.29 KB

README.md

File metadata and controls

37 lines (32 loc) · 1.29 KB

Rename-files-from-CSV

Python command line script renaming multiple files according to a pattern in a CSV file.

Use case 1

You download files in a specific order, but they change their names during download. You have a list of filenames in the original order and a list of new filenames. You can order a list of new filenames, add numbering or change their names in your tab editor, create a CSV, and then run this script to rename all files in a certain directory.

Installation

1. Open console

  • Linux: CTRL+ALT+T
  • MacOS: Open Finder -> type in terminal -> run it
  • Windows: WIN+R -> type cmd -> ENTER

2. Install Python and libraries

The program is tuned in Python 3.10.12.
  • Linux:
    • Debian (Ubuntu):
      • sudo apt update
      • sudo apt install python3
      • sudo apt install python3-pip
      • pip install pandas
    • RedHat (CentOS 8+, Fedora):
      • sudo dnf check-update
      • sudo dnf install python3
      • sudo dnf install python3-pip
      • pip install pandas
  • MacOS:
    • python3 --version