Git
Cogno’s Git panel shows the status of the Git repository for the currently focused terminal and lets you stage, unstage, commit, and inspect changes without leaving the terminal.
How it works
Section titled “How it works”The panel tracks the working directory of the active terminal. When that directory (or one of its parents) is a Git repository, the panel shows:
- The current branch name
- Staged changes, with a commit message box and a Commit button
- Unstaged changes and untracked files, including folders that can be expanded to show individual files
- A diff view for the selected file
Actions per file
Section titled “Actions per file”| Action | Description |
|---|---|
| Stage / unstage | Move a file (or a whole directory) between the staged and unstaged sections |
| Stage all / Unstage all | Stage or unstage every change at once |
| Discard changes | Revert a file to its last committed state (asks for confirmation) |
| Open in editor | Open the file in your default editor |
| View diff | Show the diff for the selected file below the file lists |
When the panel is unavailable
Section titled “When the panel is unavailable”The panel shows a status message instead of file lists when:
- No terminal is focused
- The focused terminal’s directory is not a Git repository
- Git is not installed or not on
PATH - The repository has no commits yet
- Reading the Git status failed
Configuration
Section titled “Configuration”| Setting | Default | Description |
|---|---|---|
git.mode | off | visible shows Git in the side menu, hidden keeps it available but hides it from the menu, off disables it |
See the Config page for the full reference.
Action
Section titled “Action”| Action | Description |
|---|---|
open_git | Toggle the Git panel |