Over a million developers have joined DZone.
{{announcement.body}}
{{announcement.title}}

Python API to git: gitapi

DZone's Guide to

Python API to git: gitapi

· Web Dev Zone
Free Resource

Make the transition to Node.js if you are a Java, PHP, Rails or .NET developer with these resources to help jumpstart your Node.js knowledge plus pick up some development tips.  Brought to you in partnership with IBM.

Train rides can be good - if not creativity, then at least boredom-induced productivity. I had planned to make a hgapi fork that worked against git instead of Mercurial, and during the ride back from holding a Python workshop in Malmö (a three-hour trip back to Karlskrona; I still have another hour to go...), I finally did. gitapi is born, and even though its in it's infancy, it supports a large number of common operations. Fair warning - I basically just swiched hg->git and then fixed the test cases that still made sense, so there's bound to be some kinks left to iron out. Either way, the test suite passes on both Python 2.7 and 3.2, so there's something.

hgapi is a pure-Python API to Mercurial, that uses the command-line interface instead of the internal Mercurial API. The rationale for this is twofold: the internal API is unstable, and it is GPL.

hgapi works for Mercurial < 1.9, and will instantly reflect any changes to the repository (including hgrc). It also has a really permissive license (do whatever you want, don't blame me).



Learn why developers are gravitating towards Node and its ability to retain and leverage the skills of JavaScript developers and the ability to deliver projects faster than other languages can.  Brought to you in partnership with IBM.

Topics:

Published at DZone with permission of Fredrik Håård, DZone MVB. See the original article here.

Opinions expressed by DZone contributors are their own.

The best of DZone straight to your inbox.

SEE AN EXAMPLE
Please provide a valid email address.

Thanks for subscribing!

Awesome! Check your inbox to verify your email so you can start receiving the latest in tech news and resources.
Subscribe

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}