Skip to content

Commit 5ee62f0

Browse files
committed
Merge branch 'master' into release/3.0.0
2 parents 136f85b + da9fa21 commit 5ee62f0

File tree

5 files changed

+43
-7
lines changed

5 files changed

+43
-7
lines changed

GitVersionCore/Helpers/ProcessHelper.cs

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ public static Process Start(ProcessStartInfo startInfo)
3636
startInfo.FileName,
3737
exception);
3838
}
39-
39+
4040
throw;
4141
}
4242
}
@@ -70,8 +70,14 @@ public static int Run(Action<string> output, Action<string> errorOutput, TextRea
7070
};
7171
foreach (var environmentalVariable in environmentalVariables)
7272
{
73-
if (!psi.EnvironmentVariables.ContainsKey(environmentalVariable.Key) && environmentalVariable.Value != null)
73+
if (psi.EnvironmentVariables.ContainsKey(environmentalVariable.Key))
74+
{
75+
psi.EnvironmentVariables[environmentalVariable.Key] = environmentalVariable.Value;
76+
}
77+
else
78+
{
7479
psi.EnvironmentVariables.Add(environmentalVariable.Key, environmentalVariable.Value);
80+
}
7581
if (psi.EnvironmentVariables.ContainsKey(environmentalVariable.Key) && environmentalVariable.Value == null)
7682
psi.EnvironmentVariables.Remove(environmentalVariable.Key);
7783
}

GitVersionExe.Tests/GitVersionHelper.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,8 @@ static ExecutionResults ExecuteIn(ArgumentBuilder arguments)
3232
var environmentalVariables =
3333
new[]
3434
{
35-
new KeyValuePair<string, string>("TEAMCITY_VERSION", arguments.IsTeamCity ? "8.0.0" : null)
35+
new KeyValuePair<string, string>("TEAMCITY_VERSION", arguments.IsTeamCity ? "8.0.0" : null),
36+
new KeyValuePair<string, string>("APPVEYOR", null)
3637
};
3738

3839
var exitCode = ProcessHelper.Run(

GitVersionExe/AssemblyInfoFileUpdate.cs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ namespace GitVersion
33
using System;
44
using System.Collections.Generic;
55
using System.IO;
6+
using System.Linq;
67
using GitVersion.Helpers;
78

89
class AssemblyInfoFileUpdate : IDisposable
@@ -56,7 +57,8 @@ static IEnumerable<string> GetAssemblyInfoFiles(string workingDirectory, Argumen
5657
}
5758
}
5859

59-
return fileSystem.DirectoryGetFiles(workingDirectory, "AssemblyInfo.cs", SearchOption.AllDirectories);
60+
return fileSystem.DirectoryGetFiles(workingDirectory, "AssemblyInfo.*", SearchOption.AllDirectories)
61+
.Where(f => f.EndsWith(".cs", StringComparison.OrdinalIgnoreCase) || f.EndsWith(".vb", StringComparison.OrdinalIgnoreCase));
6062
}
6163

6264
public void Dispose()

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ Those of you who have tried to do SemVer with Octopus Deploy or consume CI packa
6060
the problem that the SemVer version does not change each commit.
6161

6262
By default GitVersion is setup for *continuous delivery*, meaning that when you want to release you publish the artifact attached to
63-
your CI Build ([read more about what this means](https://github.com/ParticularLabs/GitVersion/wiki/Continuous-Delivery-Mode)).
63+
your CI Build ([read more about what this means](https://github.com/GitTools/GitVersion/wiki/Continuous-Delivery-Mode)).
6464

6565
If you want to consume packages from you CI server, for instance Octopus Deploy is looking at TeamCity's NuGet feed then you want GitVersion's *continuous deployment mode*.
6666
See the [Configuration](#configuration)
@@ -193,7 +193,7 @@ GitVersion has multiple ways it can be consumed.
193193
We have a bunch of examples in our Uncyclo, if something is missing, let us know! There are examples for GitHubFlow and GitFlow
194194

195195
### Who is using GitVersion?
196-
Find a list of projects who are currently using GitVersion [here](https://github.com/ParticularLabs/GitVersion/wiki/Who-is-using-GitVersion%3F)
196+
Find a list of projects who are currently using GitVersion [here](https://github.com/GitTools/GitVersion/wiki/Who-is-using-GitVersion%3F)
197197

198198
## Additional Links
199199

@@ -207,7 +207,7 @@ Find a list of projects who are currently using GitVersion [here](https://github
207207

208208
Have questions? Come join in the chat room:
209209

210-
[![Gitter](https://badges.gitter.im/Join Chat.svg)](https://gitter.im/ParticularLabs/GitVersion?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
210+
[![Gitter](https://badges.gitter.im/Join Chat.svg)](https://gitter.im/GitTools/GitVersion?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
211211

212212
## Icon
213213
<a href="http://thenounproject.com/noun/tree/#icon-No13389" target="_blank">Tree</a> designed by <a href="http://thenounproject.com/david.chapman" target="_blank">David Chapman</a> from The Noun Project

appveyor.yml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
assembly_info:
2+
patch: false
3+
4+
platform:
5+
- Any CPU
6+
7+
configuration:
8+
- Debug
9+
10+
build_script:
11+
- cmd: nuget restore
12+
13+
- cmd: msbuild GitVersion.sln "/p:Configuration=%CONFIGURATION%;Platform=%PLATFORM%"
14+
- ps: .\NuGetCommandLineBuild\Tools\GitVersion.exe /l console /output buildserver /updateAssemblyInfo
15+
- cmd: msbuild GitVersion.sln "/p:Configuration=%CONFIGURATION%;Platform=%PLATFORM%"
16+
17+
- cmd: appveyor PushArtifact "NuGetExeBuild/GitVersion.Portable.%GitVersion_NuGetVersion%.nupkg"
18+
19+
- cmd: appveyor PushArtifact "NuGetCommandLineBuild/GitVersion.CommandLine.%GitVersion_NuGetVersion%.nupkg"
20+
- cmd: appveyor PushArtifact "NuGetRefBuild/GitVersion.%GitVersion_NuGetVersion%.nupkg"
21+
- cmd: appveyor PushArtifact "NuGetTaskBuild/GitVersionTask.%GitVersion_NuGetVersion%.nupkg"
22+
23+
- cmd: 7z a "GitVersion_%GitVersion_NuGetVersion%.zip" .\NuGetCommandLineBuild\Tools\*.*
24+
- cmd: appveyor PushArtifact "GitVersion_%GitVersion_NuGetVersion%.zip"
25+
26+
test_script:
27+
- nunit-console "GitVersionTask.Tests\bin\%CONFIGURATION%\GitVersionTask.Tests.dll" "GitVersionExe.Tests\bin\%CONFIGURATION%\GitVersionExe.Tests.dll" "GitVersionCore.Tests\bin\%CONFIGURATION%\GitVersionCore.Tests.dll" /noshadow

0 commit comments

Comments
 (0)