From 27d2232eb3cc4ec91fe6143b5d5c0d6f72861248 Mon Sep 17 00:00:00 2001 From: Carlos Fernandez Date: Fri, 3 Apr 2026 08:00:35 -0700 Subject: info: add --format and --include-summary/--include-projects options Add --format={text,json} to produce machine-readable output, and boolean options to control which sections are displayed: --include-summary / --no-include-summary (default: on) --include-projects / --no-include-projects (default: on) The JSON output respects the include flags, so callers can request only the fields they need (e.g. `repo info --format=json --no-include-projects` for manifest metadata only). Change-Id: I9641bc4023b630d9c61c5170eb86e5f3b787236f Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/569203 Commit-Queue: Carlos Fernandez Reviewed-by: Mike Frysinger Reviewed-by: Gavin Mak Reviewed-by: Carlos Fernandez Tested-by: Carlos Fernandez --- man/repo-info.1 | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) (limited to 'man') diff --git a/man/repo-info.1 b/man/repo-info.1 index 2cb25809e..b9941c7e9 100644 --- a/man/repo-info.1 +++ b/man/repo-info.1 @@ -1,10 +1,10 @@ .\" DO NOT MODIFY THIS FILE! It was generated by help2man. -.TH REPO "1" "July 2022" "repo info" "Repo Manual" +.TH REPO "1" "May 2026" "repo info" "Repo Manual" .SH NAME repo \- repo info - manual page for repo info .SH SYNOPSIS .B repo -\fI\,info \/\fR[\fI\,-dl\/\fR] [\fI\,-o \/\fR[\fI\,-c\/\fR]] [\fI\,\/\fR...] +\fI\,info \/\fR[\fI\,-dl\/\fR] [\fI\,-o \/\fR[\fI\,-c\/\fR]] [\fI\,--format=\/\fR] [\fI\,\/\fR...] .SH DESCRIPTION Summary .PP @@ -21,6 +21,18 @@ branches \fB\-o\fR, \fB\-\-overview\fR show overview of all local commits .TP +\fB\-\-include\-summary\fR +include manifest summary (default: true) +.TP +\fB\-\-no\-include\-summary\fR +exclude manifest summary +.TP +\fB\-\-include\-projects\fR +include project details (default: true) +.TP +\fB\-\-no\-include\-projects\fR +exclude project details +.TP \fB\-c\fR, \fB\-\-current\-branch\fR consider only checked out branches .TP @@ -29,6 +41,9 @@ consider all local branches .TP \fB\-l\fR, \fB\-\-local\-only\fR disable all remote operations +.TP +\fB\-\-format\fR=\fI\,FORMAT\/\fR +output format: text, json (default: text) .SS Logging options: .TP \fB\-v\fR, \fB\-\-verbose\fR -- cgit v1.2.3-54-g00ecf