inshellisense icon indicating copy to clipboard operation
inshellisense copied to clipboard

spaces on files/folder names are not escaped

Open thomasphansen opened this issue 5 months ago • 0 comments

Describe the bug Using bash. Consider a folder named "my backup". If I type "cd ", the autocomplete will show me the proper folder name, but when I select it, it will come without the escape character for the space (like "my\ backup"), causing the cd command to fail with the message "bash: cd: too many arguments".

To Reproduce Steps to reproduce the behavior:

  1. Create a folder in your current location called "my test"
  2. Start "is"
  3. type "cd "
  4. Select the option "my test"
  5. Press enter

Expected behavior Selecting the "my test" folder from "is" list should result in a properly escaped result, like "cd my\ test". The escape pattern should follow the same rules as when we press "tab" in a bash shell.

Environment

  • OS: Linux Mint 21.3
  • Output of is --version: 0.0.1-rc.16
  • Nodejs Version:20.15.0
  • Shell: bash
  • Shell Version: 5.1.16(1)-release (x86_64-pc-linux-gnu)

Additional context Add any other context about the problem here.

thomasphansen avatar Sep 22 '24 21:09 thomasphansen