Python package to automatically organize files by type
Project description
Bulk File Renamer
A simple and efficient Python tool to rename multiple files in a folder automatically using a custom prefix and numbering.
Features
- Rename files in bulk
- Automatic numbering
- Custom prefix support
- Keeps original file extensions
- Skips duplicate file names
- Ignores hidden files
- Handles edge cases (invalid folder, empty folder)
Installation
Clone the repository:
https://github.com/anuskabhandari/Bulk_file_renamer.git
cd file_renamer
Or install from PyPI:
pip install file-renamer
Usage
Run the program:
python file_renamer.py
Enter inputs:
Enter folder path: test_files
Enter prefix: file
Example (Before & After)
Before Renaming
https://drive.google.com/file/d/1so9-L7PhesLv45y6xH4nzYdEk1QlKBrU/view?usp=sharing
After Renaming
https://drive.google.com/file/d/1mzY2XGfYv9B4Oisgt4P9Y2gvUfc8zfZu/view?usp=sharing
Example Output
img1.jpg → file_1.jpg
img2.png → file_2.png
doc1.pdf → file_3.pdf
Renaming completed!
Edge Cases Handled
- Invalid folder path
- Empty folder
- Duplicate file names (skipped)
- Hidden files ignored
How It Works
- Access folder using
pathlib - Read all files
- Loop through files
- Generate new names using prefix + number
- Rename files safely
Author
Anuska Bhandari
License
This project is open-source and available under the MIT License.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file bulk_renamer_anuska-0.1.0.tar.gz.
File metadata
- Download URL: bulk_renamer_anuska-0.1.0.tar.gz
- Upload date:
- Size: 3.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
210f77b532cdb29fb908e96a5b59fff28512f19eed7a836b8c4841d86177ae0c
|
|
| MD5 |
93211697246b9c7ba0b70f6d80bc2888
|
|
| BLAKE2b-256 |
f50c1fec7523366948808bebcfe97f34379d8dc9eb77ce8f413452478111bae5
|
File details
Details for the file bulk_renamer_anuska-0.1.0-py3-none-any.whl.
File metadata
- Download URL: bulk_renamer_anuska-0.1.0-py3-none-any.whl
- Upload date:
- Size: 4.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1795a609d307bd6ce8d315c001c6c9eb1eda152def8a86ef18f5ee284604b180
|
|
| MD5 |
532e3f0ada2f3945ed51d4297a266feb
|
|
| BLAKE2b-256 |
476b627640de111d5601016f8eb81f99893b383f47fdec5e760ce4c4d88808e2
|