ReNamed

Renamed Banner

GitHub Issues GitHub repo size GitHub last commit GitHub Release GitHub Sponsors

ReNamed

ReNamed is a simple, terminal-based C tool that helps you automatically rename and organize episodes of TV shows β€” including specials β€” with clean, consistent filenames.

πŸ’‘ What it Does

This utility scans a folder of video files (or optionally any files), detects the episode numbers using a variety of common patterns, and renames them based on a user-supplied show name. Special episodes (like OVAs, bonus content, or labeled β€œSP”) are detected and moved into a separate Specials/ subfolder.

πŸ› οΈ How to Use

  1. Download the file
    curl -O https://raw.githubusercontent.com/Panonim/ReNamed/refs/heads/main/main.c
    
  2. Compile the program:
    gcc -o renamed main.c
    
  3. Run it:
    ./renamed
    
  4. Follow the prompts:
    • Enter the show name (e.g., Attack on Titan)
    • Enter the path to the folder with episodes
    • Review the renaming plan
    • Confirm whether to proceed

Optionally put it inside /usr/local/bin to use it anywhere

βš™οΈ Options

You can use the following command-line flags:

Examples:

# Force include all file types
./renamed -f

# Create a log file of all operations
./renamed --log

# Use a custom pattern for episode detection
./renamed --pattern='Season (\d+)-Episode (\d+)'

# Combination of options
./renamed -k -f --log -p /path/to/output

🧠 Features

πŸ“œ Logging

When using the --log option, ReNamed creates a detailed log file that includes:

This is especially useful for batch operations or when troubleshooting issues.

πŸ” Custom Patterns

The --pattern option allows you to specify your own regular expression for detecting episode numbers, which is useful for shows with unconventional naming. The pattern should include at least one capture group for the episode number.

Examples:

# For filenames like "Show.S01E05.mp4"
./renamed --pattern='S[0-9]+E([0-9]+)'

# For filenames with season and episode like "Show.S01-E05.mp4" 
# (uses the second capture group)
./renamed --pattern='S([0-9]+)-E([0-9]+)'

πŸ“‚ Example

Say you have:

Attack_on_Titan_E01.mkv
Attack_on_Titan_Special_01.mp4
Attack_on_Titan_E02.mkv

After running the tool, the folder becomes:

Attack on Titan - 01.mkv
Attack on Titan - 02.mkv
Specials/
  Attack on Titan - 01 - Special.mp4

Star History Chart

Β© 2025 Artur Flis. All Rights Reserved.