# ncs-project-git

`ncs-project-git` - For each package git repo, execute a git command

## Synopsis

`ncs-project git [OPTIONS]`

## Description

When developing a project which has many packages coming from remote git repositories, it is convenient to be able to run git commands over all those packages. For example, to display the latest diff or log entry in each and every package. This command makes it possible to do exactly this.

Note that the generated top project Makefile already contain two make targets (gstat and glog) to perform two very common functions for showing any changed but uncomitted files and for showing the last log entry. The same functions can be achieved with this command, although it may require some more typing, see the example below.

## Options

\`\`

> Any git command, including options.

## Examples

Show the latest log entry in each package.

```
  $ ncs-project git --no-pager log -n 1

  ------ Package: esc
  commit ccdf889f5fe46d92b5901c7faa9c749f500c68f9
  Author: Bill Smith <void@cisco.com>
  Date:   Wed Oct 14 10:46:38 2015 +0200

      Getting the latest model changes

  ------ Package: cisco-ios
  commit 05a221ab024108e311709d6491ba8526c31df0ed
  Merge: ea72b1e 82e281e
  Author: tailf-stash.gen@cisco.com <void@tail-f.com>
  Date:   Wed Oct 14 21:09:10 2015 +0200

      Merge pull request #8 in NED/cisco-ios

  ....
      
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://nso-docs.cisco.com/guides/nso-6.6/resources/man/ncs-project-git.1.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
