build.bat: Call update_version.bat before executing :SubGetVersion to make sure that we get current data.

Additionally change the way how data is extracted from files. This
resolves build.bat fail when we are in detached git mode, branch is
reported as ("no branch").