Page 1 of 1

[Feature Req] Strip Metadata/Set Metadata

Posted: 09 Jul 2016, 20:39
by thantik
Lots of files I have and have used FileBot for renaming have this tendency to have garbage metadata. Most notably "Title" and "Comments", usually have some stupid tag added to them. An option for stripping metadata entirely, or setting the title/comments to a custom value would be handy. When these are set, some of my software for organization looks for the Title/Comments first, before the filename for organization - being able to strip this through filebot would save a lot of time. As it is right now, I use filebot to rename, and then have to use other utilities to strip the metadata.

Seems like a simple request - but I understand how difficult it would be to implement. Different filetypes, metadata formats, risk of corrupting files - totally understand if you're reluctant to tackle it.

Re: [Feature Req] Strip Metadata/Set Metadata

Posted: 10 Jul 2016, 04:53
by rednoah
You're talking about mkv/mp4 tags. That's part of the file content. By design, FileBot will never modify files for the aforementioned reasons, so it can't strip those tags.

Other tools may help and it should be fairly easy to automate this process:
https://mkvtoolnix.download/doc/mkvpropedit.html

Not sure if there's a single tool that can deal with all formats...

Re: [Feature Req] Strip Metadata/Set Metadata

Posted: 11 Jul 2016, 00:39
by thantik
rednoah wrote:Not sure if there's a single tool that can deal with all formats...
Yep, that's my problem. I fully understand the reasoning behind not wanting this feature or deeming it out-of-scope. Thank you for your time and consideration.

Re: [Feature Req] Strip Metadata/Set Metadata

Posted: 18 Dec 2016, 09:48
by khsefbh
I respect your decision to not modify the files' contents, and I understand that there is no single tool that can accomplish this. Could you please implement something half-way though? Here's what I have in mind: when a user scans a file and asks for it to be renamed (assuming the identification went well), could you please create a .ini file with the same basename as the video file? The .ini file should contain all the info that you have in your database about it. I can script the next step for myself, and fill in the tags using other tools. The choice of .ini is a matter of taste, of course. I would be just as happy with a JSON file.

Re: [Feature Req] Strip Metadata/Set Metadata

Posted: 18 Dec 2016, 10:52
by rednoah
FileBot does store all metadata as JSON to filesystem extended attributes (if supported).

You may use the xattr script (or any other xattr tool) to view xattr.

Re: [Feature Req] Strip Metadata/Set Metadata

Posted: 18 Dec 2016, 18:23
by khsefbh
@rednoah I did not know that! Thank you for pointing it out to me. I'll proceed with writing my custom scripts now.

Re: [Feature Req] Strip Metadata/Set Metadata

Posted: 18 Dec 2016, 20:58
by rednoah
Make sure to share them here afterwards. ;)

Re: [Feature Req] Strip Metadata/Set Metadata

Posted: 15 May 2018, 16:09
by flick
khsefbh wrote: 18 Dec 2016, 18:23 @rednoah I did not know that! Thank you for pointing it out to me. I'll proceed with writing my custom scripts now.
@khsefbh Did you ever post your scripts anywhere? I'm very interested in doing this as well. Thanks!

Re: [Feature Req] Strip Metadata/Set Metadata

Posted: 16 May 2018, 06:13
by underrepresented
rednoah wrote: 10 Jul 2016, 04:53 You're talking about mkv/mp4 tags. That's part of the file content. By design, FileBot will never modify files for the aforementioned reasons, so it can't strip those tags.

Other tools may help and it should be fairly easy to automate this process:
https://mkvtoolnix.download/doc/mkvpropedit.html

Not sure if there's a single tool that can deal with all formats...
ffmpeg will strip all metadata.

I use iffmpeg myself. You can simply do a passthru to wipe just the metadata or or recode to any format you choose.

Code: Select all

ffmpeg -i "$1" -c:v copy -c:a copy -map_metadata -1 -metadata output.mpg
or /mov/mp3/avi/mkv etc.

Re: [Feature Req] Strip Metadata/Set Metadata

Posted: 04 Jan 2019, 17:19
by Sauron99
MP3TAG allows batch stripping/modifying metadata from video files including MP4. You can also preserve the file timestamp.

https://help.mp3tag.de/index.html
https://www.videohelp.com/software/Mp3tag

Re: [Feature Req] Strip Metadata/Set Metadata

Posted: 05 Jan 2019, 06:45
by rednoah
Are you using the CLI or the GUI?

If you're using the CLI, then 3rd party tools can easily be integrated using the -exec option:
viewtopic.php?f=4&t=5047