Skip to main content
added 411 characters in body
Source Link
Craig Hicks
  • 756
  • 8
  • 14

EDIT: After playing around with the [CTRL]{{ method described in this answer, I found it complete and was (sometimes) able to be followed by the default completion function to add more files. However, there was no way to continue with the original _foo_completion function after that, which may or may not be a limitation depending on the usage case.

EDIT: After playing around with the [CTRL]{{ method described in this answer, I found it complete and was (sometimes) able to be followed by the default completion function to add more files. However, there was no way to continue with the original _foo_completion function after that, which may or may not be a limitation depending on the usage case.

added 288 characters in body
Source Link
Craig Hicks
  • 756
  • 8
  • 14

I provide an answerdiagnostics tool which enables the OP to directly observe the behavior of line completion after tab, and for comparison, the behavior of parsing after return. After observation and analysis, we may conclude that while writing a line completion function to complete curly brackets function might be possible - it would be pointless due to bash's limitation of suppressing any further line completion functionality after the curly brackets.

I provide an answer which enables the OP to directly observe the behavior of line completion after tab, and for comparison, the behavior of parsing after return.

I provide diagnostics tool which enables the OP to directly observe the behavior of line completion after tab, and for comparison, the behavior of parsing after return. After observation and analysis, we may conclude that while writing a line completion function to complete curly brackets function might be possible - it would be pointless due to bash's limitation of suppressing any further line completion functionality after the curly brackets.

added 133 characters in body
Source Link
Craig Hicks
  • 756
  • 8
  • 14

seems to support thatthe thesis that it's not worth supporting curlies in a line completion function until/unless bash doesn't suppress line completion after curlies.

seems to support that thesis.

seems to support the thesis that it's not worth supporting curlies in a line completion function until/unless bash doesn't suppress line completion after curlies.

Source Link
Craig Hicks
  • 756
  • 8
  • 14
Loading