0

I have a set of GIF files in which I need to insert a specific string at anywhere inside the binary file but it should not be visually different. I could probably do it in an hex editor but not sure where, as it may corrupt the file.

This is a requirement by by my source control system where it is checked for "$Header $" string in each file before they are checked in.

I have many files so need to do this using python.

Neil
  • 5,919
  • 15
  • 58
  • 85
  • Normally you should be able to write after the end of a `GIF` without breaking it (at least for browsers and image editors). However, `GIF89a` also has some support for textual metadata. Take a look [here](http://www.forensicswiki.org/wiki/GIF) and [here](http://en.wikipedia.org/wiki/Graphics_Interchange_Format) – dmg Mar 04 '13 at 08:30
  • This isn't a requirement of RCS itself. It handles binary files just fine. [This question](http://stackoverflow.com/questions/1619737/migrate-project-from-rcs-to-git) may be relevant all the same. – Cairnarvon Mar 04 '13 at 08:51
  • @DJV thanks Appending it at the end worked fine, I don't see any distortion in the image however checking in still failed , let me check Cairnarvon 's answer – Neil Mar 04 '13 at 09:21

0 Answers0