Correctly translate all branches/tags/shas:
Correctly translate all branches/tags/shas:

The code which raises an error if two elements try
to install different versions of the same git repo
currently works correctly for SHAs, or if a branch
is specified first, followed by a SHA.

However it fails if two branches are specified, because
the shallow clone does not fetch all branch heads.

This change correctly handles any combination of
SHAs/branch-heads/tags.

Change-Id: I501e94150ddeb41b79588816576a5d7a06fa92aa

qwefi/tripleo-image-elements,NaohiroTamura/diskimage-builder,rdo-management/diskimage-builder,zioproto/diskimage-builder,qwefi/tripleo-image-elements,rdo-management/tripleo-image-elements,radez/tripleo-image-elements,qwefi/tripleo-image-elements,varunarya10/diskimage-builder,agroup/tripleo-puppet-elements,citrix-openstack-build/diskimage-builder,switch-ch/diskimage-builder,switch-ch/diskimage-builder,takahashinobuyuki/diskimage-builder,agroup/tripleo-puppet-elements,agroup/tripleo-puppet-elements,agroup/tripleo-puppet-elements,eantyshev/diskimage-builder,qwefi/tripleo-image-elements,openstack/tripleo-image-elements,openstack/diskimage-builder,varunarya10/diskimage-builder,citrix-openstack-build/diskimage-builder,radez/tripleo-image-elements,openstack/tripleo-image-elements,openstack/diskimage-builder,rdo-management/diskimage-builder,zioproto/diskimage-builder,JioCloud/diskimage-builder,rdo-management/tripleo-image-elements,qwefi/tripleo-image-elements,NaohiroTamura/diskimage-builder,eantyshev/diskimage-builder,takahashinobuyuki/diskimage-builder,CSC-IT-Center-for-Science/diskimage-builder,CSC-IT-Center-for-Science/diskimage-builder,JioCloud/diskimage-builder