Skip to main content

Rename and unrename all files in the directory, alphabetically or randomly

Project description

Frenamer (file-renamer)

Frenamer-logo

Rename and unrename all files in the directory, alphabetically or randomly

PyPI - Python Version PyPI License
test-frenamer Upload Python Package
Code style: black
Table of Contents
  1. Requirements
  2. Installation
  3. Usage
  4. Discussions
  5. Issues
  6. License

Requirements

Installation

PyPi

$ pip3 install frenamer

GitHub

$ git clone https://github.com/TheAwiteb/frenamer/
$ cd frenamer
$ sudo python3 setup.py install

Update

$ python3 -m pip install frenamer --upgrade

Note

if frenamer --help don't work with you use python3 -m frenamer --help or py -m frenamer --help for windows

Usage

Help message

Usage: frenamer [OPTIONS] COMMAND [ARGS]...

  Frenamer (File-Renamer) Tool help you to rename files and directories
  alphabetical or random names

Options:
  -V, --version  Frenamer (File-Renamer) version.
  --help         Show this message and exit.

Commands:
  rename    Rename directories with random names or alphabetical order.
  unrename  unrename directories, fetching old names from json files.

Rename

Help message

Usage: frenamer rename [OPTIONS] DIRECTORIES...

  Rename directories with random names or alphabetical order.

Arguments:
  DIRECTORIES...  Directories whose contents you want to rename.  [required]

Options:
  -r, --random          Rename with random names, or alphabetically.
  -l, --length INTEGER  Random name length.  [default: 10]
  -s, --save-date       Save directory names before and after renaming.
  -f, --filename TEXT   The name of the json file in which the directory names
                        are to be saved.  [default: rename_data.json]
  --help                Show this message and exit.

Alphabetically

$ frenamer rename <my_directory>
$ frenamer rename --save-date  <my_directory>
$ frenamer rename --save-date --filename data.json <my_directory>

Randomly

$ frenamer rename --random <my_directory>
$ frenamer rename --random --length 15  <my_directory>

Unrename

Help message

Usage: frenamer unrename [OPTIONS] DIRECTORIES...

  unrename directories, fetching old names from json files.

Arguments:
  DIRECTORIES...  Directories whose contents you want to unrename.  [required]

Options:
  -d, --delete         Delete the JSON files that were used in the unrenaming
                       after completion.
  -f, --filename TEXT  The name of the json file from which the directory
                       names will be extracted.  [default: rename_data.json]
  --help               Show this message and exit.

$ frenamer unrename <my_directory>
$ frenamer unrename --filename data.json <my_directory>
$ frenamer unrename --delete <my_directory>

Discussions

Question, feature request, discuss about frenamer here

Issues

You can report a bug here

License

The MIT License (MIT). Please see License File for more information.

Project details


Download files

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

Source Distribution

frenamer-0.2.3.tar.gz (9.9 kB view details)

Uploaded Source

Built Distribution

frenamer-0.2.3-py3-none-any.whl (10.0 kB view details)

Uploaded Python 3

File details

Details for the file frenamer-0.2.3.tar.gz.

File metadata

  • Download URL: frenamer-0.2.3.tar.gz
  • Upload date:
  • Size: 9.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.10.1

File hashes

Hashes for frenamer-0.2.3.tar.gz
Algorithm Hash digest
SHA256 f1f3c39cc79266acafcb6f36a91da9904cfd115e1ea92b2ca67437383f45b7c4
MD5 e83579d87f2154552a00ee00800ea9c0
BLAKE2b-256 093128130b23fb314cd0cb554edb1019b89a023385bb33e7db85ad578e3a3b00

See more details on using hashes here.

Provenance

File details

Details for the file frenamer-0.2.3-py3-none-any.whl.

File metadata

  • Download URL: frenamer-0.2.3-py3-none-any.whl
  • Upload date:
  • Size: 10.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.10.1

File hashes

Hashes for frenamer-0.2.3-py3-none-any.whl
Algorithm Hash digest
SHA256 3586e1286cb1ff28a9905b03901edc6fb18e97c8291c7eeaecc68c3aace4d6e5
MD5 74e0614bc05674269cf86591b389827a
BLAKE2b-256 520d422918efc4ef53ffe68edb33854c8b717e0218574c437eef5f990b21aa08

See more details on using hashes here.

Provenance

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page