This is breaking
alias f='git flow feature'
complete -F __git_flow_feature f
-bash: [: 1: unary operator expected
It works for me, when I do:
Anyhow, the most common reason for the "[: 1: unary operator expected" error is that you have in the shell script code like:
if [ 1 = $MYVAL ]
MYVAL is not set. Inspect your completion functions. You can add
set -x to debug it.
Usually the easiest solution is to quote the variable so the operator will get the empty argument, but will have correct number of arguments:
if [ 1 = "$MYVAL" ]