Skip to content

Commit

Permalink
Merge branch 'hotfix/7.0.4'
Browse files Browse the repository at this point in the history
  • Loading branch information
matkoch committed Aug 31, 2023
2 parents 369ef2b + d7ccb87 commit ea86450
Show file tree
Hide file tree
Showing 15 changed files with 189 additions and 136 deletions.
109 changes: 109 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,15 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.

## [vNext]

## [7.0.4] / 2023-08-31
- Fixed check on nullable parameter type
- Fixed telemetry check on home repository
- Fixed missing environment variables for AppVeyor
- Fixed `ICreateGitHubRelease` to work with existing releases
- Fixed `ICreateGitHubRelease` to set `GitHubToken` unconditionally
- Fixed `SetBuildTarget` and `SetTestPlatform` overloads in `UnityTasks`
- Fixed `UnityRunTestsSettings` base type

## [7.0.3] / 2023-08-21
- Fixed enumeration value sets to exclude non-public fields
- Fixed check for `NUKE_ENTERPRISE_TOKEN` in `build.sh` bootstrapping script
Expand Down Expand Up @@ -1474,3 +1483,103 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
[0.3.1]: https://github.com/nuke-build/nuke/compare/0.2.10...0.3.1
[0.2.10]: https://github.com/nuke-build/nuke/compare/0.2.0...0.2.10
[0.2.0]: https://github.com/nuke-build/nuke/tree/0.2.0

[vNext]: https://github.com/nuke-build/nuke/compare/7.0.4...HEAD
[7.0.4]: https://github.com/nuke-build/nuke/compare/7.0.3...7.0.4
[7.0.3]: https://github.com/nuke-build/nuke/compare/7.0.2...7.0.3
[7.0.2]: https://github.com/nuke-build/nuke/compare/7.0.1...7.0.2
[7.0.1]: https://github.com/nuke-build/nuke/compare/7.0.0...7.0.1
[7.0.0]: https://github.com/nuke-build/nuke/compare/6.3.0...7.0.0
[6.3.0]: https://github.com/nuke-build/nuke/compare/6.2.1...6.3.0
[6.2.1]: https://github.com/nuke-build/nuke/compare/6.2.0...6.2.1
[6.2.0]: https://github.com/nuke-build/nuke/compare/6.1.2...6.2.0
[6.1.2]: https://github.com/nuke-build/nuke/compare/6.1.1...6.1.2
[6.1.1]: https://github.com/nuke-build/nuke/compare/6.1.0...6.1.1
[6.1.0]: https://github.com/nuke-build/nuke/compare/6.0.3...6.1.0
[6.0.3]: https://github.com/nuke-build/nuke/compare/6.0.2...6.0.3
[6.0.2]: https://github.com/nuke-build/nuke/compare/6.0.1...6.0.2
[6.0.1]: https://github.com/nuke-build/nuke/compare/6.0.0...6.0.1
[6.0.0]: https://github.com/nuke-build/nuke/compare/5.3.0...6.0.0
[5.3.0]: https://github.com/nuke-build/nuke/compare/5.2.1...5.3.0
[5.2.1]: https://github.com/nuke-build/nuke/compare/5.2.0...5.2.1
[5.2.0]: https://github.com/nuke-build/nuke/compare/5.1.4...5.2.0
[5.1.4]: https://github.com/nuke-build/nuke/compare/5.1.3...5.1.4
[5.1.3]: https://github.com/nuke-build/nuke/compare/5.1.2...5.1.3
[5.1.2]: https://github.com/nuke-build/nuke/compare/5.1.1...5.1.2
[5.1.1]: https://github.com/nuke-build/nuke/compare/5.1.0...5.1.1
[5.1.0]: https://github.com/nuke-build/nuke/compare/5.0.2...5.1.0
[5.0.2]: https://github.com/nuke-build/nuke/compare/5.0.1...5.0.2
[5.0.1]: https://github.com/nuke-build/nuke/compare/5.0.0...5.0.1
[5.0.0]: https://github.com/nuke-build/nuke/compare/0.25.0...5.0.0
[0.25.0]: https://github.com/nuke-build/nuke/compare/0.24.11...0.25.0
[0.24.11]: https://github.com/nuke-build/nuke/compare/0.24.10...0.24.11
[0.24.10]: https://github.com/nuke-build/nuke/compare/0.24.9...0.24.10
[0.24.9]: https://github.com/nuke-build/nuke/compare/0.24.8...0.24.9
[0.24.8]: https://github.com/nuke-build/nuke/compare/0.24.7...0.24.8
[0.24.7]: https://github.com/nuke-build/nuke/compare/0.24.6...0.24.7
[0.24.6]: https://github.com/nuke-build/nuke/compare/0.24.5...0.24.6
[0.24.5]: https://github.com/nuke-build/nuke/compare/0.24.4...0.24.5
[0.24.4]: https://github.com/nuke-build/nuke/compare/0.24.2...0.24.4
[0.24.2]: https://github.com/nuke-build/nuke/compare/0.24.1...0.24.2
[0.24.1]: https://github.com/nuke-build/nuke/compare/0.24.0...0.24.1
[0.24.0]: https://github.com/nuke-build/nuke/compare/0.23.7...0.24.0
[0.23.7]: https://github.com/nuke-build/nuke/compare/0.23.6...0.23.7
[0.23.6]: https://github.com/nuke-build/nuke/compare/0.23.5...0.23.6
[0.23.5]: https://github.com/nuke-build/nuke/compare/0.23.4...0.23.5
[0.23.4]: https://github.com/nuke-build/nuke/compare/0.23.3...0.23.4
[0.23.3]: https://github.com/nuke-build/nuke/compare/0.23.2...0.23.3
[0.23.2]: https://github.com/nuke-build/nuke/compare/0.23.1...0.23.2
[0.23.1]: https://github.com/nuke-build/nuke/compare/0.23.0...0.23.1
[0.23.0]: https://github.com/nuke-build/nuke/compare/0.22.2...0.23.0
[0.22.2]: https://github.com/nuke-build/nuke/compare/0.22.1...0.22.2
[0.22.1]: https://github.com/nuke-build/nuke/compare/0.22.0...0.22.1
[0.22.0]: https://github.com/nuke-build/nuke/compare/0.21.2...0.22.0
[0.21.2]: https://github.com/nuke-build/nuke/compare/0.21.1...0.21.2
[0.21.1]: https://github.com/nuke-build/nuke/compare/0.21.0...0.21.1
[0.21.0]: https://github.com/nuke-build/nuke/compare/0.20.1...0.21.0
[0.20.1]: https://github.com/nuke-build/nuke/compare/0.20.0...0.20.1
[0.20.0]: https://github.com/nuke-build/nuke/compare/0.19.2...0.20.0
[0.19.2]: https://github.com/nuke-build/nuke/compare/0.19.1...0.19.2
[0.19.1]: https://github.com/nuke-build/nuke/compare/0.19.0...0.19.1
[0.19.0]: https://github.com/nuke-build/nuke/compare/0.18.0...0.19.0
[0.18.0]: https://github.com/nuke-build/nuke/compare/0.17.7...0.18.0
[0.17.7]: https://github.com/nuke-build/nuke/compare/0.17.6...0.17.7
[0.17.6]: https://github.com/nuke-build/nuke/compare/0.17.5...0.17.6
[0.17.5]: https://github.com/nuke-build/nuke/compare/0.17.4...0.17.5
[0.17.4]: https://github.com/nuke-build/nuke/compare/0.17.3...0.17.4
[0.17.3]: https://github.com/nuke-build/nuke/compare/0.17.2...0.17.3
[0.17.2]: https://github.com/nuke-build/nuke/compare/0.17.1...0.17.2
[0.17.1]: https://github.com/nuke-build/nuke/compare/0.17.0...0.17.1
[0.17.0]: https://github.com/nuke-build/nuke/compare/0.16.0...0.17.0
[0.16.0]: https://github.com/nuke-build/nuke/compare/0.15.0...0.16.0
[0.15.0]: https://github.com/nuke-build/nuke/compare/0.14.1...0.15.0
[0.14.1]: https://github.com/nuke-build/nuke/compare/0.14.0...0.14.1
[0.14.0]: https://github.com/nuke-build/nuke/compare/0.13.0...0.14.0
[0.13.0]: https://github.com/nuke-build/nuke/compare/0.12.4...0.13.0
[0.12.4]: https://github.com/nuke-build/nuke/compare/0.12.3...0.12.4
[0.12.3]: https://github.com/nuke-build/nuke/compare/0.12.2...0.12.3
[0.12.2]: https://github.com/nuke-build/nuke/compare/0.12.1...0.12.2
[0.12.1]: https://github.com/nuke-build/nuke/compare/0.12.0...0.12.1
[0.12.0]: https://github.com/nuke-build/nuke/compare/0.11.1...0.12.0
[0.11.1]: https://github.com/nuke-build/nuke/compare/0.11.0...0.11.1
[0.11.0]: https://github.com/nuke-build/nuke/compare/0.10.5...0.11.0
[0.10.5]: https://github.com/nuke-build/nuke/compare/0.10.4...0.10.5
[0.10.4]: https://github.com/nuke-build/nuke/compare/0.10.3...0.10.4
[0.10.3]: https://github.com/nuke-build/nuke/compare/0.10.2...0.10.3
[0.10.2]: https://github.com/nuke-build/nuke/compare/0.10.1...0.10.2
[0.10.1]: https://github.com/nuke-build/nuke/compare/0.10.0...0.10.1
[0.10.0]: https://github.com/nuke-build/nuke/compare/0.9.1...0.10.0
[0.9.1]: https://github.com/nuke-build/nuke/compare/0.9.0...0.9.1
[0.9.0]: https://github.com/nuke-build/nuke/compare/0.8.0...0.9.0
[0.8.0]: https://github.com/nuke-build/nuke/compare/0.7.0...0.8.0
[0.7.0]: https://github.com/nuke-build/nuke/compare/0.6.2...0.7.0
[0.6.2]: https://github.com/nuke-build/nuke/compare/0.6.1...0.6.2
[0.6.1]: https://github.com/nuke-build/nuke/compare/0.6.0...0.6.1
[0.6.0]: https://github.com/nuke-build/nuke/compare/0.5.3...0.6.0
[0.5.3]: https://github.com/nuke-build/nuke/compare/0.5.2...0.5.3
[0.5.2]: https://github.com/nuke-build/nuke/compare/0.5.0...0.5.2
[0.5.0]: https://github.com/nuke-build/nuke/compare/0.4.0...0.5.0
[0.4.0]: https://github.com/nuke-build/nuke/compare/0.3.1...0.4.0
[0.3.1]: https://github.com/nuke-build/nuke/compare/0.2.10...0.3.1
[0.2.10]: https://github.com/nuke-build/nuke/compare/0.2.0...0.2.10
[0.2.0]: https://github.com/nuke-build/nuke/tree/0.2.0
8 changes: 4 additions & 4 deletions appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,13 +41,13 @@ environment:
SignPathApiToken:
secure: uQTH2MxpqiqWTy7EJkjtNc43ipG17EUOQN99QsODRNgtNEcikDaP0t4ylekK/ibn
TwitterConsumerKey:
secure: mYr1Uw8bcVUyl1P0prdaUFurdiF7V283BSRlQHxe2Zg=
secure: T61zL4r+xtyj7b0aOGYCsyixrXHooXE759T8z3M67Lw=
TwitterConsumerSecret:
secure: pGt5X6KOwj/bLM4A5mnDRBqPxt7o7UreSlZSFmbfZwyfKZnhfFRnr20fXWjVqToVw7NSp30s6GxjswTrQSIogw==
secure: CZwdlO4PHT51Xr0Pe/mT6WpfBzQXsL0C3yWfHgXqdYrf22rx8ePEt5qpszWckbHE5Vh5ErtVfIAQgLeFrqe2Gg==
TwitterAccessToken:
secure: nnv1h5nkNm4MS50soQHiYUZLERgkft/ooq73B02sLValeUDZFypI3tk1TzUwACzJPOdjqRSvY9efvQbt2MoNaQ==
secure: nnv1h5nkNm4MS50soQHiYZk9hnPkWEMQP/5cdf6RJfDIL1gUYxLR7uBaAi1M4sswT0TQ7oL4TBIN/yziq33N5A==
TwitterAccessTokenSecret:
secure: odqmaAfKaVzNj8Ph/q2sLVmM/1COuix8NoqtDwayr8KEli3kmtGFThrN4g5k6aKT
secure: /RrBl2p46rlgpzBHweWeD0spt3JNZDsM8vABoI9Ao29+Z9D4rUYvpM5oHUWA8Lb6
SlackWebhook:
secure: xENxLITTR28hBLEY51YWMeHhxkhg1h1tLY1zGre1/hmM/XDRPsJCxvZvTHFhtfLsQ3cF7GQi3xDaShkVVR7zoXHsIYT+KT0zLnq9FSEvr5c=
DiscordWebhook:
Expand Down
44 changes: 25 additions & 19 deletions build/Build.Announce.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@
using System.Collections.Generic;
using System.Linq;
using System.Text;
using LinqToTwitter;
using LinqToTwitter.OAuth;
using Nuke.Common;
using Nuke.Common.ChangeLog;
using Nuke.Common.Git;
Expand All @@ -16,9 +18,6 @@
using Nuke.Common.Tools.Slack;
using Nuke.Common.Utilities;
using Nuke.Components;
using Tweetinvi;
using Tweetinvi.Models;
using Tweetinvi.Parameters;
using static Nuke.Common.Tools.Discord.DiscordTasks;
using static Nuke.Common.Tools.Git.GitTasks;
using static Nuke.Common.Tools.Mastodon.MastodonTasks;
Expand Down Expand Up @@ -78,10 +77,12 @@ partial class Build
("Amazon Web Services", "https://aws.amazon.com/"),
};

// https://api.slack.com/apps/A050ZLH0V40/incoming-webhooks?
[Parameter] [Secret] readonly string SlackWebhook;

Target AnnounceSlack => _ => _
.TriggeredBy(Announce)
.ProceedAfterFailure()
.Requires(() => SlackWebhook)
.Executes(async () =>
{
Expand All @@ -105,10 +106,12 @@ await SendSlackMessageAsync(_ => _
SlackWebhook);
});

// Server settings | Apps | Integrations | Webhooks | NUKE
[Parameter] [Secret] readonly string DiscordWebhook;

Target AnnounceDiscord => _ => _
.TriggeredBy(Announce)
.ProceedAfterFailure()
.Requires(() => DiscordWebhook)
.Executes(async () =>
{
Expand Down Expand Up @@ -143,38 +146,41 @@ await SendDiscordMessageAsync(_ => _

Target AnnounceTwitter => _ => _
.TriggeredBy(Announce)
.ProceedAfterFailure()
.Requires(() => TwitterCredentials.ConsumerKey)
.Requires(() => TwitterCredentials.ConsumerSecret)
.Requires(() => TwitterCredentials.AccessToken)
.Requires(() => TwitterCredentials.AccessTokenSecret)
.Executes(async () =>
{
var client = new TwitterClient(
new TwitterCredentials(
TwitterCredentials.ConsumerKey,
TwitterCredentials.ConsumerSecret,
TwitterCredentials.AccessToken,
TwitterCredentials.AccessTokenSecret));
var media = await client.Upload.UploadTweetImageAsync(
new UploadTweetImageParameters(ReleaseImageFile.ReadAllBytes())
var context = new TwitterContext(
new SingleUserAuthorizer
{
MediaCategory = MediaCategory.Image
CredentialStore =
new SingleUserInMemoryCredentialStore
{
ConsumerKey = TwitterCredentials.ConsumerKey,
ConsumerSecret = TwitterCredentials.ConsumerSecret,
AccessToken = TwitterCredentials.AccessToken,
AccessTokenSecret = TwitterCredentials.AccessTokenSecret
}
});
await client.Tweets.PublishTweetAsync(
new PublishTweetParameters
{
Text = AnnouncementTweetText,
Medias = new List<IMedia> { media }
});
var media = await context.UploadMediaAsync(
media: ReleaseImageFile.ReadAllBytes(),
mediaType: "image/png",
mediaCategory: "tweet_image");
await context.TweetMediaAsync(AnnouncementTweetText, mediaIds: new[] { media.NotNull().MediaID.ToString() });
});

string AnnouncementTootText => AnnouncementTweetText;
// https://dotnet.social/settings/applications/496
[Parameter] [Secret] readonly string MastodonAccessToken;

Target AnnounceMastodon => _ => _
.TriggeredBy(Announce)
.ProceedAfterFailure()
.Requires(() => MastodonAccessToken)
.Executes(async () =>
{
Expand Down
8 changes: 4 additions & 4 deletions build/Build.CI.AppVeyor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,10 @@
[AppVeyorSecret(nameof(PublicNuGetApiKey), "dSaquYHVNEAZO+hhGGoGqeHaVP99BP8koHTTqcD3WInWBTmB7yE4CzxZ1pWypnX2")]
[AppVeyorSecret(ICreateGitHubRelease.GitHubRelease + nameof(ICreateGitHubRelease.GitHubToken), "a5UfxXiDEere9GkCCN9TUZMUdyzjC01cvHthbMLtSl0w+/giDwOyApiHRRRrwyKL5yd/vjD6xDBTBj+W/ZxKzMtzC+gDCSTNO8bSJG9Rh2n9eGzLtWzEFDw/zDYZXe5N")]
[AppVeyorSecret(ISignPackages.SignPath + nameof(ISignPackages.ApiToken), "uQTH2MxpqiqWTy7EJkjtNc43ipG17EUOQN99QsODRNgtNEcikDaP0t4ylekK/ibn")]
[AppVeyorSecret(IHazTwitterCredentials.Twitter + nameof(IHazTwitterCredentials.ConsumerKey), "mYr1Uw8bcVUyl1P0prdaUFurdiF7V283BSRlQHxe2Zg=")]
[AppVeyorSecret(IHazTwitterCredentials.Twitter + nameof(IHazTwitterCredentials.ConsumerSecret), "pGt5X6KOwj/bLM4A5mnDRBqPxt7o7UreSlZSFmbfZwyfKZnhfFRnr20fXWjVqToVw7NSp30s6GxjswTrQSIogw==")]
[AppVeyorSecret(IHazTwitterCredentials.Twitter + nameof(IHazTwitterCredentials.AccessToken), "nnv1h5nkNm4MS50soQHiYUZLERgkft/ooq73B02sLValeUDZFypI3tk1TzUwACzJPOdjqRSvY9efvQbt2MoNaQ==")]
[AppVeyorSecret(IHazTwitterCredentials.Twitter + nameof(IHazTwitterCredentials.AccessTokenSecret), "odqmaAfKaVzNj8Ph/q2sLVmM/1COuix8NoqtDwayr8KEli3kmtGFThrN4g5k6aKT")]
[AppVeyorSecret(IHazTwitterCredentials.Twitter + nameof(IHazTwitterCredentials.ConsumerKey), "T61zL4r+xtyj7b0aOGYCsyixrXHooXE759T8z3M67Lw=")]
[AppVeyorSecret(IHazTwitterCredentials.Twitter + nameof(IHazTwitterCredentials.ConsumerSecret), "CZwdlO4PHT51Xr0Pe/mT6WpfBzQXsL0C3yWfHgXqdYrf22rx8ePEt5qpszWckbHE5Vh5ErtVfIAQgLeFrqe2Gg==")]
[AppVeyorSecret(IHazTwitterCredentials.Twitter + nameof(IHazTwitterCredentials.AccessToken), "nnv1h5nkNm4MS50soQHiYZk9hnPkWEMQP/5cdf6RJfDIL1gUYxLR7uBaAi1M4sswT0TQ7oL4TBIN/yziq33N5A==")]
[AppVeyorSecret(IHazTwitterCredentials.Twitter + nameof(IHazTwitterCredentials.AccessTokenSecret), "/RrBl2p46rlgpzBHweWeD0spt3JNZDsM8vABoI9Ao29+Z9D4rUYvpM5oHUWA8Lb6")]
[AppVeyorSecret(nameof(SlackWebhook), "xENxLITTR28hBLEY51YWMeHhxkhg1h1tLY1zGre1/hmM/XDRPsJCxvZvTHFhtfLsQ3cF7GQi3xDaShkVVR7zoXHsIYT+KT0zLnq9FSEvr5c=")]
[AppVeyorSecret(nameof(DiscordWebhook), "K5WG8m71vcB56C75b0ErFPLYTsqywhPy8hSn49uqc5XBE7txUnZqWBHfbWCuU9AdFkm3TNgSYLoejjF59OgiACEn45fghVe7XCwAXo2l54ZXl08MZyBkJ8by9HsZirL9W+SeysNdw/Cfc0sxKrWcpDkn1IH2zZ+iXAgqBsW2CNY=")]
[AppVeyorSecret(nameof(MastodonAccessToken), "pD/C1TvhUnFtb0oLUvlf2NtjkWeZQcrUVvYJE/LgZb8nxagK8Lwk+OR7TUqOh+Nn")]
Expand Down
1 change: 1 addition & 0 deletions build/_build.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="linqtotwitter" Version="6.15.0" />
<PackageReference Include="SixLabors.ImageSharp.Drawing" Version="1.0.0-beta14" />
<PackageDownload Include="Codecov.Tool" Version="[1.12.3]" />
<PackageDownload Include="GitVersion.Tool" Version="[5.8.0]" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@
using System.Collections.Generic;
using System.IO;
using System.Linq;
using JetBrains.Annotations;
using Newtonsoft.Json.Linq;
using Nuke.Common.CI;
using Nuke.Common.IO;
using Nuke.Common.ProjectModel;
using Nuke.Common.Utilities;
using Nuke.Common.Utilities.Collections;
using Nuke.Common.ValueInjection;
Expand Down Expand Up @@ -48,11 +48,10 @@ string DecryptValue(string profile, string name, string value)
name);

// TODO: Abstract AbsolutePath/Solution/Project etc.
string ConvertValue(Type scalarType, string value)
=> scalarType.IsAssignableTo(typeof(IAbsolutePathHolder))
? PathConstruction.HasPathRoot(value)
? value
: EnvironmentInfo.WorkingDirectory.GetUnixRelativePathTo(Build.RootDirectory / value)
string ConvertValue([CanBeNull] Type scalarType, string value)

Check notice on line 51 in source/Nuke.Build/Execution/Extensions/ArgumentsFromParametersFileAttribute.cs

View workflow job for this annotation

GitHub Actions / Qodana for .NET

Put local function after 'return' or 'continue'

Put local function 'ConvertValue' after 'return'

Check notice on line 51 in source/Nuke.Build/Execution/Extensions/ArgumentsFromParametersFileAttribute.cs

View workflow job for this annotation

GitHub Actions / Qodana for .NET

Put local function after 'return' or 'continue'

Put local function 'ConvertValue' after 'return'
=> typeof(IAbsolutePathHolder).IsAssignableFrom(scalarType) &&
!PathConstruction.HasPathRoot(value)
? EnvironmentInfo.WorkingDirectory.GetUnixRelativePathTo(Build.RootDirectory / value)
: value;

var arguments = GetParameters().SelectMany(x => ConvertToArguments(x.Profile, x.Name, x.Values)).ToArray();
Expand Down
2 changes: 1 addition & 1 deletion source/Nuke.Build/Telemetry/Telemetry.Properties.cs
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ private static bool IsCommonType(Type type)
{
return type.Assembly
.GetCustomAttributes<AssemblyMetadataAttribute>()
.Any(x => x is { Key: "RepositoryUrl", Value: "https://github.com/nuke-build/nuke" });
.Any(x => x is { Key: "RepositoryUrl", Value: "https://github.com/nuke-build/nuke.git" });
}

private static bool IsCustomType(Type type)
Expand Down
3 changes: 3 additions & 0 deletions source/Nuke.Common/CI/AppVeyor/AppVeyor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,9 @@ internal AppVeyor()
public string BuildWorkerImage => EnvironmentInfo.GetVariable("APPVEYOR_BUILD_WORKER_IMAGE");
[CanBeNull] public int? PullRequestNumber => EnvironmentInfo.GetVariable<int?>("APPVEYOR_PULL_REQUEST_NUMBER");
[CanBeNull] public string PullRequestTitle => EnvironmentInfo.GetVariable("APPVEYOR_PULL_REQUEST_TITLE");
[CanBeNull] public string PullRequestHeadRepositoryName => EnvironmentInfo.GetVariable("APPVEYOR_PULL_REQUEST_HEAD_REPO_NAME");
[CanBeNull] public string PullRequestHeadRepositoryBranch => EnvironmentInfo.GetVariable("APPVEYOR_PULL_REQUEST_HEAD_REPO_BRANCH");
[CanBeNull] public string PullRequestHeadCommit => EnvironmentInfo.GetVariable("APPVEYOR_PULL_REQUEST_HEAD_COMMIT");
public string JobId => EnvironmentInfo.GetVariable("APPVEYOR_JOB_ID");
[CanBeNull] public string JobName => EnvironmentInfo.GetVariable("APPVEYOR_JOB_NAME");
public int JobNumber => EnvironmentInfo.GetVariable<int>("APPVEYOR_JOB_NUMBER");
Expand Down
2 changes: 1 addition & 1 deletion source/Nuke.Common/Tools/Unity/Unity.Generated.cs
Original file line number Diff line number Diff line change
Expand Up @@ -752,7 +752,7 @@ protected override Arguments ConfigureProcessArguments(Arguments arguments)
[PublicAPI]
[ExcludeFromCodeCoverage]
[Serializable]
public partial class UnityRunTestsSettings : UnityBaseSettings
public partial class UnityRunTestsSettings : UnityProjectSettings
{
/// <summary>
/// Path to the Unity executable.
Expand Down
2 changes: 1 addition & 1 deletion source/Nuke.Common/Tools/Unity/Unity.json
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@
"customAssertion": true,
"definiteArgument": "-runTests",
"settingsClass": {
"baseClass": "UnityBaseSettings",
"baseClass": "UnityProjectSettings",
"properties": [
{
"name": "TestCategories",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
using System;
using System.Linq;
using JetBrains.Annotations;
using Nuke.Common.Tooling;

namespace Nuke.Common.Tools.Unity;

Expand All @@ -15,11 +14,10 @@ public static partial class UnityProjectSettingsExtensions

/// <summary><p><em>Sets <see cref="UnityProjectSettings.BuildTarget"/>.</em></p><p>Allows the selection of an active build target before a project is loaded.</p></summary>
[Pure]
public static UnityProjectSettings SetBuildTarget(this UnityProjectSettings toolSettings, UnityBuildTarget buildTarget)
public static T SetBuildTarget<T>(this T toolSettings, UnityBuildTarget buildTarget)
where T : UnityProjectSettings
{
toolSettings = toolSettings.NewInstance();
toolSettings.BuildTarget = buildTarget.ToString();
return toolSettings;
return toolSettings.SetBuildTarget(buildTarget.ToString());
}

#endregion
Expand Down
Loading

0 comments on commit ea86450

Please sign in to comment.