Glenn Jackman's comment is correct - you are using vi-mode.
Some third-party prompts (e.g. from Oh-My-Fish or similar) enable it for some reason.
To switch back, usually executing fish_default_key_bindings
once interactively should suffice once you have deleted the offending line or package (search for fish_vi_key_bindings
).
Or, if you like vi-mode, you can add a binding. Create a function called fish_user_key_bindings
(e.g. with funced
).
The content should look like this
function fish_user_key_bindings
bind -M $mode $sequence $command
end
where "$command" here would be "backward-word". $mode would be the vi-mode you want the binding to be valid for, e.g. "insert" or "default" (what vi would call "normal" mode).
"$sequence" would be the text sequence that the terminal sends to fish whenever this key combination is pressed. Unfortunately they aren't standardized, so you need to figure out which it is on your system.
fish_key_reader
is useful here - execute it, press the combination and use what it tells you. On my terminal ctrl+left sends \e\[1\;5D
(and ctrl+right sends the same with C instead of D).