I recently asked Removing duplicate files but ignoring certain lines (e.g. embedded timestamp).
I suspect I am falling into an XY trap (I realized this more and more as I typed the question which is why the focus kind of shifts towards the end). My fundamental issue is making MySQL backups only if the database has changed. My current attempted solution is to write a script to find duplicates (which has the problem that timestamps are embedded in the files), and my immediate issue is with the attempted solution.
I presented the fundamental issue for obvious reasons; to open the possibility for an answer that points out a better way entirely.
However, this potentially stops an answer to the immediate question of how to find duplicate files but ignore certain lines, which is also a useful question in general.
Should I leave the question as is, or should I split it (and how)? What's a good thing to do in general if I suspect there is a better way to do what I am trying to do but the specific solution is useful as well?