LINBIT / linstor-client

Python client for LINSTOR
https://docs.linbit.com/docs/linstor-guide/
GNU General Public License v3.0
22 stars 10 forks source link

bash_completion missing from Ubuntu packages #44

Closed candlerb closed 3 years ago

candlerb commented 3 years ago

According to https://www.linbit.com/drbd-user-guide/linstor-guide-1_0-en/#_from_the_command_line

If tab-completion does not work out of the box, please try to source the appropriate file:

# source /etc/bash_completion.d/linstor # or # source /usr/share/bash_completion/completions/linstor

However these files don't appear to exist in any of the linstor packages:

root@node1:~# ls /etc/bash_completion.d/linstor /usr/share/bash-completion/completions/linstor
ls: cannot access '/etc/bash_completion.d/linstor': No such file or directory
ls: cannot access '/usr/share/bash-completion/completions/linstor': No such file or directory

root@node1:~# dpkg-query -l | grep linstor
ii  linstor-client                   1.6.1-1ppa1~bionic1                         all          Linstor client command line tool
ii  linstor-common                   1.11.1-1ppa1~bionic1                        all          DRBD distributed resource management utility
ii  linstor-controller               1.11.1-1ppa1~bionic1                        all          DRBD distributed resource management utility
ii  linstor-satellite                1.11.1-1ppa1~bionic1                        all          DRBD distributed resource management utility
ii  python-linstor                   1.6.0-1ppa1~bionic1                         all          Linstor python api library
root@node1:~# dpkg-query -L linstor-client | grep -i bash
root@node1:~# dpkg-query -L linstor-common | grep -i bash
root@node1:~# dpkg-query -L linstor-controller | grep -i bash
root@node1:~# dpkg-query -L linstor-satellite | grep -i bash
root@node1:~# apt-cache search linstor
linstor-client - Linstor client command line tool
linstor-common - DRBD distributed resource management utility
linstor-controller - DRBD distributed resource management utility
linstor-satellite - DRBD distributed resource management utility
python-linstor - Linstor python api library
root@node1:~#

I did however find it in the linstor-client repo - and it has been there since the initial commit in 2017. I think it's some sort of packaging issue.

Workaround

curl -Ss https://raw.githubusercontent.com/LINBIT/linstor-client/master/scripts/bash_completion/linstor \
     -o /etc/bash_completion.d/linstor
rp- commented 3 years ago

Thanks for the report, should be fixed in the next release

candlerb commented 3 years ago

This is fixed in linstor-client 1.7.1

root@node1:~# dpkg-query -S /etc/bash_completion.d/linstor
linstor-client: /etc/bash_completion.d/linstor