citool Git Command Guide
The git citool command launches an interactive graphical commit tool built with Tcl/Tk, providing a user-friendly interface for committing changes to a Git repository.
git citool Syntax:
Section titled “git citool Syntax:”git citool [<options>]Options:
Section titled “Options:”| Option | Description |
|---|---|
| —amend | Amend the HEAD commit instead of creating a new one |
| —nocommit | Stage the changes but do not create a commit |
| —signoff | Add a Signed-off-by trailer to the commit message |
| —no-signoff | Do not add a Signed-off-by trailer (default) |
| —allow-empty | Allow creating empty commits |
| —allow-empty-message | Allow creating commits with empty messages |
| —cleanup= | Choose cleanup method for commit messages (strip, whitespace, verbatim, scissors, default) |
| —untracked-files[= | Show untracked files (no, normal, all; default is normal) |
| —verbose | Verbose output |
| —quiet | Suppress status messages |
| —dry-run | Don’t actually run any commands |
Parameters:
Section titled “Parameters:”| Parameter | Description |
|---|---|
| None supported - citool operates on staged/unstaged changes | N/A |
git citool Command Samples:
Section titled “git citool Command Samples:”Launch the commit tool
Section titled “Launch the commit tool”git citoolOpens the graphical interface for staging and committing changes.
Amend the last commit
Section titled “Amend the last commit”git citool --amendOpens the tool with the previous commit’s message for editing and amending.
Stage changes without committing
Section titled “Stage changes without committing”git citool --nocommitOpens the interface to stage changes but doesn’t create the commit.
Create a signed-off commit
Section titled “Create a signed-off commit”git citool --signoffOpens the tool and will add a Signed-off-by trailer to the commit message.
Show all files including untracked
Section titled “Show all files including untracked”git citool --untracked-files=allLaunches the tool showing all files, including untracked ones.
How do I open the git commit tool graphically?
Section titled “How do I open the git commit tool graphically?”To open the git commit tool graphically, use:
git citoolHow can I amend a commit using citool?
Section titled “How can I amend a commit using citool?”To amend a commit using citool, run:
git citool --amendHow do I stage changes without committing in citool?
Section titled “How do I stage changes without committing in citool?”To stage changes without committing in citool, execute:
git citool --nocommitHow can I enable signoff for commits in citool?
Section titled “How can I enable signoff for commits in citool?”To enable signoff for commits in citool, use:
git citool --signoffHow do I show untracked files in citool?
Section titled “How do I show untracked files in citool?”To show untracked files in citool, run:
git citool --untracked-files=allApplications of the git citool command
Section titled “Applications of the git citool command”- Providing a graphical interface for developers preferring GUI over command line
- Interactive staging of file changes with patch visualization
- Committing large numbers of files with visual confirmation
- Training new Git users with a familiar interface
- Managing complex commits with selective staging
- Reviewing and amending commits with better readability