Respond to PR feedback.

This commit is contained in:
Eric Erhardt 2017-02-10 11:32:22 -06:00
parent 72af77de1b
commit 31ff72e62d
2 changed files with 5 additions and 5 deletions

View file

@ -22,7 +22,7 @@ namespace Microsoft.DotNet.Scripts
/// GITHUB_ORIGIN_OWNER - The owner of the GitHub fork to push the commit and create the PR from. (ex. "dotnet-bot")
/// GITHUB_UPSTREAM_OWNER - The owner of the GitHub base repo to create the PR to. (ex. "dotnet")
/// GITHUB_PROJECT - The repo name under the ORIGIN and UPSTREAM owners. (ex. "cli")
/// GITHUB_UPSTREAM_BRANCH - The branch in the GitHub base repo to create the PR to. (ex. "rel/1.0.0")
/// GITHUB_UPSTREAM_BRANCH - The branch in the GitHub base repo to create the PR to. (ex. "master")
/// GITHUB_PULL_REQUEST_NOTIFICATIONS - A semi-colon ';' separated list of GitHub users to notify on the PR.
/// </remarks>
public class Config
@ -37,7 +37,7 @@ namespace Microsoft.DotNet.Scripts
private Lazy<string> _coreSetupVersionUrl = new Lazy<string>(() => GetEnvironmentVariable("CORESETUP_VERSION_URL", "https://raw.githubusercontent.com/dotnet/versions/master/build-info/dotnet/core-setup/master"));
private Lazy<string> _gitHubUpstreamOwner = new Lazy<string>(() => GetEnvironmentVariable("GITHUB_UPSTREAM_OWNER", "dotnet"));
private Lazy<string> _gitHubProject = new Lazy<string>(() => GetEnvironmentVariable("GITHUB_PROJECT", "cli"));
private Lazy<string> _gitHubUpstreamBranch = new Lazy<string>(() => GetEnvironmentVariable("GITHUB_UPSTREAM_BRANCH", "rel/1.0.0"));
private Lazy<string> _gitHubUpstreamBranch = new Lazy<string>(() => GetEnvironmentVariable("GITHUB_UPSTREAM_BRANCH", "master"));
private Lazy<string[]> _gitHubPullRequestNotifications = new Lazy<string[]>(() =>
GetEnvironmentVariable("GITHUB_PULL_REQUEST_NOTIFICATIONS", "")
.Split(new[] { ';' }, StringSplitOptions.RemoveEmptyEntries));

View file

@ -29,9 +29,9 @@ namespace Microsoft.DotNet.Scripts
buildInfos.Add(BuildInfo.Get("CoreSetup", s_config.CoreSetupVersionUrl, fetchLatestReleaseFile: false));
IEnumerable<IDependencyUpdater> updaters = GetUpdaters();
var dependencyBuildInfos = buildInfos.Select(i =>
var dependencyBuildInfos = buildInfos.Select(buildInfo =>
new DependencyBuildInfo(
i,
buildInfo,
upgradeStableVersions: true,
disabledPackages: Enumerable.Empty<string>()));
DependencyUpdateResults updateResults = DependencyUpdateUtils.Update(updaters, dependencyBuildInfos);
@ -46,7 +46,7 @@ namespace Microsoft.DotNet.Scripts
string suggestedMessage = updateResults.GetSuggestedCommitMessage();
string body = string.Empty;
if (s_config.GitHubPullRequestNotifications != null)
if (s_config.GitHubPullRequestNotifications.Any())
{
body += PullRequestCreator.NotificationString(s_config.GitHubPullRequestNotifications);
}