← スキル一覧に戻る

git-log
by dudusoar
Code for sentiment analysis and topic modeling of public perceptions toward sidewalk delivery robots using YouTube comments (TRR 2025).
⭐ 0🍴 0📅 2026年1月9日
SKILL.md
name: git-log description: Git version control management for code commits, push operations, branch management, and maintaining git history records. Use when managing git operations in software projects, including committing code changes, pushing to remote repositories, viewing git logs, creating branches, and resolving merge conflicts.
Git Version Control Management Skill
This skill provides tools and workflows for managing git operations in software development projects. It supports code commits, push operations, branch management, and git history maintenance.
Quick Start
- Check git status: Review current changes before committing
- Stage changes: Add modified files to staging area
- Commit changes: Create commits with descriptive messages
- Push to remote: Upload commits to remote repository
- Review history: View git log to understand project history
Core Workflow
Committing Code Changes
When making code changes:
- Check current status:
git status - Stage files:
git add <file>orgit add . - Review staged changes:
git diff --cached - Commit with message:
git commit -m "Descriptive message" - Push to remote:
git push origin <branch>
Branch Management
For feature development:
- Create new branch:
git checkout -b feature/new-feature - Work on branch: Make commits on the feature branch
- Switch branches:
git checkout mainorgit checkout feature/new-feature - Merge branches:
git merge feature/new-feature(when ready) - Delete old branches:
git branch -d feature/old-feature
Git History Review
To understand project history:
- View commit history:
git log --oneline --graph --all - Check specific commit:
git show <commit-hash> - Compare branches:
git diff main..feature/new-feature - View file history:
git log --follow -p <file-path>
Remote Repository Operations
For collaboration:
- Check remote:
git remote -v - Fetch updates:
git fetch origin - Pull changes:
git pull origin main - Push changes:
git push origin <branch> - Set upstream:
git push -u origin <branch>(first push)
Common Git Patterns
Standard Commit Workflow
# 1. Check status
git status
# 2. Stage all changes
git add .
# 3. Commit with message
git commit -m "feat: add new feature"
# 4. Push to remote
git push origin main
Feature Branch Workflow
# 1. Create and switch to feature branch
git checkout -b feature/new-feature
# 2. Make changes and commit
git add .
git commit -m "feat: implement new feature"
# 3. Push feature branch
git push -u origin feature/new-feature
# 4. Merge to main (after review)
git checkout main
git pull origin main
git merge feature/new-feature
git push origin main
Git Log Analysis
# Compact view with graph
git log --oneline --graph --all
# Show recent commits with details
git log -5 --stat
# Search commits by message
git log --grep="bugfix"
# View commits by date
git log --since="2024-01-01" --until="2024-12-31"
Error Handling
Common Issues and Solutions
1. Commit Rejected (Non-Fast-Forward)
# Pull latest changes before pushing
git pull origin main --rebase
# Or force push (use with caution)
git push origin main --force
2. Merge Conflicts
# Resolve conflicts in files marked by <<<<<<<
# After resolving:
git add .
git commit -m "fix: resolve merge conflicts"
3. Accidental Commit
# Undo last commit (keep changes)
git reset --soft HEAD~1
# Undo last commit (discard changes)
git reset --hard HEAD~1
4. Wrong Branch Commits
# Stash changes
git stash
# Switch to correct branch
git checkout correct-branch
# Apply stashed changes
git stash pop
Best Practices
Commit Messages
- Use conventional commit format:
type(scope): description - Types: feat, fix, docs, style, refactor, test, chore
- Keep descriptions concise but descriptive
- Reference issues/tickets when applicable
Branch Strategy
main: Production-ready codedevelop: Integration branchfeature/*: New featuresbugfix/*: Bug fixesrelease/*: Release preparation
Git Hygiene
- Commit frequently with logical changes
- Keep commits focused on single purpose
- Write descriptive commit messages
- Review changes before committing
- Keep repository clean and organized
Resources
- Git Cheat Sheet: See
references/git-cheatsheet.mdfor common commands - Commit Examples: See
references/commit-examples.mdfor good commit messages - Branch Examples: See
references/branch-examples.mdfor branch management patterns - YouTube-SC Examples: See
examples/youtube-sc/for project-specific git workflows
When to Use This Skill
Use this skill when:
- Committing code changes to version control
- Managing git branches for feature development
- Pushing code to remote repositories
- Reviewing git history and understanding changes
- Resolving git conflicts and issues
- Maintaining clean git history and project structure
スコア
総合スコア
60/100
リポジトリの品質指標に基づく評価
✓SKILL.md
SKILL.mdファイルが含まれている
+20
○LICENSE
ライセンスが設定されている
0/10
✓説明文
100文字以上の説明がある
+10
○人気
GitHub Stars 100以上
0/15
○最近の活動
3ヶ月以内に更新がある
0/10
○フォーク
10回以上フォークされている
0/5
✓Issue管理
オープンIssueが50未満
+5
✓言語
プログラミング言語が設定されている
+5
○タグ
1つ以上のタグが設定されている
0/5
レビュー
💬
レビュー機能は近日公開予定です