我想知道的是,访问git有很多java实现。
有没有办法使用thees库? 我看过很多关于如何通过java代码访问git的教程。它是一个具有git函数的类。但是没有考虑我们如何将这些代码用于实际应用。
然后不使用插件IDE(jgit,egit ....)或CLI工具我们如何在java项目中使用thees库?
答案 0 :(得分:2)
您可以在任何IDE之外以及任何Java项目中使用的一个库是JGit(sources at GitHub,User Guide)。
请参阅“Confusion in choosing between JavaGit, JGit and EGit”
该库可以独立于Eclipse使用。
作为I mention in this answer,包org.eclipse.jgit.test/tst/org/eclipse/jgit
包含大量测试,供您举例说明。
这个JGit cookbook project也是一个很好的例子来源。