Re: linking libgit.a in C++ projects
From: Sverre Rabbelier <hidden>
Date: 2016-06-15 22:45:05
On Thu, Jul 31, 2008 at 13:10, cte [off-list ref] wrote:
I'm not worried about the interfaces changing; the gui is tied to a particular version of git, and I will update the code that calls into libgit I pull new changes from the mainline into my local clone.
You should be ;). Unless you are planning to learn a lot of C very fast, you should be worried about the interfaces changing. That is, if you want your GUI to be able to stay up to date with the current git version.
who's to say that the output of the various commands won't change formats with future releases of git?
Junio is to say. Plumbing output format is git's API.
There is no correct solution if you are worried about forward compatibility, unless a well defined API is created (which would be sweet btw, but is probably not a priority).
There is, use the plumbing, forward compatibility is 95% assured. With the exception of major releases, for which any plumbing output/behavior changes will be announced in the changelog, usually including an explanation on how to change your code to match. In short, use the forc-... errr, plumbing ;). -- Cheers, Sverre Rabbelier