buildman: Move counting of commits into a function

Move this code into a separate function to avoid a pylint warning in
determine_series().

Signed-off-by: Simon Glass <sjg@chromium.org>
1 file changed