New gui extension

Jens Alfke jens at mooseyard.com
Fri Jul 27 10:08:57 CDT 2007


On 27 Jul '07, at 12:08 AM, Brad Schick wrote:

> gtools is a mercurial extension written in python, so it gets called
> directly from within the hg process. I really wanted to avoid parsing
> text output and for the most part that was possible without  
> duplicating
> too much mercurial code.

That sounds nice and comfy. And technically, calling Python from  
Objective-C is very easy, as there's a bridge that lets each language  
use the other's objects transparently. But legally, using mercurial in- 
process would GPL-infect my code, and I don't want to do that (BSD's  
more prevalent in the Mac community.)

So far I haven't run into any hg output that's kludgy to parse:  
"status" is trivial, and my style makes "log" output XML. I could run  
into issues with other commands, though; then I'd look into enhancing  
mercurial itself to add options to those commands to generate more  
parseable output. (Much like Monotone's "mt automate" commands.)

--Jens


More information about the Mercurial mailing list