The hard part isn't Git. It's knowing which machine you're standing on.
Working with GitHub through AI assistants adds a layer nobody warns you about: three filesystems, token scopes you discover at the finish line, and the ambient-context workaround that got me through.
I've worked with GitHub for years. This week it made me feel like a beginner again — not because Git changed, but because I now work with it through AI assistants, and that adds a layer nobody warns you about.
The honest version: I spent a good part of this week fighting my own setup instead of shipping. If your experience has been smoother, I'd genuinely like to hear how. Here's mine.
Friction one: which machine am I standing on?
When I work on a repository now, there are at least three computers involved. My Mac, where the "real" files live. The assistant's sandboxed environment, which sees a mounted copy of some folders at completely different paths. And sometimes a cloud session or a browser context with its own view of the world. Same repository, three filesystems, three sets of credentials.
Git can tell me the state of every branch. Nothing tells me which of these machines I'm currently acting on — until something fails. A path that works in one environment doesn't exist in the other. A push that worked yesterday fails today because this session isn't the one holding the key. I've been burned by this shape of problem before, when the database I could see wasn't the database that mattered — except now it's my own toolchain doing it.
Git tracks every version of my code. Nothing tracks which computer I'm on.
Friction two: rights you discover at the finish line
GitHub's fine-grained personal access tokens are the security model done right: fifty-plus granular permissions, scoped per repository, minimal by default. And that's exactly why they hurt: you find out what a token can't do at the worst possible moment. Mine could read and push code all week — then returned a hard 403 the moment the workflow needed to create a new repository, a permission nobody thinks about until it's missing.
The lesson isn't to hand out broader tokens. It's that token scopes are part of your project plan now: before an assistant-driven session, decide what the session will need to do — read, push, create, administer — and check that the credential can actually do it. Five minutes up front against an evening of confident tooling hitting a wall at step nine.
Friction three: every environment can do something the other can't
The strangest part is capability asymmetry. One environment can edit files but can't touch the browser. Another can fix things live in the browser but can't reach the repository. Deploys stall in the gap: the fix exists here, the deployment credential exists there, and I'm the messenger in between. It's the same class of infrastructure friction that once had my sessions hanging until I built a fix that runs every session — solvable, but you solve it yourself.
The workaround: make context ambient
What actually got me through: I stopped trusting any single environment to hold the truth, and made the context ambient instead. Repositories mirror to an always-online store, so whichever environment wakes up can read the current state. Project memory — decisions, runbooks, gotchas — lives in a structured knowledge base rather than in any machine's local state, some of it also in tools like mymind so it's reachable from anywhere. And credentials live in exactly one canonical place, read by exact path, never copied per environment — the one rule that has never once bitten me. When I let AI reorganise my whole workspace, this separation was the part that paid for itself.
Is it elegant? No. It's scaffolding around a gap the tools will eventually close. But it turns "which machine am I on?" from a blocking question into a boring one — the state is wherever I am.
The meta-lesson is familiar: the assistant executes brilliantly inside an environment; stitching environments together into a system that ships is still operator work. Far from ideal this week. Honest about it. Better next week.
Sources & further reading
External
- GitHub Docs: Managing your personal access tokens
- GitHub Docs: Permissions required for fine-grained personal access tokens
- GitHub Blog: Introducing fine-grained personal access tokens
Related posts
- I let AI reorganise my whole workspace. The dangerous moment was a find-and-replace.
- The database I could see wasn't the database that mattered
- Claude Cowork keeps hanging? Here's the fix that runs every session
- Beyond the junk drawer: mastering knowledge with progressive disclosure and AI
- The death of generic AI: why deep domain expertise is the only real leverage left