<< All versions
Skill v1.0.1
currentAutomated scan100/100kivo360/omoios/git-workflow
4 files
──Details
PublishedJune 26, 2026 at 07:31 PM
Content Hashsha256:f6a1d72ce6934a32...
Git SHA65d8f5eff4fd
Bump Typepatch
──Files
Files (1 file, 5.7 KB)
SKILL.md5.7 KBactive
SKILL.md · 295 lines · 5.7 KB
version: "1.0.1" description: Git branching, commits, and PR workflow following GitFlow conventions globs: [".git/", "/.gitignore"]
Git Workflow
Follow these conventions for all git operations.
Branch Naming
{type}/{ticket-id}-{short-description}
| Type | Purpose | Example | |
|---|---|---|---|
feature/ | New features | feature/TKT-123-user-auth | |
fix/ | Bug fixes | fix/TKT-456-login-error | |
hotfix/ | Production fixes | hotfix/TKT-789-security-patch | |
refactor/ | Code refactoring | refactor/TKT-101-cleanup-api | |
docs/ | Documentation | docs/TKT-102-api-docs | |
test/ | Test additions | test/TKT-103-unit-tests |
Commit Messages
Use conventional commits format:
{type}({scope}): {description}{body - optional}{footer - optional}
Types
feat: New featurefix: Bug fixrefactor: Code refactoring (no functional change)test: Adding or updating testsdocs: Documentation onlychore: Maintenance tasksstyle: Formatting, whitespace (no code change)perf: Performance improvement
Examples
bash
# Simple commitgit commit -m "feat(auth): add JWT token validation"# With bodygit commit -m "fix(api): handle null user in responseThe API was returning 500 when user was not found.Now returns 404 with proper error message.Fixes TKT-456"# Breaking changegit commit -m "feat(api)!: change response format to JSON:APIBREAKING CHANGE: Response format changed from custom to JSON:API spec.Migration guide: docs/migration/v2-response-format.md"
Workflow Commands
Starting Work
bash
# Create feature branch from maingit checkout maingit pull origin maingit checkout -b feature/TKT-123-feature-name# Or from develop for GitFlowgit checkout developgit pull origin developgit checkout -b feature/TKT-123-feature-name
During Development
bash
# Stage and commit changesgit add -Agit commit -m "feat(scope): description"# Keep branch updatedgit fetch origingit rebase origin/main # or origin/develop
Before PR
bash
# Ensure clean historygit rebase -i HEAD~{n} # Squash if needed# Push to remotegit push -u origin feature/TKT-123-feature-name
Pull Request Guidelines
PR Title
{type}({scope}): {description} [TKT-{num}]
Example: feat(auth): implement OAuth2 login [TKT-123]
PR Description Template
markdown
## Summary{1-2 sentence description of changes}## Changes-{Change 1}-{Change 2}## Testing-[ ] Unit tests pass-[ ] Integration tests pass-[ ] Manual testing completed## TicketCloses TKT-{num}## Screenshots (if UI changes){Add screenshots}
Common Operations
Amend Last Commit
bash
git add -Agit commit --amend --no-editgit push --force-with-lease
Undo Last Commit (keep changes)
bash
git reset --soft HEAD~1
Cherry-pick to Another Branch
bash
git checkout target-branchgit cherry-pick {commit-hash}
Clean Up Merged Branches
bash
git fetch -pgit branch --merged | grep -v main | xargs git branch -d
Pushing Code
Push to Remote
bash
# First push (set upstream)git push -u origin feature/TKT-123-feature-name# Subsequent pushesgit push# Force push (only on your own branches, never main!)git push --force-with-lease
After Making Changes
bash
# Stage, commit, push in one flowgit add -Agit commit -m "feat(scope): description"git push
Creating Pull Requests
Using GitHub CLI (Recommended)
bash
# Create PR with title and bodygh pr create --title "feat(auth): add login feature [TKT-123]" --body "## SummaryImplements user login with JWT authentication.## Changes- Add login endpoint- Add JWT token generation- Add auth middleware## Testing- [x] Unit tests pass- [x] Integration tests passCloses TKT-123"# Create PR interactivelygh pr create# Create draft PRgh pr create --draft# Create PR with reviewersgh pr create --reviewer @username1,@username2
Merging Pull Requests
Check PR Status First
bash
# View PR status and checksgh pr statusgh pr checks# View specific PRgh pr view 123
Merge Methods
bash
# Squash merge (recommended - clean history)gh pr merge --squash# Regular mergegh pr merge --merge# Rebase mergegh pr merge --rebase# Merge specific PR numbergh pr merge 123 --squash# Merge with custom commit messagegh pr merge --squash --subject "feat(auth): implement login [TKT-123]"# Auto-merge when checks passgh pr merge --auto --squash
Merge to Main (When Task is 100% Complete)
bash
# 1. Ensure all tests passgh pr checks# 2. Ensure PR is approved (if required)gh pr view --json reviews# 3. Merge the PRgh pr merge --squash --delete-branch# The --delete-branch flag cleans up the feature branch after merge
After Merge
bash
# Switch back to main and pull latestgit checkout maingit pull origin main# Clean up local branchesgit fetch -pgit branch --merged | grep -v main | xargs git branch -d
Handling Merge Conflicts
bash
# Update your branch with maingit fetch origingit rebase origin/main# If conflicts occur:# 1. Fix conflicts in files# 2. Stage resolved filesgit add <resolved-files># 3. Continue rebasegit rebase --continue# 4. Force push (safe on feature branches)git push --force-with-lease
Safety Rules
- Never force push to main/develop - Shared branches are protected
- Always use `--force-with-lease` - Safer than
--force - Rebase, don't merge - Keep history clean
- One concern per commit - Atomic changes
- Test before push - Run tests locally first
- Only merge when 100% complete - All tests passing, code reviewed
- Use --delete-branch on merge - Keep repo clean