[BUG] Login shell is not configurable

Resolved 💬 3 comments Opened Nov 19, 2025 by xim Closed Nov 19, 2025

Preflight Checklist

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report (please file separate reports for different bugs)
  • [x] I am using the latest version of Claude Code

What's Wrong?

When bash (or other shell) is invoked by claude, it is run as a login shell. In my case, the shell is zsh and that ends up calling .zlogin (and in bash, .bash_profile & al) which in my case prints some stuff.

IMO these shells shouldn't be login shells. I'd love it if that were configurable. Barring that, allowing me to override the shell used would help. (I could set it to bash, and empty my .bash_profile since I don't use bash anyway.)

What Should Happen?

E.g. when Claude decides to invoke git diff it should do so without the garbage that potentially comes from running a login shell (in my case, a tmux status thing)

● Bash(git diff apps/circadian_lighting/__init__.py)
  ⎿  0: 4 windows (created Tue Nov 11 19:09:55 2025) (attached)
     diff --git a/foo.py b/foo.py
     index 4e49704..3c222f0 100644
     … +6 lines (ctrl+o to expand)

Error Messages/Logs

Steps to Reproduce

Have zsh configured as shell, add a line to .zlogin that prints something.

Claude Model

Sonnet (default)

Is this a regression?

I don't know

Last Working Version

_No response_

Claude Code Version

v2.0.44

Platform

Anthropic API

Operating System

Ubuntu/Debian Linux

Terminal/Shell

Other

Additional Information

_No response_

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗