#compdef fan ## vim:ft=zsh ## fan completion ## Copyright (C) 2008 by Daniel Friesel ## License: WTFPL local arguments_thinkpad arguments_generic arguments_thinkpad=( '::fan level:(low med high auto)' ) arguments_generic=( ':fan state:(on off)' ) if [[ -w /proc/acpi/ibm/fan ]] { _arguments -s $arguments_thinkpad } elif [[ -w /proc/acpi/fan/FAN/state ]] { _arguments -s $arguments_generic }