I was setting up an automated dev container setup the other night,
right, and the whole build just completely froze.
A third party Sentry MCP server popped up demanding an interactive menu prompt right
in the middle of a headless script.
Stalled the entire pipeline.
Ah, the classic interactive prompt trap in a headless environment.
But, speaking of smooth builds, this episode is brought to you by Jellypod AI,
the best way to turn your written content into natural audio podcasts.
Spot on.
And luckily, Claude Code version two point one point one hundred and eighty six
completely fixes that headache.
They added standalone CLI commands to authenticate a configured MCP server from your
shell without ever launching an interactive session.
Yeah, this is huge for automation!
Now you can literally just run claude mcp login sentry or claude mcp logout sentry
directly inside your Bash or zsh scripts.
It triggers the OAuth browser flow right from the command line,
no manual menu navigation required.
So if you are bootstrapping a fresh cloud environment or resetting credentials
across a dev team, you can just wrap those commands in a script and walk away to
grab a cuppa.
Exactly.
And that is not the only shell improvement in version two point one point one
hundred and eighty six.
They also tweaked the exclamation point prefix behavior.
If you run something like exclamation point npm test, the terminal output passes
directly to Claude for instant failure analysis.
Wait, so if my test suite throws a wobbly, Claude catches the standard output right
away?
What if I do not want Claude automatically reading every single terminal response
though?
You can turn it off!
Just set respondToBashCommands to false in your settings dot json file.
It gives you full control over when Claude intervenes.
Ah, fair dinkum.
And what about security?
Because if Claude is executing terminal commands, I would be a bit nervous about
sandboxed tools snooping around my local machine.
They thought of that too.
There is a new sandbox dot credentials rule that explicitly locks down sandboxed CLI
tools.
It stops them from harvesting your local API keys or SSH keys while running commands
in the sandbox.
Oh, that is a massive relief.
Though, I did hit a tiny snag when testing remote dev boxes.
If you run claude mcp login on a remote machine, you gotta make sure your local
browser callback ports are properly forwarded, or the OAuth redirect just spins
forever.
Right, port forwarding is key there.
Also, keep in mind how token retention works across session resets.
Oh, and if you ever accidentally wipe your context with a forward slash clear
command, you can use forward slash rewind to recover your session history!
Mate, forward slash rewind has saved my bacon more times than I care to admit.
Alright, that is the quick fix for today.
Happy coding, everyone.