Re: Git Library?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Apr 28, 2008 at 11:55 AM, Patrick Altman <paltman@xxxxxxxxx> wrote:
> I want to write a Mac OSX UI for git.
>

git gui works on OSX.
Aside from that, someone's already written one* :-)

    http://repo.or.cz/ugit.git
    http://ugit.sf.net/


>  Is there a documented/undocumented API for interacting with git in process?
> Or would I be better off "shelling out" to the git command line?

Fork/exec.

If you grabbed the ugit modules you could say:

    from ugit import git

    revisions = git.rev_list(all=True).splitlines()

    file = open('msg', 'w')
    file.write("commit message." )
    file.close()

    git.commit(F='msg', s=True)

    etc, etc.

It's pretty much 90%+ of git wrapped in Python.
If a libgit.so did appear one day it would be trivial to swap out the
meta-functions in
git.py and replace them with e.g. swig replacements.  Until then,
forking out works
just fine.

stg also has Python wrapped around git so you could look there too.

-- 
 David


* - okay, I lied. It's PyQt4.  But it does run on OSX and looks just
like any other cocoa app.
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux