Move getVersion line cleanup to main

This was catching comments of the format "Chart version for package:".
By moving the line cleanup (remove comments, prune whitespace) to be
before the case statement, we can be sure that comments won't trigger
the case statement, and that whitespace added before the colon for
aesthetic reasons don't need to be accounted for with a wildcard in
the glob.

Signed-off-by: Eric Ball <eball@linuxfoundation.org>
Change-Id: I3f0a4c979d6da4e17bd65b3423f77df0c93fe47a
1 file changed