News about Gerrit, Jenkins & friends

Here are a few things I’ve updated on Gerrit, Jenkins and associated tools:

  1. Gerrit
    • The Gerrit bot, gerritwk23, has now support for !pl (and pl in a query). It’s just like zebrapig’s !pl.
    • I’ve updated Gerrit in mid-Decembre. Since then, you can switch to a newly designed “Change View” which you’ll find under your account’s settings in the “Change View” option. There’s also an associated “Diff View” option to set your preferred diff style if you switch to the new Change View.

2. Jenkins

    • In its build logs, you’ll now find the mounts, the cave resolve command and the (likely) dependencies gathered from the installed package. Dependency information might not be 100% accurate so please take it with a grain of salt but it’s usually a good indicator.
      Look out for “**************************************************************” to find that information.

 

If you have any ideas about what else to improve, please let me know.

I am and have been working on quite a few F/OSS projects:
  • Exherbo (Nick: Philantrop)
  • Gentoo (Nick: Philantrop)
  • Calibre plugin iOS reader applications
  • Calibre plugin Marvin XD
  • chroot-manager
  • stuff on github
  • Lots of other projects
  • If you like my work, feel free to donate. 🙂

    Another good reason to use Gerrit: Jenkins is at your service

    If it’s not yet good enough for you that using Gerrit

    • is even easier and faster than using zebrapig (you just push your change and you’re done! And if you use git review it’s getting even easier.),
    • the review turn-around times are often better when using Gerrit than zebrapig,
    • discussing patches can be done both when you’re on IRC and on Gerrit,

    then here’s another good reason to use it: I’ve set up Jenkins for all repositories on Gerrit to build every change in a chroot (including sydbox-1, pinktrace-1 and docs).

    For now, all reports only go to me (and anyone else who wants to get an email with the result included) and Jenkins will not report back to Gerrit because the setup is quite fragile yet and I want to be sure it works properly before making it do more.

    No idea how to use Gerrit? Just read my earlier posts Gerrit Code Review for Exherbo and Gerrit for Core-Devs. Of course, you can ask me, too. 🙂

     

    I am and have been working on quite a few F/OSS projects:
  • Exherbo (Nick: Philantrop)
  • Gentoo (Nick: Philantrop)
  • Calibre plugin iOS reader applications
  • Calibre plugin Marvin XD
  • chroot-manager
  • stuff on github
  • Lots of other projects
  • If you like my work, feel free to donate. 🙂

    Gerrit installation updated to the 2.7 release, pesky “internal server error” fixed

    I’ve just updated the Gerrit installation to the 2.7 release and fixed the pesky “internal server error” that occurred when entering a user name or similar.

    I’ve also updated my posts on Gerrit and the FAQ-like post for core devs:

    Gerrit Code Review for Exherbo

    Gerrit for Core-Devs

     

     

    I am and have been working on quite a few F/OSS projects:
  • Exherbo (Nick: Philantrop)
  • Gentoo (Nick: Philantrop)
  • Calibre plugin iOS reader applications
  • Calibre plugin Marvin XD
  • chroot-manager
  • stuff on github
  • Lots of other projects
  • If you like my work, feel free to donate. 🙂

    Gerrit for Core-Devs

    There have been a few questions and potential misunderstandings I’m going to try to address here. I’ll update this post if new stuff comes up.

    • Getting the foo Or: How do I become a Core-Dev on Gerrit?
      Simple: You register with your GitHub or Google account, then you ask any other core dev to add you to the group. At least Bo “zlin” Ørsted Andresen and I know how to do it and every member has the necessary privileges.
    • Reviewing Or: +1+1 != +2
      Every registered user can comment and/or -1/+1 a change. This is an indication said user has reviewed the patch and, ideally, tested it. It’s basically only an opinion, though.
      Only Core-Devs can +2 a change. This means they’ve reviewed and tested that change and are approving it. The change then will get merged and pushed.
      It’s important to remember, though, that +1’s do NOT add up. You can +1 a change a hundred times but it will still need one bold man (or woman) to +2 it.
      Important as well, don’t forget to press the “Submit” button if you want to get a change merged.
    • What about testing (or the lack of)?
      Everyone who +2’s a change at least (ideally, +1 would indicate you tested the thing, too!) is expected to have actually tested it. If you +2 it but didn’t test it, we’re going to slowly roast you over a scented candle. 
    • What’s the easiest way to test a patch?
      Use dev-scm/gertty.

      (Previsouly: I look at the patch, at the “Downloads” line, I click on “Patch” and then click on the small clipboard icon next to the git fetch comand. That adds said line to your clipboard. Next, I cd into the respective repository, paste the line we just copied and append “| git am”. That’s it, patch applied, now test it!)

    • Merging & pushing (no, not like that, you pervert!)
      Gerrit now pushes merged changes directly to our repositories. This means, once you +2 and submit a change (cf. first point), you push it.
    • Command line tricks or How do I…
      … most easily review a change?git review -d -t <change number, e. g. 202>

      … merge a boat-load of patches I reviewed and tested at once?

      On your branch with the changes applied: ssh -p 29418 <username>@galileo.mailstation.de gerrit review –code-review +2 –submit $(git rev-list gerrit/master..HEAD)

      … query for a specific change?

      ssh -p 29418 <username>@galileo.mailstation.de — gerrit query –comments change:212

      …  get a list of all open changes?

      ssh -p 29418 <username>@galileo.mailstation.de — gerrit query status:open (add a “project” parameter if you want only changes for a certain repository, e. g. “project:arbor”)

      … add a comment from the command line?

      ssh -p 29418 <username>@galileo.mailstation.de — gerrit review -m “\”At the very least this commit message should explain why we have to put PWD in PYTHONPATH which can’t be quoted properly… But other than that, seems sensible at least for now.\”” $changeid

    I am and have been working on quite a few F/OSS projects:
  • Exherbo (Nick: Philantrop)
  • Gentoo (Nick: Philantrop)
  • Calibre plugin iOS reader applications
  • Calibre plugin Marvin XD
  • chroot-manager
  • stuff on github
  • Lots of other projects
  • If you like my work, feel free to donate. 🙂

    Gerrit Code Review for Exherbo

    I’ve installed a Gerrit Code Review instance on my server for use with Exherbo.

    Gerrit is a code review tool and allows for

    • discussing patches and keeping the results for future reference
    • get notified by email about changes (if you want)
    • easily work on every Exherbo repository
    • contributors to get their repositories added to Gerrit as well (optional but strongly recommended)
    You’ll find an introduction to Gerrit here.
    Notes:
    • You need a GitHub or Google account. The email address you wish to use in Gerrit must be configured in your GitHub account.
    • You MUST use your real name for copyright reasons.
    • Gerrit replicates merged changes pretty much immediately. This sometimes/rarely fails on the first attempt for various reason. I’ve implemented a fallback that occurs every 5 minutes.

    How to use Gerrit:

    Initial setup in two easy steps:
    1. Go to https://galileo.mailstation.de/gerrit//, in the upper right corner, click “Sign in”.
    2. Authorize Gerrit with GitHub or Google.
     Cloning a repository:
    1. Click “Projects”, “List”, then choose a project.
    2. You should see several methods for cloning the project, the easiest way is to choose the ssh method.
    3. Clone, e. g. git clone ssh://<user name>@galileo.mailstation.de:29418/alip
    4. Install a hook that sets a Change-Id automatically (choose one of the two alternatives):

    scp -p -P 29418 <your username>@galileo.mailstation.de:hooks/commit-msg <local path to your repository>/.git/hooks/
    curl -o <local path to your repository>/.git/hooks/commit-msg https://galileo.mailstation.de/gerrit/tools/hooks/commit-msg

     

    chmod +x <local path to your repository>/.git/hooks/commit-msg

    Uploading changes:

    There are several methods to upload changes:
    1. Work on your copy of the repository, commit.
    2. Push your changes: git push origin HEAD:refs/for/master
    You can use git review for easily setting up your repository clone and submitting patches, too. It’s quite nice, use it!
    You might want to read the following posts as well:

     

     

     

    And if you just can’t get enough: All my posts about Exherbo’s Gerrit.