Skip to content

Make Git Notes visible in the UI

Description

We are migrating 14 years of CVS history to Git, and the biggest issue is all the tools expecting a CVS-like revision ID (1.x[.y.z]). To that end, I have built a bunch of server-side hooks that tag CVS-like revision IDs to each commit using a Git note. Problem is, I cannot make this visible to our end users in the Gitlab UI (I have a CLI script that works fine).

There are other uses for notes, by tools like Git Appraise or Gerritt to store code review, for example.

Proposal

Add a per-project option for a new column in the Commits view that shows any available Git notes object (first line is sufficient in the commits list).

Links / references

  1. Git Appraise: https://github.com/google/git-appraise
  2. Gerrit Reviewnotes plugin: https://gerrit-review.googlesource.com/admin/projects/plugins/reviewnotes

Documentation blurb

The Settings -> Repository "Show Git notes" option sets Gitlab to display notes in the commits list and commit view. The notes namespace can be specified. If not, it defaults to refs/notes.

Overview

Anyone wanting to look at note objects on commits cannot do so from the Gitlab UI, they have to clone the repo and go to the command-line. This introduces friction in the integration with legacy build systems or notes-based code review tools.

By listing the notes, it's fast to locate a review, or figure out the build revision ID to pass to other tools.

Use cases

I can reference a CVS revision ID to start a specific build of our tool. The complex and existing build system expects CVS revision IDs, and many other tools do so. So if I want to start a build based on a particular Git commit message, I currently have to go to from Gitlab to a cloned repo, run the command that looks at the git notes, and pass that to the start-up script. If this were available, I would only have to copy the note displayed in the UI, and pass that to the start-up script directly.

Feature checklist

Make sure these are completed before closing the issue, with a link to the relevant commit.