diff options
Diffstat (limited to 'devdocs/git/git-for-each-repo.html')
| -rw-r--r-- | devdocs/git/git-for-each-repo.html | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/devdocs/git/git-for-each-repo.html b/devdocs/git/git-for-each-repo.html new file mode 100644 index 00000000..f904a74f --- /dev/null +++ b/devdocs/git/git-for-each-repo.html @@ -0,0 +1,6 @@ +<h1>git-for-each-repo</h1> <h2 id="_name">Name</h2> <div class="sectionbody"> <p>git-for-each-repo - Run a Git command on a list of repositories</p> </div> <h2 id="_synopsis">Synopsis</h2> <div class="sectionbody"> <div class="verseblock"> <pre class="content" data-language="shell">git for-each-repo --config=<config> [--] <arguments></pre> </div> </div> <h2 id="_description">Description</h2> <div class="sectionbody"> <p>Run a Git command on a list of repositories. The arguments after the known options or <code>--</code> indicator are used as the arguments for the Git subprocess.</p> <p>THIS COMMAND IS EXPERIMENTAL. THE BEHAVIOR MAY CHANGE.</p> <p>For example, we could run maintenance on each of a list of repositories stored in a <code>maintenance.repo</code> config variable using</p> <div class="listingblock"> <div class="content"> <pre data-language="shell">git for-each-repo --config=maintenance.repo maintenance run</pre> </div> </div> <p>This will run <code>git -C <repo> maintenance run</code> for each value <code><repo></code> in the multi-valued config variable <code>maintenance.repo</code>.</p> </div> <h2 id="_options">Options</h2> <div class="sectionbody"> <div class="dlist"> <dl> <dt class="hdlist1" id="Documentation/git-for-each-repo.txt---configltconfiggt"> --config=<config> </dt> <dd> <p>Use the given config variable as a multi-valued list storing absolute path names. Iterate on that list of paths to run the given arguments.</p> <p>These config values are loaded from system, global, and local Git config, as available. If <code>git for-each-repo</code> is run in a directory that is not a Git repository, then only the system and global config is used.</p> </dd> </dl> </div> </div> <h2 id="_subprocess_behavior">Subprocess behavior</h2> <div class="sectionbody"> <p>If any <code>git -C <repo> <arguments></code> subprocess returns a non-zero exit code, then the <code>git for-each-repo</code> process returns that exit code without running more subprocesses.</p> <p>Each <code>git -C <repo> <arguments></code> subprocess inherits the standard file descriptors <code>stdin</code>, <code>stdout</code>, and <code>stderr</code>.</p> </div><div class="_attribution"> + <p class="_attribution-p"> + © 2012–2024 Scott Chacon and others<br>Licensed under the MIT License.<br> + <a href="https://git-scm.com/docs/git-for-each-repo" class="_attribution-link">https://git-scm.com/docs/git-for-each-repo</a> + </p> +</div> |
