This should be leveraged by
repo.Lookup()
repo.Commits.QueryBy()
- ...
and more generally by any method bearing a parameter named shaOrReferenceName.
In order to make the API a bit more explicit, this last parameter should be renamed commitish, treeish... in order to hint the consumer about the type of the expected resolved object.
Beside the Extended Sha syntax, it may be useful to expose as well, whenever possible, an overload which accepts an ObjectId. The ObjectId based method would be part of the concrete type, whereas the string based Extended Sha method would be converted into an extension method.
This should be leveraged by
repo.Lookup()repo.Commits.QueryBy()and more generally by any method bearing a parameter named
shaOrReferenceName.In order to make the API a bit more explicit, this last parameter should be renamed
commitish,treeish... in order to hint the consumer about the type of the expected resolved object.Beside the Extended Sha syntax, it may be useful to expose as well, whenever possible, an overload which accepts an
ObjectId. TheObjectIdbased method would be part of the concrete type, whereas the string based Extended Sha method would be converted into an extension method.