Files
xen/tools/libxl/bash-completion
T
Wei Liu 1b86994afe libxl: clean up trailing whitespaces in code.
Commit exactly the results of running
   find \! -iname '*.txt' -type f -print0 | xargs -0 perl -p -i.bak -E 's/\s+\n/\n/'

Signed-off-by: Wei Liu <liuw@liuw.name>
Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
Committed: Ian Jackson <ian.jackson@eu.citrix.com>
2011-07-19 16:02:36 +01:00

22 lines
399 B
Bash

#!/bin/bash
# Copy this file to /etc/bash_completion.d/xl.sh
_xl()
{
local IFS=$'\n,'
local cur opts xl
COMPREPLY=()
cur="${COMP_WORDS[COMP_CWORD]}"
xl=xl
if [[ $COMP_CWORD == 1 ]] ; then
opts=`${xl} help 2>/dev/null | sed '1,4d' | awk '{print $1}' | sed 's/$/ ,/g'` && COMPREPLY=( $(compgen -W "${opts}" -- ${cur}) )
return 0
fi
return 0
}
complete -F _xl -o nospace -o default xl