zsh-completion: remove use of 'head' with negative offset

Some systems - like OSX - don't come with a version of head that
supports a negative value for the -n flag. Such systems get a message
such as this when tab-completing ninja's -d flag:

    ninja -dhead: illegal line count -- -1

Using sed instead should be more universally supported.
Merge pull request #885 from frasercrmck/zsh_comp_modes

zsh-completion: remove use of 'head' with negative offset