Skip to content

Commit

Permalink
Merge pull request #152 from petabridge/dev
Browse files Browse the repository at this point in the history
v0.4.0 Release
  • Loading branch information
Aaronontheweb authored Dec 23, 2020
2 parents 051a91f + a4412c0 commit 8c053f3
Show file tree
Hide file tree
Showing 12 changed files with 40 additions and 87 deletions.
8 changes: 4 additions & 4 deletions RELEASE_NOTES.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#### 0.3.0 September 26 2020 ####
New feature release: 0.3.0
#### 0.4.0 December 23 2020 ####
New feature release: 0.4.0

* Updated Roslyn version to 3.7.0
* Dropped .NET tool support for .NET Core 2.1 and 3.0; moved to targeting .NET Core 3.1
* Added .NET 5 `dotnet tool` support in addition to .NET Core 3.1
* Target Roslyn 3.8.0
10 changes: 10 additions & 0 deletions build-system/azure-pipeline.template.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,16 @@ jobs:
clean: false # whether to fetch clean each time
submodules: recursive # set to 'true' for a single level of submodules or 'recursive' to get submodules of submodules
persistCredentials: true
- task: UseDotNet@2
displayName: 'Use .Net 5 SDK'
inputs:
packageType: sdk
version: 5.0.101
- task: UseDotNet@2
displayName: 'Use .NET Core SDK 3.1.105'
inputs:
packageType: sdk
version: 3.1.105
# Linux or macOS
- task: Bash@3
displayName: Linux / OSX Build
Expand Down
2 changes: 1 addition & 1 deletion build-system/windows-pr-validation.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,6 @@ jobs:
- template: azure-pipeline.template.yaml
parameters:
name: Windows
vmImage: 'vs2017-win2016'
vmImage: 'windows-2019'
scriptFileName: build.cmd
scriptArgs: all
2 changes: 1 addition & 1 deletion build-system/windows-release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# See https://docs.microsoft.com/en-us/azure/devops/pipelines/yaml-schema for reference

pool:
vmImage: vs2017-win2016
vmImage: windows-2019
demands: Cmd

trigger:
Expand Down
16 changes: 10 additions & 6 deletions build.fsx
Original file line number Diff line number Diff line change
Expand Up @@ -120,25 +120,29 @@ Target "RunTests" (fun _ ->
Target "IntegrationTests" <| fun _ ->
let integrationTests = !! "./src/**/Incrementalist.Cmd.csproj"

let runSingleProject project =

let folderOnlyArgs = sprintf "run --project %s -c %s --framework netcoreapp3.1 --no-build -- -b dev -l -f %s" project configuration (outputTests @@ "incrementalist-affected-folders.txt")
let slnArgs = sprintf "run --project %s -c %s --framework netcoreapp3.1 -- -b dev -f %s" project configuration (outputTests @@ "incrementalist-affected-files.txt")
let frameworks = ["netcoreapp3.1"; "net5.0"]

let runSingleProject project fwork =

let folderOnlyArgs = sprintf "run --project %s -c %s --framework %s --no-build -- -b dev -l -f %s" project configuration fwork (outputTests @@ "incrementalist-affected-folders.txt")
let slnArgs = sprintf "run --project %s -c %s --framework %s -- -b dev -f %s" project configuration fwork (outputTests @@ "incrementalist-affected-files.txt")

let execWithArgs args =
let result = ExecProcess(fun info ->
info.FileName <- "dotnet"
info.WorkingDirectory <- __SOURCE_DIRECTORY__
info.Arguments <- args) (TimeSpan.FromMinutes 5.0)
if result <> 0 then failwithf "Incrementalist failed.%s" args
if result <> 0 then failwithf "Incrementalist failed.%s" args

log "Running Incrementalist folders-only check"
execWithArgs folderOnlyArgs

log "Running Incrementalist solution check"
execWithArgs slnArgs

integrationTests |> Seq.iter runSingleProject
for integrationTest in integrationTests do
for framework in frameworks do
runSingleProject integrationTest framework

Target "NBench" <| fun _ ->
let projects =
Expand Down
48 changes: 2 additions & 46 deletions build.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ Param(

$FakeVersion = "4.61.2"
$DotNetChannel = "LTS";
$DotNetVersion = "3.1.100";
$DotNetInstallerUri = "https://dot.net/v1/dotnet-install.ps1";
$NugetVersion = "4.1.0";
$NugetUrl = "https://dist.nuget.org/win-x86-commandline/v$NugetVersion/nuget.exe"
Expand All @@ -46,50 +45,6 @@ if (!(Test-Path $ToolPath)) {
New-Item -Path $ToolPath -Type directory | out-null
}

###########################################################################
# INSTALL .NET CORE CLI
###########################################################################

Function Remove-PathVariable([string]$VariableToRemove)
{
$path = [Environment]::GetEnvironmentVariable("PATH", "User")
if ($path -ne $null)
{
$newItems = $path.Split(';', [StringSplitOptions]::RemoveEmptyEntries) | Where-Object { "$($_)" -inotlike $VariableToRemove }
[Environment]::SetEnvironmentVariable("PATH", [System.String]::Join(';', $newItems), "User")
}

$path = [Environment]::GetEnvironmentVariable("PATH", "Process")
if ($path -ne $null)
{
$newItems = $path.Split(';', [StringSplitOptions]::RemoveEmptyEntries) | Where-Object { "$($_)" -inotlike $VariableToRemove }
[Environment]::SetEnvironmentVariable("PATH", [System.String]::Join(';', $newItems), "Process")
}
}

# Get .NET Core CLI path if installed.
$FoundDotNetCliVersion = $null;
if (Get-Command dotnet -ErrorAction SilentlyContinue) {
$FoundDotNetCliVersion = dotnet --version;
$env:DOTNET_SKIP_FIRST_TIME_EXPERIENCE=1
$env:DOTNET_CLI_TELEMETRY_OPTOUT=1
}

if($FoundDotNetCliVersion -ne $DotNetVersion) {
$InstallPath = Join-Path $PSScriptRoot ".dotnet"
if (!(Test-Path $InstallPath)) {
mkdir -Force $InstallPath | Out-Null;
}
(New-Object System.Net.WebClient).DownloadFile($DotNetInstallerUri, "$InstallPath\dotnet-install.ps1");
& $InstallPath\dotnet-install.ps1 -Channel $DotNetChannel -Version $DotNetVersion -InstallDir $InstallPath -Architecture x64;

Remove-PathVariable "$InstallPath"
$env:PATH = "$InstallPath;$env:PATH"
$env:DOTNET_SKIP_FIRST_TIME_EXPERIENCE=1
$env:DOTNET_CLI_TELEMETRY_OPTOUT=1
$env:DOTNET_ROOT=$InstallPath
}

###########################################################################
# INSTALL NUGET
###########################################################################
Expand All @@ -100,7 +55,8 @@ if (!(Test-Path $NugetPath)) {
Write-Host "Downloading NuGet.exe..."
(New-Object System.Net.WebClient).DownloadFile($NugetUrl, $NugetPath);
}

Write-Host "Update NuGet"
& $NugetPath update -self
###########################################################################
# INSTALL FAKE
###########################################################################
Expand Down
20 changes: 1 addition & 19 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ NUGET_EXE=$TOOLS_DIR/nuget.exe
NUGET_URL=https://dist.nuget.org/win-x86-commandline/v4.0.0/nuget.exe
FAKE_VERSION=4.61.2
FAKE_EXE=$TOOLS_DIR/FAKE/tools/FAKE.exe
DOTNET_VERSION=3.1.100
DOTNET_INSTALLER_URL=https://dot.net/v1/dotnet-install.sh
DOTNET_CHANNEL=LTS;
DOCFX_VERSION=2.40.5
Expand Down Expand Up @@ -42,23 +41,6 @@ if [ ! -d "$TOOLS_DIR" ]; then
mkdir "$TOOLS_DIR"
fi

###########################################################################
# INSTALL .NET CORE CLI
###########################################################################

echo "Installing .NET CLI..."
if [ ! -d "$SCRIPT_DIR/.dotnet" ]; then
mkdir "$SCRIPT_DIR/.dotnet"
fi
curl -Lsfo "$SCRIPT_DIR/.dotnet/dotnet-install.sh" $DOTNET_INSTALLER_URL
bash "$SCRIPT_DIR/.dotnet/dotnet-install.sh" --version $DOTNET_VERSION --channel $DOTNET_CHANNEL --install-dir .dotnet --no-path
export PATH="$SCRIPT_DIR/.dotnet":$PATH
export DOTNET_SKIP_FIRST_TIME_EXPERIENCE=1
export DOTNET_CLI_TELEMETRY_OPTOUT=1
chmod -R 0755 ".dotnet"
"$SCRIPT_DIR/.dotnet/dotnet" --info


###########################################################################
# INSTALL NUGET
###########################################################################
Expand All @@ -72,7 +54,7 @@ if [ ! -f "$NUGET_EXE" ]; then
exit 1
fi
fi

mono "$NUGET_EXE" update -self
###########################################################################
# INSTALL FAKE
###########################################################################
Expand Down
3 changes: 2 additions & 1 deletion src/Incrementalist.Cmd/Incrementalist.Cmd.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<ToolCommandName>incrementalist</ToolCommandName>
<PackAsTool>true</PackAsTool>
<OutputType>Exe</OutputType>
<TargetFrameworks>netcoreapp3.1;</TargetFrameworks>
<TargetFrameworks>net5.0;netcoreapp3.1</TargetFrameworks>
<PackageRequireLicenseAcceptance>false</PackageRequireLicenseAcceptance>
<LangVersion>7.1</LangVersion>
<Description>.NET Core global tool for determining how to run incremental builds based on the current Git diff.</Description>
Expand All @@ -15,6 +15,7 @@
<PackageReference Include="Microsoft.Build.Locator" Version="1.2.6" />
<PackageReference Include="Microsoft.CodeAnalysis.Workspaces.MSBuild" Version="$(RoslynVersion)" />
<PackageReference Include="Microsoft.Extensions.Logging.Console" Version="2.2.0" />
<PackageReference Include="NuGet.ProjectModel" Version="$(NugetVersion)" />
</ItemGroup>

<ItemGroup>
Expand Down
1 change: 0 additions & 1 deletion src/Incrementalist.Cmd/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,6 @@ private static async Task<int> Main(string[] args)
ResetTitle();
return result;
}

var exitCode = await RunIncrementalist(options);

ResetTitle();
Expand Down
2 changes: 1 addition & 1 deletion src/Incrementalist.Tests/Incrementalist.Tests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<Import Project="..\common.props" />

<PropertyGroup>
<TargetFrameworks>netcoreapp3.1</TargetFrameworks>
<TargetFrameworks>net5.0;netcoreapp3.1</TargetFrameworks>
</PropertyGroup>

<ItemGroup>
Expand Down
2 changes: 1 addition & 1 deletion src/Incrementalist/Incrementalist.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<ItemGroup>
<PackageReference Include="Libgit2Sharp" Version="0.26.2" />
<PackageReference Include="Microsoft.CodeAnalysis.CSharp.Workspaces" Version="$(RoslynVersion)" />
<PackageReference Include="Microsoft.Extensions.Logging" Version="3.1.8" />
<PackageReference Include="Microsoft.Extensions.Logging" Version="5.0.0" />
</ItemGroup>

</Project>
13 changes: 7 additions & 6 deletions src/common.props
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@
<PropertyGroup>
<Copyright>Copyright © 2015-2019 Petabridge</Copyright>
<Authors>Petabridge</Authors>
<VersionPrefix>0.2.2</VersionPrefix>
<PackageReleaseNotes>Maintenance release: Incrementalist v0.2.2
Updated Roslyn version to 3.4.0
Updated Libgit2Sharp version to 0.26.2</PackageReleaseNotes>
<VersionPrefix>0.4.0</VersionPrefix>
<PackageReleaseNotes>New feature release: 0.4.0
Added .NET 5 `dotnet tool` support in addition to .NET Core 3.1
Target Roslyn 3.8.0</PackageReleaseNotes>
<tags>build, msbuild, incremental build, roslyn, git</tags>
<PackageIconUrl>
https://petabridge.com/images/logo.png
Expand Down Expand Up @@ -222,7 +222,8 @@ Updated Libgit2Sharp version to 0.26.2</PackageReleaseNotes>
<PropertyGroup>
<NBenchVersion>1.2.2</NBenchVersion>
<XunitVersion>2.4.1</XunitVersion>
<TestSdkVersion>16.7.1</TestSdkVersion>
<RoslynVersion>3.7.0</RoslynVersion>
<TestSdkVersion>16.8.3</TestSdkVersion>
<RoslynVersion>3.8.0</RoslynVersion>
<NugetVersion>5.8.0</NugetVersion>
</PropertyGroup>
</Project>

0 comments on commit 8c053f3

Please sign in to comment.