new helper functions:
- _usb_ids completes on USB ids - _pci_ids completes on PCI idsmaster
parent
9e08218fb9
commit
935295c280
|
@ -522,6 +522,22 @@ _count_args()
|
|||
done
|
||||
}
|
||||
|
||||
# This function complete on PCI IDs
|
||||
#
|
||||
_pci_ids()
|
||||
{
|
||||
COMPREPLY=( ${COMPREPLY[@]:-} \
|
||||
$( compgen -W "$( lspci -n | awk '{print $3}')" -- $cur ) )
|
||||
}
|
||||
|
||||
# This function complete on USB IDs
|
||||
#
|
||||
_usb_ids()
|
||||
{
|
||||
COMPREPLY=( ${COMPREPLY[@]:-} \
|
||||
$( compgen -W "$( lsusb | awk '{print $6}')" -- $cur ) )
|
||||
}
|
||||
|
||||
# start of section containing completion functions for bash built-ins
|
||||
|
||||
# bash alias completion
|
||||
|
|
Loading…
Reference in New Issue