HouseOfCards 71 Posted April 9, 2023 Share Posted April 9, 2023 Right here... Can there be an option here to "Ignore Metadata Date If Present...", or something similar, so that Emby uses the option you select even if there is an NFO file with a date in the media folder? If you save metadata to an NFO, this setting becomes permanently useless. Allowing an option to ignore the original date added could be helpful if users have a need. I move files in/out of the library, but the date from the original time I add it becomes permanent without this option.. Vote! Thanks! Link to comment Share on other sites More sharing options...
visproduction 123 Posted April 11, 2023 Share Posted April 11, 2023 HOC, You can edit the date added, per media and that updates it's position in an added sort or latest recent media. In order to see an immediate change use the Metadata edit in the page in the browser. If you edit in the nfo file, it will probably only show a change then next time the library is scanned. 1 Link to comment Share on other sites More sharing options...
HouseOfCards 71 Posted April 13, 2023 Author Share Posted April 13, 2023 On 4/10/2023 at 8:16 PM, visproduction said: HOC, You can edit the date added, per media and that updates it's position in an added sort or latest recent media. In order to see an immediate change use the Metadata edit in the page in the browser. If you edit in the nfo file, it will probably only show a change then next time the library is scanned. I know. My issue is this is the last piece of the puzzle in my "interactive" media server. I use scripts to copy content in and out of the server so it is constantly updating/dynamic. Because Emby is reading the "date added" from the .nfo file, every time it gets re-added, it uses the date from the first time I added it, and still won't show up in the "recently added" list. Without an option such as this, I'll need to figure out some complicated script to strip the date added line out of the .nfo files, so it gets recreated when it's copied back in. I know I'm an "edge case" on this one, but I'd like my Christmas movies to show up in the recently added list when I throw them back in each December. Link to comment Share on other sites More sharing options...
Happy2Play 8296 Posted April 13, 2023 Share Posted April 13, 2023 And an easier route would be place all of them in their own folder/library and only enable access as needed instead of moving in and out of existing library. But yes a simple script could be made to clear the node if needed. Just like the similar thing done here with notepad++, same concept different node. 1 Link to comment Share on other sites More sharing options...
visproduction 123 Posted April 13, 2023 Share Posted April 13, 2023 HC, What about just adding date in your script? https://www.computerhope.com/datehlp.htm 1 Link to comment Share on other sites More sharing options...
HouseOfCards 71 Posted April 13, 2023 Author Share Posted April 13, 2023 Unless this override option becomes a reality, I'll likely have to figure out a script solution, but I'm not a scripting guru by any means. I have Emby running on UnRAID which has a useful plugin called "User Scripts". It would be easy enough to have a script run once in a while which performed the modifications, but I'll need to figure out how to accomplish that using Linux/BASH. From what I gather, it would be something like... 1. Locate every file ending in ".nfo" recursively through all subfolders... 2. Open each ".nfo" and remove the line containing "<dateadded>SOMEDATETIME</dateadded>"... 3. Resave the modified ".nfo" file... In the complicated world of scripting, Linux can probably do this in one line of code, but I'll be damned if I know where to start. LOL Link to comment Share on other sites More sharing options...
Solution visproduction 123 Posted April 14, 2023 Solution Share Posted April 14, 2023 HC, Aha, what about making a script that adds a version number to the name of the file? Emby would then consider it new media and auto update the dateadded to the present date. In a shell script, I think you would use a 'for' command to do all files in a folder and subfolders. If you want to be more selective, then maybe do it in two steps. Collect the file location and titles for all media to update, one media per line and then add the rename command in front and the version add on text at the end of each command line, then just run the file as a script. Once you have the list of media files location you can use grep, to add the extra rename command bits. I like to just do it with Excel and copy the tweaked command lines to a text editor and use Search replace to get rid of unwanted tabs. If you have all the locations, I can tweak 10,000 command lines in a under a minute. If you want to try that and need help, let me know with a private message. 1 Link to comment Share on other sites More sharing options...
HouseOfCards 71 Posted April 25, 2023 Author Share Posted April 25, 2023 On 4/14/2023 at 9:12 AM, visproduction said: HC, Aha, what about making a script that adds a version number to the name of the file? Emby would then consider it new media and auto update the dateadded to the present date. In a shell script, I think you would use a 'for' command to do all files in a folder and subfolders. If you want to be more selective, then maybe do it in two steps. Collect the file location and titles for all media to update, one media per line and then add the rename command in front and the version add on text at the end of each command line, then just run the file as a script. Once you have the list of media files location you can use grep, to add the extra rename command bits. I like to just do it with Excel and copy the tweaked command lines to a text editor and use Search replace to get rid of unwanted tabs. If you have all the locations, I can tweak 10,000 command lines in a under a minute. If you want to try that and need help, let me know with a private message. I went the script route, and I hammered this out with some good folks at a Unix forum. For those interested, it's here... https://community.unix.com/t/batch-remove-line-from-files-recursively/390725/25 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now