File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed
src/PostSharp.Engineering.BuildTools/Dependencies/Model Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -9,21 +9,22 @@ namespace PostSharp.Engineering.BuildTools.Dependencies.Model;
99public record CiBuildId ( int BuildNumber , string ? BuildTypeId ) : ICiBuildSpec
1010{
1111 // This is a hack to guess the build configuration from the BuildTypeId because this information is not available
12- // when we restore artifacts.
12+ // when we restore artifacts. It is only useful for Metalama.Compiler, all other products do not take the BuildConfiguration
13+ // into account.
1314 public BuildConfiguration BuildConfiguration
1415 {
1516 get
1617 {
1718 if ( this . BuildTypeId == null )
1819 {
19- throw new InvalidOperationException ( "BuildTypeId is null." ) ;
20+ return default ;
2021 }
2122
2223 var match = Regex . Match ( this . BuildTypeId , "_([A-Z][a-z]+)Build$" ) ;
2324
2425 if ( ! match . Success )
2526 {
26- throw new InvalidOperationException ( $ "BuildTypeId ' { this . BuildTypeId } ' cannot be parsed." ) ;
27+ return default ;
2728 }
2829
2930 return Enum . Parse < BuildConfiguration > ( match . Groups [ 1 ] . Value ) ;
You can’t perform that action at this time.
0 commit comments