Skip to content

Commit 23a8106

Browse files
committed
Moved configuration files to Core
1 parent b77694a commit 23a8106

File tree

6 files changed

+36
-3
lines changed

6 files changed

+36
-3
lines changed
File renamed without changes.

GitVersionCore/GitVersionCore.csproj

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,8 +53,12 @@
5353
<SpecificVersion>False</SpecificVersion>
5454
<HintPath>..\Packages\Visualize.Fody.0.4.0.0\Lib\portable-net4+sl4+wp7+win8+MonoAndroid16+MonoTouch40\Visualize.dll</HintPath>
5555
</Reference>
56+
<Reference Include="YamlDotNet">
57+
<HintPath>..\packages\YamlDotNet.3.3.0\lib\net35\YamlDotNet.dll</HintPath>
58+
</Reference>
5659
</ItemGroup>
5760
<ItemGroup>
61+
<Compile Include="AssemblyVersioningScheme.cs" />
5862
<Compile Include="Authentication.cs" />
5963
<Compile Include="BuildServers\AppVeyor.cs" />
6064
<Compile Include="BuildServers\BuildServerBase.cs" />
@@ -64,6 +68,8 @@
6468
<Compile Include="BuildServers\IBuildServer.cs" />
6569
<Compile Include="BuildServers\MyGet.cs" />
6670
<Compile Include="BuildServers\TeamCity.cs" />
71+
<Compile Include="Configuration\Config.cs" />
72+
<Compile Include="Configuration\ConfigReader.cs" />
6773
<Compile Include="GitFlow\BranchFinders\BranchCommitDifferenceFinder.cs" />
6874
<Compile Include="GitFlow\BranchFinders\RecentTagVersionExtractor.cs" />
6975
<Compile Include="LastMinorVersionFinder.cs" />

GitVersionCore/SemanticVersion.cs

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,36 @@ public bool Equals(SemanticVersion obj)
3434
BuildMetaData == obj.BuildMetaData;
3535
}
3636

37+
public override bool Equals(object obj)
38+
{
39+
if (ReferenceEquals(null, obj))
40+
{
41+
return false;
42+
}
43+
if (ReferenceEquals(this, obj))
44+
{
45+
return true;
46+
}
47+
if (obj.GetType() != GetType())
48+
{
49+
return false;
50+
}
51+
return Equals((SemanticVersion)obj);
52+
}
53+
54+
public override int GetHashCode()
55+
{
56+
unchecked
57+
{
58+
var hashCode = Major;
59+
hashCode = (hashCode * 397) ^ Minor;
60+
hashCode = (hashCode * 397) ^ Patch;
61+
hashCode = (hashCode * 397) ^ (PreReleaseTag != null ? PreReleaseTag.GetHashCode() : 0);
62+
hashCode = (hashCode * 397) ^ (BuildMetaData != null ? BuildMetaData.GetHashCode() : 0);
63+
return hashCode;
64+
}
65+
}
66+
3767
public static bool operator ==(SemanticVersion v1, SemanticVersion v2)
3868
{
3969
if (ReferenceEquals(v1, null))

GitVersionTask/GitVersionTask.csproj

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -55,12 +55,9 @@
5555
</ItemGroup>
5656
<ItemGroup>
5757
<Compile Include="AssemblyInfoBuilder\AssemblyInfoBuilder.cs" />
58-
<Compile Include="AssemblyInfoBuilder\AssemblyVersioningScheme.cs" />
5958
<Compile Include="AssemblyInfoBuilder\AssemblyVersionsGenerator.cs" />
6059
<Compile Include="BuildLogger.cs" />
6160
<Compile Include="CachedVersion.cs" />
62-
<Compile Include="Config.cs" />
63-
<Compile Include="ConfigReader.cs" />
6461
<Compile Include="DirectoryDateFinder.cs" />
6562
<Compile Include="VersionCache.cs" />
6663
<Compile Include="WriteVersionInfoToBuildLog.cs" />

0 commit comments

Comments
 (0)