Replies: 2 comments
-
You can do it with a python callback, but I suspect the easiest way would be to get git's hashes for both the old and new blob and then run:
followed by running filter-repo. filter-repo pays attention to replace refs and makes them permanent automatically, no special flags required. (Although, if you were only replacing the image and not rewriting anything else or splitting the repository, you'd have to pass --force to filter-repo, because filter-repo has a safety check to error out when not given any filtering options.) |
Beta Was this translation helpful? Give feedback.
-
I was trying to do something very similar (in my case, substituting a one pdf with another that had had a minor change made), but I was not able to get the above git replace command to work. My steps were to:
This would give the message: Instead, I followed steps 1 and 2 above, then ran the following: I don't really know what I'm doing and probably there is something basic I was missing with the 'git replace' option, but this worked for me. |
Beta Was this translation helpful? Give feedback.
-
Hi.
Some time ago one committed a quite large image to our git repository. Now we are splitting this repository into multiple smaller repos and I want to take the opportunity to replace this big images blob with a smaller one.
Is there a simple way to do this? The only way I can image from the docs is to write a python callback.
Beta Was this translation helpful? Give feedback.
All reactions