npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

tv-shows-file-renamer

v1.0.7

Published

CLI tool to rename files for tv-shows to add S01E01 notation based on folder location

Downloads

10

Readme

tv-shows-file-renamer

CLI tool to automatically rename and group files for TV series.

Main functionality:

  • Extract series metadata from thetvdb.com API.
  • Group episodes by Season folders.
  • Automatically change subtitles encoding to UTF-8 from specified encoding.
  • Build filenames which are easily recognizable by Plex mediaserver

So, if you have bunch of files named like this:

🎬 150.mkv
📝 150.eng.srt
🎬 S09E11 - ONEPIECE - 153.mkv
🎬 [CoolSubsTeam] - 196 - OnePiece.mkv

The tool provides a fast way to get this:

📁 Season 09
    🎬 S09E007 - 150 - Dreams Don't Come True! Bellamy vs. The Saruyama Alliance.mkv
    📝 S09E007 - 150 - Dreams Don't Come True! Bellamy vs. The Saruyama Alliance.eng.srt
    🎬 S09E010 - 153 - This is the Sea of the Sky! The Knight of the Sky and Heaven's Gate.mkv
📁 Season 10
    🎬 S10E001 - 196 - Emergency Announcement! An Infamous Pirate Ship has Invaded!.mkv

Prerequisites

This tool is built with NodeJS, so it should be installed in your system.

  • NodeJS at least v8.5.0
  • NPM at least 5.3.0

Installation

npm i -g tv-shows-file-renamer

Usage

Just call it in folder with your series and specify parameters

tv-shows-file-renamer -s one-piece

Commandline parameters:

| Key | Value | Description | Example | | --- | --------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------- | | -s | serie identificator | This is a serie identificator used by thetvdb.com API. To get it you need to locate you serie on the thetvdb.com website and copy part of URL. For example for this url: https://www.thetvdb.com/series/one-piece the serie id is one-piece | -s one-piece | | -d | dry run mode | You can check expected output but without actual performing any operations on disk. Useful when you are not sure about whether metadata are correct. | -d | | -m | only extract metadata | Does not perform any operations with you series, only downloads metadata for given serie from thetvdb.com API and saves that to META.json file. | -m | | -e | encode subtitles | Performs re-encoding of *.srt files from specified encoding to UTF-8 | -e cp1251 |

Please use it on your own risk, if you are not sure please make backup of your data first!

Licence: MIT