gerrit_related_changes

command
v0.0.0-...-9994f1b Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 22, 2025 License: BSD-3-Clause Imports: 16 Imported by: 0

README

A CLI tool to find related changes given a Gerrit CL. See Gerrit documentation.

Auth

Note that you'll need to log in with bb auth-login and have the https://www.googleapis.com/auth/gerritcodereview OAuth scope.

Sample usage

go run gerrit_related_changes.go gerrit_related_changes --input_json="sample-stacked.json" --output_json="/tmp/sample_gerrit_related_changes_output.txt"

gives:

cat /tmp/sample_gerrit_related_changes_output.txt
{
 "related": [
  {
   "project": "chromiumos/platform2",
   "_change_number": 4508966,
   "_revision_number": 2
  },
  {
   "project": "chromiumos/platform2",
   "_change_number": 4508965,
   "_revision_number": 1
  }
 ],
 "relatedCount": 2,
 "hasRelated": true
}
Unrelated changes

go run gerrit_related_changes.go gerrit_related_changes --input_json="sample-unstacked.json" --output_json="/tmp/sample_gerrit_related_changes_output.txt"

gives:

cat /tmp/sample_gerrit_related_changes_output.txt
{
 "related": [],
 "relatedCount": 0,
 "hasRelated": false
}

Documentation

Overview

Copyright 2023 The Chromium Authors Use of this source code is governed by a BSD-style license that can be found in the LICENSE file.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL