From 493c7e087981036ae2db67eb5b8e86db80b77917 Mon Sep 17 00:00:00 2001 From: Frank Terbeck Date: Sun, 1 May 2016 15:27:32 +0200 Subject: 38388: Refactor baud rate completion This adds a new helper function _baudrate and uses it in place of private solutions in various existing completions. --- Completion/Unix/Command/_gdb | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'Completion/Unix/Command/_gdb') diff --git a/Completion/Unix/Command/_gdb b/Completion/Unix/Command/_gdb index e9c333925..d5eed5ae4 100644 --- a/Completion/Unix/Command/_gdb +++ b/Completion/Unix/Command/_gdb @@ -37,9 +37,7 @@ else (-[csx]) _files && return 0 ;; (-e) _description files expl executable _files "$expl[@]" -g '*(-*)' && return 0 ;; - (-b) _wanted -V values expl 'baud rate' \ - compadd 0 50 75 110 134 150 200 300 600 1200 1800 2400 4800 \ - 9600 19200 38400 57600 115200 230400 && return 0 ;; + (-b) _baudrate && return 0 ;; esac w=( "${(@)words[2,-1]}" ) -- cgit 1.4.1