Closed gforsyth closed 6 years ago
Also, hat-tip to @battaglia01 for noticing the disparate behavior between quote types!
Thanks @gforsyth and @battaglia01! This is great!
The last remaining bit of weirdness that I haven't tracked down yet is that the bash completer script always returns quoted paths using single quotes, no matter if the original explicit leading quote is single or double.
Yeah that is odd, but perhaps unsuprising :)
There were several issues popping up in xonsh that I traced back to here.
The current behavior of this code in xonsh right now is as follows:
Initially the leading double-quote seemed to work in xonsh but that is actually the bash completer failing completely and then xonsh falling back on to the path completer which works correctly for this completion. Wild.
If I directly import the
bash_completions
function in the same test directory with that folder name and call it directly:Note that the double-quoted lead returns nothing. Also, the single-quoted lead says that the number of characters to strip off of the prefix is 1, which will leave a leading
't
as evidenced above.So, two main fixes in here:
The last remaining bit of weirdness that I haven't tracked down yet is that the bash completer script always returns quoted paths using single quotes, no matter if the original explicit leading quote is single or double.
That said, this is still an improvement and also seems to fix some of the weird readline issues we were seeing, too.