On Fri, Feb 02, 2024 at 03:39:54PM +0100, Mike Jonkmans wrote: > [ mkdir test; cd test; touch file1 file2 ] > > Going into `vi-command' mode on the line `ls *' puts the cursor on the `*'. > Then `glob-expand-word' does nothing with the `*', it just inserts a space. > Resulting in `ls *' (cursor still on `*'). > Expected: nothing happens.
I'm not sure what keystrokes you're actually using, or what bind calls you've done leading up to this, but in a vanilla instance of bash with nothing done except 'set -o vi', typing l s space * esc * will replace the * with file1 file2 and another space, and also puts you in insert mode for some reason. Probably historical.