Package: bash-completion / 1:2.1-4.3

09-aptitude_safe-upgrade.patch Patch series | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
From: Nicolas Le Cam <niko.lecam@gmail.com>
Subject: aptitude safe-upgrade accepts package names
Forwarded: no
Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=673235
Origin: vendor, https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=673235

---
 completions/aptitude |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

--- bash-completion.orig/completions/aptitude
+++ bash-completion/completions/aptitude
@@ -26,7 +26,7 @@ _aptitude()
 
     local special i
     for (( i=0; i < ${#words[@]}-1; i++ )); do
-        if [[ ${words[i]} == @(@(|re)install|@(|un)hold|@(|un)markauto|@(dist|full)-upgrade|download|show|forbid-version|purge|remove|changelog|why@(|-not)|keep@(|-all)|build-dep|@(add|remove)-user-tag|versions) ]]; then
+        if [[ ${words[i]} == @(@(|re)install|@(|un)hold|@(|un)markauto|@(dist|full|safe)-upgrade|download|show|forbid-version|purge|remove|changelog|why@(|-not)|keep@(|-all)|build-dep|@(add|remove)-user-tag|versions) ]]; then
             special=${words[i]}
         fi
         #exclude some mutually exclusive options
@@ -38,7 +38,7 @@ _aptitude()
        case $special in
            install|hold|markauto|unmarkauto|dist-upgrade|full-upgrade| \
            download|show|changelog|why|why-not|build-dep|add-user-tag| \
-           remove-user-tag|versions)
+           remove-user-tag|versions|safe-upgrade)
                COMPREPLY=( $( apt-cache pkgnames $cur 2> /dev/null ) )
                return 0
                ;;
@@ -56,7 +56,7 @@ _aptitude()
 
     case $prev in
         # don't complete anything if these options are found
-        autoclean|clean|forget-new|search|safe-upgrade|upgrade|update|keep-all)
+        autoclean|clean|forget-new|search|upgrade|update|keep-all)
             return 0
             ;;
         -S)