<div dir="ltr">Do we actually need separate fetcher for gerrit?<div><br></div><div>We&#39;re using gerrit for everything @LGE and to fetch from open reviews instead of merged commits I&#39;m just setting the gerrit reference in SRCREV (e.g. refs/changes/61/252561/44) and normal git fetcher does the right think and fetches it correctly.</div><div><br></div><div>Advantage of using the same fetcher is to easily switch between tag/git ref/gerrit ref just by small SRC_URI modification instead of replacing whole repository (starting from fetcher change from git:// to gerrit://).</div><div><br></div><div>Adding optional parameter for git:// fetcher to make it easier to specify which review to pull seems easier to use and less error prone (as you probably never want to use e.g. review from glib gerrit project in dbus recipe, so always including the project name and showing error when the referenced review in change parameter doesn&#39;t point to the right project is IMHO better then fetching something completely different).</div><div><br></div><div>For topic parameter I don&#39;t understand how would you fetch the reviews if there are more then one with the same topic? Would you fetch multiple repositories in some automatically generated destdir directories? Or fetch just the patches and apply them on top of some other SRC_URI entry?</div><div><br></div><div>Regards,</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Nov 8, 2019 at 3:08 PM Adrian Ambrożewicz &lt;<a href="mailto:adrian.ambrozewicz@linux.intel.com">adrian.ambrozewicz@linux.intel.com</a>&gt; wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hello,<br>
<br>
As it is my first message here allow me to introduce myself. I&#39;m Adrian <br>
Ambrożewicz and I work at Intel Technology Poland. I love flexibility <br>
and features of Bitbake and I would like to propose new feature which <br>
will solve our problem.<br>
<br>
I would like to propose extension to already supported fetcher library - <br>
gerrit. Idea is to be able to apply gerrit patches by simply specifying: <br>
&quot;SRC_URI += gerrit://[gerrit_server];change=[change_id]&quot;. Fetcher would <br>
then take care of downloading most recent patchset from given review.<br>
Further extensiosn of that fetcher could include ability to specify:<br>
- revision (get given revision instead of top)<br>
- topic (get all patches from given topic)<br>
- project (to be used in conjunction with &#39;topic&#39; parameter)<br>
etc...<br>
<br>
I&#39;ve prepared minimal PoC implementation without any error handling. It <br>
works just fine and is basing on wget command. Gerrit REST API is used <br>
to obtain base64-encoded patch which is then decoded to file with name <br>
[change_id].patch . I&#39;m very interested in polishing that and <br>
upstreaming it for everyone to use.<br>
<br>
The question I have for you is the following: does this fetcher have a <br>
chance to be accepted upstream?<br>
<br>
Regards,<br>
Adrian<br>
-- <br>
_______________________________________________<br>
bitbake-devel mailing list<br>
<a href="mailto:bitbake-devel@lists.openembedded.org" target="_blank">bitbake-devel@lists.openembedded.org</a><br>
<a href="http://lists.openembedded.org/mailman/listinfo/bitbake-devel" rel="noreferrer" target="_blank">http://lists.openembedded.org/mailman/listinfo/bitbake-devel</a><br>
</blockquote></div>