tab completion for service command on debian
- by markus
I have two systems with debian squeeze installed. On one system when I type:
service <TAB>
it shows me all available service (from /etc/init.d)
on the other system it shows me all files from the current directory. Does anyone know which setting changes that behaviour ?
UPDATE:
The file /etc/bash_completion.d/service was missing. I copied it from the machine where it is working. If I type complete -p | grep service it shows me:
complete -F _service service
On the machine where it is not working that command shows me nothing. I executed complete -F _service service in the command line, after that, the command service <TAB> shows me:
service -su: completion: function `_service' not found
this function is defined in the service file I recently copied, for some reasons it can't be found ...