symfony.plugin.zsh 315 B

12345678910111213
  1. # symfony basic command completion
  2. _symfony_get_command_list () {
  3. php symfony | sed "1,/Available tasks/d" | awk 'BEGIN { cat=null; } /^[A-Za-z]+$/ { cat = $1; } /^ :[a-z]+/ { print cat $1; }'
  4. }
  5. _symfony () {
  6. if [ -f symfony ]; then
  7. compadd `_symfony_get_command_list`
  8. fi
  9. }
  10. compdef _symfony symfony