Not compatible with bash-completion 2.14.0
An award-winning drawing program for children of all ages
Brought to you by:
wkendrick
On ever since I updated bash-completion to 2.14.0 (from 2.11) on my Arch system, I am getting the following while tuxpaint-completion.bash is loaded:
have: command not found
It's a bit odd though that this only happens with Czech and Slovak locales. After receiving the error the completion for tuxpaint is not working.
$ export LC_ALL=en_US.utf8
$ bash
$ # no error
$ export LC_ALL=sk_SK.utf8
$ bash
bash: have: príkaz nenájdený
(translates to command not found)
$ export LC_ALL=cs_CZ.utf8
$ bash
bash: have: příkaz nenalezen
(translates to command not found)
This may also be an issue of bash-completion itself - perhaps someone has an idea what's going on. For now the downgrade to 2.11 solves the problem.
Briefly Googling around it seems
havewas deprecated. I'm replacing it with_have. Can you try modifying yourtuxpaint-completion.bashin the same way and check that it works underbash-completion2.14? (I'm on Ubuntu 22.04 here, with 2.11, so unable to replicate it, even if I switch to e.g.cs_CZlocale.)https://sourceforge.net/p/tuxpaint/tuxpaint/ci/71959d502ef17e594ba69f3344c17119ea4c0416/
Hello William,
the problem on my system is as follows:
As can be observed
tuxpaint-completion.bashis sourced before000_bash_completion_compat.bashwhile it's the latter file that contains the definition of the_havefunction:I see two possible workarounds:
tuxpaint-completion.bashto010_tuxpaint-completion.bashto make sure it gets loaded afterbash_completion_comp_have_commandinstead of_have(as it seems to just be a wrapper around it:And the reason why you may get different output with different locales:
Last edit: Jozef Riha 2024-07-04
So this seems to have been a known bug in bash-completion (https://github.com/scop/bash-completion/issues/1207). That said, since it's obviously out in the wild and affecting people, I'll go with the rename route (
010_tuxpaint-completion.bash). Thanks!