File: bash-completion-atool_0.1-1

package info (click to toggle)
atool 0.37.0-3
  • links: PTS, VCS
  • area: main
  • in suites: squeeze
  • size: 576 kB
  • ctags: 46
  • sloc: perl: 1,769; sh: 619; makefile: 90
file content (26 lines) | stat: -rwxr-xr-x 688 bytes parent folder | download | duplicates (9)
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
# atool(1) completion by Roman G <chesercat@gmail.com>

_atool() 
{
	local cur

	COMPREPLY=()
	cur=${COMP_WORDS[COMP_CWORD]}

	case "$cur" in
	    -*)
		COMPREPLY=( $( compgen -W '-l -x -X -a -c- -d -r \
		-e -F -D -f -q -v -p -o -E -S --list --extract --extract-to= \
                --add --cat --diff --repack --each --format= --subdir --force \
                --quiet --verbose --page --null --explain --simulate --config=' -- $cur ) )
		;;
	    *)
		_filedir '@(rar|RAR|zip|ZIP|tar.gz|tgz|tar.bz|tbz|tar.Z|tZ|tar.lzo|tzo|tar.7z|t7z|tar|jar|JAR|war|lha|lzh|7z|ace|ACE|arj|ARJ|a|arc|ARC|rpm|deb|gz|bz|bz2|Z|lzo|cpio)'
		;;
	esac
  
	return 0

}
complete -F _atool -o filenames atool