Re: jgit as a jira plugin

!MAILaRCHIVE_VOTE_RePLACE
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: Shawn O. Pearce <spearce@...>
Cc: <git@...>
Date: Wednesday, October 29, 2008 - 7:49 pm

On 29-Oct-08, at 7:08 PM, Shawn O. Pearce wrote:

Basically I stole the pgm.Fetch code:

Transport tn = Transport.open(repository, "origin");
final FetchResult r;
List<RefSpec> toget = new ArrayList<RefSpec>();
try {
	r = tn.fetch(new TextProgressMonitor(), toget);
} finally {
	tn.close();
}

Can I assume that this enough to update the database?  If so I think  
I'm doing what you're suggesting.  After this (and not shown) is some  
logging code taken from Fetch, which results in the following:

 From /Users/longman/workspace2/work/../masterRepo/
     131dcf5..078d43f  master     -> origin/master

but there doesn't appear to be any specific mention of the incoming  
changes.



Well, the egit does provide some examples, just there's another API  
involved which can be confusing.  The code in the jira git plugin the  
key classes are GitManagerImpl and RevisionIndexer, but the  
RevisionIndexer has some Lucene (text search engine) API mixed-in.  
Plus I'm still even learning about git much less the jgit api so I  
can't vouch for quality or correctness ;-).  I could snip some code  
out and send it to you off-list for inclusion in the wiki maybe.

later, j

--
J. Longman
longman@xiplink.com

The information transmitted is intended only for the person or entity to
which it is addressed and may contain confidential and/or privileged
material.  If you have received this in error, please contact the sender
and delete this communication and any copy immediately.  Thank you.


--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
jgit as a jira plugin, J. Longman, (Wed Oct 29, 7:02 pm)
Re: jgit as a jira plugin, Shawn O. Pearce, (Wed Oct 29, 7:08 pm)
Re: jgit as a jira plugin, J. Longman, (Wed Oct 29, 7:49 pm)
Re: jgit as a jira plugin, Shawn O. Pearce, (Wed Oct 29, 7:53 pm)