Hide Forgot
Created attachment 539327 [details] Fix. bash-completion-1.3-6.fc16.noarch Steps to Reproduce: rpm -r /var/lib/mock/fedo<tab><tab> ... for some -i package.rpm Actual results: No completion. Expected results: Filename completion works.
But maybe the fix is wrong. rpm -i kernel-3.1.4-1.fc16.x86_6<tab><tab> works fine (for a local file kernel-3.1.4-1.fc16.x86_64.rpm) but even after the patch: rpm -r /var/lib/mock/fedora-16-x86_64/root -i ker<tab><tab> still does not work.
The fix is definitely correct, pushed upstream: http://anonscm.debian.org/gitweb/?p=bash-completion/bash-completion.git;a=commitdiff;h=86d0395fc5efbeef9aad8cc27e84270f7c59faa1 Why the latter example still doesn't work is just because rpm is a pretty complex command to complete properly and there's lots of room for improvement. Your example case would however work if given the other way around, i.e. "rpm -i ... -r ...". As a rule of thumb, specifying the operation (-i, -U, -e etc) first, then additional options tends to result in best completion results at the moment.