[BUG] Auto update fish function alias error

Resolved 💬 3 comments Opened Sep 18, 2025 by cakeface Closed Sep 24, 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?

I keep getting the following error on my command line when I run claude

> claude
fish: Unknown command: /Users/rpollock/.claude/local/claude
- (line 1): 
function claude --wraps /Users/rpollock/.claude/local/claude --description 'alias claude=/Users/rpollock/.claude/local/claude';  /Users/rpollock/.claude/local/claude $argv
                                                                                                                                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^
in function 'claude'

This seems to happen after I install claude and I think an auto update runs. Immediately after installing claude it works fine on the command line.

What Should Happen?

Running from the command line should start claude, no error.

Error Messages/Logs

> claude
fish: Unknown command: /Users/rpollock/.claude/local/claude
- (line 1): 
function claude --wraps /Users/rpollock/.claude/local/claude --description 'alias claude=/Users/rpollock/.claude/local/claude';  /Users/rpollock/.claude/local/claude $argv
                                                                                                                                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^
in function 'claude'

Steps to Reproduce

I am using fish shell. I don't know if that's required for the bug. I have NPM and NodeJS from homebrew.

  1. Install using npm install -g @anthropic-ai/claude-code

1.1 Run claude, it works!

  1. Wait a while. I have not figured out how long.
  2. in a new terminal run claude, it does not work.

Claude Model

None

Is this a regression?

Yes, this worked in a previous version

Last Working Version

_No response_

Claude Code Version

1.0.117 (Claude Code)

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

IntelliJ IDEA terminal

Additional Information

This is reproducible in iterm and kitty terminal as well as IDEA.

I run functions -e claude and it fixes it until the function comes back.

In /status I see this

 System Diagnostics • /doctor
  ⚠  Config mismatch: running npm-global but config says local

but when I run /doctor nothing is changed.

View original on GitHub ↗

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