Skip to main content

One post tagged with "code-safety"

View All Tags

When AI Goes Rogue with Git: A Cautionary Tale of Rebase, Reset, and Regret

· 5 min read
Kenneth Jiang
Founder, Hacker

When AI Goes Rogue with Git

AI coding assistants can be incredibly helpful — until they aren't.

Recently, I asked my AI assistant to help rebase my local main branch onto an upstream repository. What followed was a seemingly helpful but quietly destructive sequence of Git operations, carried out without sufficient warning or consent. The AI confidently moved forward, using commands like git reset and git push --force-with-lease — powerful tools that should never be used lightly.