1#compdef apt-move 2 3local curcontext="$curcontext" state line cmds ret=1 4typeset -A opt_args 5 6_arguments -C \ 7 '-a[process all packages]' \ 8 '-c[specify an alternative configuration file]' \ 9 '-d[override the DIST setting]' \ 10 '-f[override the MAXDELETE setting]' \ 11 '-q[be quiet; suppress normal output]' \ 12 '-t[show what apt-move would do, but do not actually do anything]' \ 13 '1: :->cmds' \ 14 '*: :->args' && ret=0 15 16case $state in 17 cmds) 18 cmds=( 19 'get:update your master files from local apt' 20 'getlocal:alias of get' 21 'fsck:fix broken repositories' 22 'move:move cache files into mirror tree' 23 'movefile:move files into the repository' 24 'delete:delete obsolete packages' 25 'packages:create new local Packages files' 26 'update:alias for: get move delete packages' 27 'local:alias for: move delete packages' 28 'localupdate:alias for: getlocal move delete packages' 29 'mirror:update your local mirror from remote rsync site' 30 'sync:same as mirror, but only gets packages that you currently have installed on your system' 31 'exclude:prints a list of all packages EXCLUDED from the mirror by the .exclude file' 32 'listbin:prints lists of packages which can serve as the input to mirrorbin(mirror,sync,repo)' 33 'listsrc:same as listbin, but lists source packages' 34 'mirrorbin:same as mirror, but gets the packages specified on stdin' 35 'mirrorsrc:same as mirrorbin, but gets source packages' 36 ) 37 _describe -t commands 'apt-move command' cmds && ret=0 38 ;; 39 args) 40 case $line[1] in 41 get|getlocal) 42 _directories && ret=0 43 ;; 44 movefile) 45 _files -g "*.d(sc|eb)(-.)" && ret=0 46 ;; 47 listbin) 48 _wanted lists expl list compadd mirror sync repo 49 ;; 50 esac 51 ;; 52esac 53 54return ret 55