File tree Expand file tree Collapse file tree 2 files changed +13
-12
lines changed
src/GitVersion.Core/VersionCalculation Expand file tree Collapse file tree 2 files changed +13
-12
lines changed Original file line number Diff line number Diff line change @@ -35,21 +35,22 @@ private bool IsMatch(string path)
35
35
public bool Exclude ( ICommit ? commit , [ NotNullWhen ( true ) ] out string ? reason )
36
36
{
37
37
reason = null ;
38
+ if ( commit == null )
39
+ {
40
+ return false ;
41
+ }
38
42
39
- if ( commit != null )
43
+ switch ( mode )
40
44
{
41
- switch ( mode )
42
- {
43
- case PathFilterMode . Inclusive :
45
+ case PathFilterMode . Inclusive :
46
+ {
47
+ if ( commit . DiffPaths . All ( this . IsMatch ) )
44
48
{
45
- if ( commit . DiffPaths . All ( this . IsMatch ) )
46
- {
47
- reason = "Source was ignored due to all commit paths matching ignore regex" ;
48
- return true ;
49
- }
50
- break ;
49
+ reason = "Source was ignored due to all commit paths matching ignore regex" ;
50
+ return true ;
51
51
}
52
- }
52
+ break ;
53
+ }
53
54
}
54
55
55
56
return false ;
Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ public IEnumerable<BaseVersion> GetBaseVersions(EffectiveBranchConfiguration con
18
18
{
19
19
configuration . NotNull ( ) ;
20
20
21
- if ( ! this . Context . Configuration . VersionStrategy . HasFlag ( VersionStrategies . ConfiguredNextVersion ) )
21
+ if ( ! Context . Configuration . VersionStrategy . HasFlag ( VersionStrategies . ConfiguredNextVersion ) )
22
22
yield break ;
23
23
24
24
var nextVersion = Context . Configuration . NextVersion ;
You can’t perform that action at this time.
0 commit comments