Jellyfin Forum
Dealing with "New:" in Folder title - Printable Version

+- Jellyfin Forum (https://forum.jellyfin.org)
+-- Forum: Support (https://forum.jellyfin.org/f-support)
+--- Forum: Troubleshooting (https://forum.jellyfin.org/f-troubleshooting)
+---- Forum: Media Scanning & Identification (https://forum.jellyfin.org/f-media-scanning-identification)
+---- Thread: Dealing with "New:" in Folder title (/t-dealing-with-new-in-folder-title)



Dealing with "New:" in Folder title - Elsmandino - 2024-02-15

Hi there.

I use TVHeadend to record all my TV programmes and then scrape that folder, automatically, into Jellyfin.

However, I have an issue whereby my EPG will mark brand new episodes with "New:" at the beginning of the title.

As such, I get "New:" at the beginning of the programme folder and all the individual episodes inside.

When this happens, Jellyfin gets confused and will not pick up the show.

Can anyone possibly suggest any way round this, please?  Is there a way for Jellyfin remove "New:" from the beginning of recordings or perhaps ignore it when scraping?


RE: Dealing with "New:" in Folder title - Efficient_Good_5784 - 2024-02-15

Jellyfin doesn't have that type of functionality to remove any string from file names.

What you can do is create a script to do this for you.

If your media is on a linux server, you can create a bash script that will:
  1. Find either all files of that type (and use grep to only get results with "New:"), or files that contain "New:" in the filename, and make a list of the found files.
  2. Use something like sed to replace all instances of "New:" as "".
  3. Pass on a new list of only edited filenames (along with their full paths).
  4. Use both the old and new lists to copy the actual files from their old names to their new names in the same path.
  5. Use the old list to remove the old files.

You can then make a cron task that uses this script on a daily basis to rename your files for you.