Auto Complete with vim snippets
There is a vim plugin called vim-snipmate that lets to auto complete a bunch of code for you. So you type some snippet trigger and hit <tab>
and that's it.
Also there is another vim plugin vim-snippets with a lot of snippets for a lot of languages or file types.
For example this snippet for if
in shell files:
snippet if
if [[ ${1:condition} ]]; then
${0:#statements}
fi