Machine: _get_comp_words_by_ref missing

Created on 26 Jan 2017  路  4Comments  路  Source: docker/machine

Hi docker-machine authors,
I was trying out the bash completion scripts. After adding
docker-machine.bash
docker-machine-prompt.bash
to ~/.bashrc and "source" them, this error was thrown:

$ docker-machine -bash: _get_comp_words_by_ref: command not found
-bash: ((: i < : syntax error: operand expected (error token is " ")
-bash: _get_comp_words_by_ref: command not found
-bash: ((: i < : syntax error: operand expected (error token is " ")

I searched for _get_comp_words_by_ref in this repository, but only a usage was found. It might have been removed, I guess. Do you guys still have that function by any chance?

Most helpful comment

_get_comp_words_by_ref is a function provided by the _bash-completion_ package.

Possible causes for your error message would be

  • _bash-completion_ is not installed
  • _bash-completion_ is not invoked from your login scripts
  • you source the completion files before _bash-completion_ is initialized

All 4 comments

_get_comp_words_by_ref is a function provided by the _bash-completion_ package.

Possible causes for your error message would be

  • _bash-completion_ is not installed
  • _bash-completion_ is not invoked from your login scripts
  • you source the completion files before _bash-completion_ is initialized

Thanks @albers . I'm going to close the issue as I think it's related to installation issues

source /etc/profile if you aren't already (i.e.: when using bash with alpine).

source /etc/profile if you aren't already (i.e.: when using bash with alpine).

This worked for bash with centos too.
thanks!

Was this page helpful?
0 / 5 - 0 ratings