{"slug": "i-built-gitx-to-turn-messy-ai-generated-changes-into-clean-git-history", "title": "I built GitX to turn messy AI-generated changes into clean Git history", "summary": "A developer built GitX, a portable Git workflow skill for AI coding agents that organizes messy AI-generated code changes into clean, logical commits. GitX inspects the working tree, proposes commit groupings via 'gitx plan', and supports the full Git workflow including branch creation, pull requests, issue handling, and conflict resolution, while being conservative to avoid dangerous operations.", "body_md": "AI coding agents are great at changing code.\n\nBut after a long session with Codex, Claude Code, Cursor, or another coding agent, I often end up with something like this:\n\n```\n17 changed files\n```\n\nSome files belong to a feature.\n\nSome belong to a bug fix.\n\nSome are tests.\n\nSome are documentation.\n\nPutting everything into one commit works, but it usually creates messy Git history.\n\nSo I built **GitX**.\n\nGitX is a portable Git workflow skill for AI coding agents. It inspects your working tree, understands the changes, and helps organize them into clean, logical commits.\n\nOne of the commands I use most is:\n\n```\ngitx plan\n```\n\nIt analyzes the current changes and proposes how they should be grouped without creating any commits.\n\nFor example:\n\n```\n3 logical commits\n\nfeat(auth): add token refresh support\n\nfix(api): handle expired authentication sessions\n\ntest(auth): cover refresh token behavior\n```\n\nThis lets me review the plan before GitX changes anything.\n\nIf the plan looks good:\n\n```\ngitx\n```\n\nGitX creates Conventional Commit messages based on the actual changes.\n\nIf the working tree contains multiple logical groups, GitX can separate them instead of automatically putting unrelated changes into one large commit.\n\nI didn't want GitX to be only another commit-message generator.\n\nIt can also help with the rest of the Git workflow:\n\n```\ngitx status\ngitx tree\ngitx plan\ngitx check\n\ngitx branch\ngitx pull\ngitx push\n\ngitx pr\n\ngitx issue <description>\ngitx issue <number>\n\ngitx resolve\ngitx amend\n```\n\nFor example:\n\n```\ngitx check\n```\n\nGitX detects relevant project checks such as tests or linting and runs them before creating the commit.\n\n```\ngitx branch\n```\n\nGitX can infer an appropriate branch name and prefix such as `feat/`\n\n, `fix/`\n\n, `docs/`\n\n, or `refactor/`\n\n.\n\n```\ngitx pr\n```\n\nIt inspects the commits and changes, pushes the branch when needed, and creates a pull request with a generated title and summary.\n\nCreate an issue:\n\n```\ngitx issue Login fails after token expiry\n```\n\nOr ask your coding agent to work on an existing issue:\n\n```\ngitx issue 123\ngitx resolve\n```\n\nGitX can inspect an in-progress merge or rebase conflict, understand both sides of the change, resolve it, and run the relevant checks.\n\nGit automation can become dangerous quickly, so GitX is intentionally conservative.\n\nIt avoids force-pushing, doesn't push during a normal commit workflow, protects existing branches and working-tree changes, and warns before including files that may contain credentials, secrets, logs, or build artifacts.\n\nGitX follows the portable Agent Skills `SKILL.md`\n\nformat and is designed for compatible coding agents such as Codex, Claude Code, Cursor, and other Agent Skills-compatible tools.\n\nInstall it with:\n\n```\nnpx skills add musoyangrigor/gitx-skill --skill gitx\n```\n\nThen start with:\n\n```\ngitx plan\n```\n\nGitHub:\n\n[https://github.com/musoyangrigor/gitx-skill](https://github.com/musoyangrigor/gitx-skill)\n\nI'd especially like feedback from developers using AI coding agents on real projects.\n\nIf you try GitX, I'm curious about one thing:\n\n**Does gitx plan group your changes the way you would have grouped them yourself?**\n\nIf it doesn't, I'd love to hear about the case so I can improve it.", "url": "https://wpnews.pro/news/i-built-gitx-to-turn-messy-ai-generated-changes-into-clean-git-history", "canonical_source": "https://dev.to/musoyangrigor/i-built-gitx-to-turn-messy-ai-generated-changes-into-clean-git-history-1408", "published_at": "2026-08-11 19:46:10+00:00", "updated_at": "2026-08-11 20:18:45.506932+00:00", "lang": "en", "topics": ["developer-tools", "ai-agents", "ai-tools"], "entities": ["GitX", "Codex", "Claude Code", "Cursor", "musoyangrigor/gitx-skill"], "alternates": {"html": "https://wpnews.pro/news/i-built-gitx-to-turn-messy-ai-generated-changes-into-clean-git-history", "markdown": "https://wpnews.pro/news/i-built-gitx-to-turn-messy-ai-generated-changes-into-clean-git-history.md", "text": "https://wpnews.pro/news/i-built-gitx-to-turn-messy-ai-generated-changes-into-clean-git-history.txt", "jsonld": "https://wpnews.pro/news/i-built-gitx-to-turn-messy-ai-generated-changes-into-clean-git-history.jsonld"}}