Your message dated Sun, 28 Apr 2024 20:57:12 +0200
with message-id <d046e2ce-52e6-423d-ab80-a194b1313...@svario.it>
and subject line Re: Bug#935905: bash: ":?xxx" filename broken on autocomplete
has caused the Debian Bug report #935905,
regarding bash: ":?xxx" filename broken on autocomplete
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact ow...@bugs.debian.org
immediately.)


-- 
935905: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=935905
Debian Bug Tracking System
Contact ow...@bugs.debian.org with problems
--- Begin Message ---
Package: bash
Version: 5.0-4
Severity: normal

With the default setting

    complete -F _longopt rm

the autocompletion is broken on filenames or directories with ":?" at the 
beginning.

    # mkdir ':?aa'
    # rmdir :<tab>

gives me

    # rmdir :\:\?

which doesn't match the filename; I can finish completion by entering "aa", 
but then "rm" rejects this name.


-- System Information:
Debian Release: 10.0
  APT prefers testing
  APT policy: (990, 'testing'), (500, 'testing-debug'), (500, 'unstable'), (1, 
'experimental')
Architecture: amd64 (x86_64)

Kernel: Linux 5.0.0-trunk-amd64 (SMP w/8 CPU cores)
Kernel taint flags: TAINT_WARN
Locale: LANG=de_AT.UTF-8, LC_CTYPE=de_AT.UTF-8 (charmap=UTF-8), 
LANGUAGE=de_AT:de (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages bash depends on:
ii  base-files   10.3
ii  debianutils  4.8.6.1
ii  libc6        2.28-10
ii  libtinfo6    6.1+20181013-2

Versions of packages bash recommends:
ii  bash-completion  1:2.8-6

Versions of packages bash suggests:
pn  bash-doc  <none>

-- no debconf information

-- 

--- End Message ---
--- Begin Message ---
Control: tags -1 wontfix

On Tue, 27 Aug 2019 16:36:03 +0200 Philipp Marek <phil...@marek.priv.at> wrote:
With the default setting

    complete -F _longopt rm

the autocompletion is broken on filenames or directories with ":?" at the beginning.

    # mkdir ':?aa'
    # rmdir :<tab>

gives me

    # rmdir :\:\?

which doesn't match the filename; I can finish completion by entering "aa", but then "rm" rejects this name.

As pointed out by Andreas Schwab in the thread at <https://lists.gnu.org/archive/html/bug-bash/2024-04/msg00181.html>, `:` is in $COMP_WORDBREAKS.

This means that the initial `:` is not considered as the first character of the word to be completed, but rather as a separator that restarts the completion logic.

`:` must be escaped to make the completion logic consider it as a normal character:

    $ rmdir \:<TAB>
    $ rmdir \:\?aa

Regards,

--
Gioele Barabucci

--- End Message ---

Reply via email to