diff --git a/completions/xrandr b/completions/xrandr index 643b11f5..5ce85f7e 100644 --- a/completions/xrandr +++ b/completions/xrandr @@ -21,7 +21,8 @@ _xrandr() done if [[ $output ]]; then local modes=$( xrandr | sed -e "1,/$output/ d" \ - -e "/connected/,$ d" | awk '{print $1}' ) + -e "/connected/,$ d" \ + -e "s/\([^[:space:]]\)[[:space:]].*/\1/" ) COMPREPLY=( $( compgen -W "$modes" -- "$cur" ) ) fi return