Friday, 9 December 2011

Yay for git!

Friday, 9 December 2011 21:25
pne: A picture of a plush toy, halfway between a duck and a platypus, with a green body and a yellow bill and feet. (Default)

So I’m working on a font in FontForge for several days, when suddenly the program crashes. OK, not the first time, so I restart: and am greeted with an error message (“Internal Error: Invalid 2nd order spline in SplineRefigure2”). Oops, what now.

Apparently, that happens when the quadratic splines which are internally represented as cubic splines end up not being a valid quadratic spline after all. But how to fix that?

Now I was happy that I had added the file to a local git repository and had been committing regularly, typically after every letter. So I could have gone back in time until a good place and then started redoing my work without the bad letter(s). Annoying, but possible.

But enter git bisect! That identified the single bad commit for me (the letter R, for what it’s worth).

And then git rebase -i let me reply the series of commits from T to the end onto Q (the last good one), so the end result was the same as before, except minus the bad commit. (I had two conflicts along the way, but they were easily resolved.)

So yay! It seems that the error was only in the R. And it’s much less annoying to redraw one letter than a whole bunch!

Git saves the day!

Profile

pne: A picture of a plush toy, halfway between a duck and a platypus, with a green body and a yellow bill and feet. (Default)
Philip Newton

June 2015

S M T W T F S
 12 3456
78910111213
14151617181920
2122232425 2627
282930    

Most Popular Tags

Page Summary

Style Credit

Expand Cut Tags

No cut tags
Page generated Tuesday, 8 July 2025 16:52
Powered by Dreamwidth Studios