Allow Git::ObjectId to be turned into short strings

Sometimes (most of the time) we don't want all the 40 numbers of a full SHA. Instead of creating it fully and then cutting the unwanted part, allow to tell libGitWrap how much we want to.