Вы можете использовать метод Attribute.IsDefined
https://msdn.microsoft.com/en-us/library/system.attribute.isdefined (v = vs.110). aspx
if(Attribute.IsDefined([YourProperty],typeof([YourAttribute])))
{
//Conditional execution...
}
Вы можете указать свойство, которое вы специально ищете, или вы можете перебирать все из них с помощью отражения, например:
PropertyInfo[] props = typeof([YourClass]).GetProperties();
Для сравнения текущей ветки с главной
ветвью:
$ git diff --name-status master
Для сравнения любых двух ветвей:
$ git diff --name-status firstbranch..yourBranchName
Читайте дальше git diff
в официальной документации .
Note that git makes it easy to just try out the merge and back away from any problems if you don't like the result. It might be easier than looking for potential problems in advance.