Back to skills
SKILL.md
427 Git Commands B6a53e87
ASecurityUseful git commands when analysing, staging, and amending commits.
- 9 stars
- 0 votes
- 0 copies
- 0 views
- Added October 11, 2026
Security analysis
100/100npx -y skills add tools-only/X-Skills --skill 427-git-commands_b6a53e87 --agent claude-codeAre you the author of 427 Git Commands B6a53e87?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/tools-only-427-git-commands-b6a53e87)# Git Commands for Commit Workflows
Useful git commands when analysing, staging, and amending commits.
## Analysing changes
Review what is being committed:
```bash
# Show files changed
git status
# Show detailed changes
git diff --staged
# Show statistics
git diff --staged --stat
# Show changes for specific file
git diff --staged path/to/file
```
## Interactive staging
Use `git add -p` for selective staging:
```bash
# Stage changes interactively
git add -p
# Review what's staged
git diff --staged
# Commit with message
git commit -m "type(scope): description"
```
## Amending commits
Fix the last commit message:
```bash
# Amend commit message only
git commit --amend
# Amend and add more changes
git add forgotten-file.js
git commit --amend --no-edit
```
Attribution
Comments
Loading comments…