Package: qpdf
Version: 12.3.2-1
Severity: normal
X-Debbugs-Cc: [email protected]

Hello and thanks for maintaining qpdf!

I would like to point out that its bash completion seems to be totally
broken.

For instance:

    $ ls
    foo.pdf
    $ qpdf fo

if I now hit [Tab], I get the following awkward result:

    $ qpdf fo
    qpdf: an input file name is required
    
    For help:
      qpdf --help=usage       usage information
      qpdf --help=topic       help on a topic
      qpdf --help=--option    help on an option
      qpdf --help             general help and a topic list
    
    o.pdf

The problema seems to lie in the qpdf executable itself, which is
supposed to be able to generated its own bash completion code:

    $ dpkg -L qpdf | grep bash-completion
    /usr/share/bash-completion
    /usr/share/bash-completion/completions
    /usr/share/bash-completion/completions/qpdf
    $ cat /usr/share/bash-completion/completions/qpdf
    eval "$(/usr/bin/qpdf --completion-bash)"

but:

    $ /usr/bin/qpdf --completion-bash
    qpdf_completer() { '/usr/bin/qpdf'; }; complete -o bashdefault -o default 
-o nospace -F qpdf_completer qpdf

I am no expert of bash completion code, but the qpdf_completer()
function does not look like a working bash completion function...

What's wrong?
Is there anything I failed to understand?

Please clarify or fix the bug.


Thanks for your time and dedication!


-- System Information:
Debian Release: forky/sid
  APT prefers testing
  APT policy: (800, 'testing'), (500, 'unstable')
Architecture: amd64 (x86_64)

Kernel: Linux 6.18.5+deb14-amd64 (SMP w/4 CPU threads; PREEMPT)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8), 
LANGUAGE=en_US:en
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages qpdf depends on:
ii  libc6       2.42-11+b1
ii  libgcc-s1   15.2.0-12
ii  libqpdf30   12.3.2-1
ii  libstdc++6  15.2.0-12

qpdf recommends no packages.

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

-- no debconf information

Reply via email to