diff --git a/Microsoft.DotNet.Cli.sln b/Microsoft.DotNet.Cli.sln
index 03125bb8a..60ca154de 100644
--- a/Microsoft.DotNet.Cli.sln
+++ b/Microsoft.DotNet.Cli.sln
@@ -1,7 +1,7 @@
Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 14
-VisualStudioVersion = 14.0.25402.0
+VisualStudioVersion = 14.0.25420.1
MinimumVisualStudioVersion = 10.0.40219.1
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{ED2FE3E2-F7E7-4389-8231-B65123F2076F}"
EndProject
@@ -126,9 +126,20 @@ Project("{8BB2217D-0F2D-49D1-97BC-3654ED321F3B}") = "dotnet-build3.Tests", "test
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "build", "build", "{89905EC4-BC0F-443B-8ADF-691321F10108}"
ProjectSection(SolutionItems) = preProject
+ build\Microsoft.DotNet.Cli.Package.targets = build\Microsoft.DotNet.Cli.Package.targets
build\Microsoft.DotNet.Cli.Prepare.targets = build\Microsoft.DotNet.Cli.Prepare.targets
EndProjectSection
EndProject
+Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "package", "package", "{31A6D092-F50C-4D70-BA4D-97098189A953}"
+ ProjectSection(SolutionItems) = preProject
+ build\package\Microsoft.DotNet.Cli.Archive.targets = build\package\Microsoft.DotNet.Cli.Archive.targets
+ build\package\Microsoft.DotNet.Cli.Installer.DEB.targets = build\package\Microsoft.DotNet.Cli.Installer.DEB.targets
+ build\package\Microsoft.DotNet.Cli.Installer.MSI.targets = build\package\Microsoft.DotNet.Cli.Installer.MSI.targets
+ build\package\Microsoft.DotNet.Cli.Installer.PKG.targets = build\package\Microsoft.DotNet.Cli.Installer.PKG.targets
+ build\package\Microsoft.DotNet.Cli.Layout.targets = build\package\Microsoft.DotNet.Cli.Layout.targets
+ build\package\Microsoft.DotNet.Cli.Nupkg.targets = build\package\Microsoft.DotNet.Cli.Nupkg.targets
+ EndProjectSection
+EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
@@ -967,5 +978,6 @@ Global
{4C3B06D5-B6D5-4E5B-A44F-3EBE52A1C759} = {17735A9D-BFD9-4585-A7CB-3208CA6EA8A7}
{35B19F22-B8C0-4849-9C35-3F809B7588B8} = {ED2FE3E2-F7E7-4389-8231-B65123F2076F}
{49D7318E-D198-4E2B-BBEA-3A24D805F88D} = {17735A9D-BFD9-4585-A7CB-3208CA6EA8A7}
+ {31A6D092-F50C-4D70-BA4D-97098189A953} = {89905EC4-BC0F-443B-8ADF-691321F10108}
EndGlobalSection
EndGlobal
diff --git a/build.proj b/build.proj
index 133cfa712..169def133 100644
--- a/build.proj
+++ b/build.proj
@@ -20,6 +20,7 @@
Debug
$(MSBuildThisFileDirectory)
+ preview
1.0.0
1.0.1
1.0.1
diff --git a/build/Microsoft.DotNet.Cli.Prepare.targets b/build/Microsoft.DotNet.Cli.Prepare.targets
index 8ed0fdff6..ef5d28e82 100644
--- a/build/Microsoft.DotNet.Cli.Prepare.targets
+++ b/build/Microsoft.DotNet.Cli.Prepare.targets
@@ -1,17 +1,19 @@
-
+
+
+
-
-
-
+
-
+
@@ -32,6 +34,7 @@
$(BaseOutputDirectory)/intermediate
$(BaseOutputDirectory)/packages
$(BaseOutputDirectory)/stage2symbols
+ $(IntermediateDirectory)/sharedFrameworkPublish
@@ -83,17 +86,16 @@
$(ArtifactNameCombinedFrameworkSdk)-$(ProductMonikerRid).$(SdkVersion)
- $(PackagesDirectory)/dotnet-host-$(ProductMonikerRid).$(SharedHostVersion)$(ArchiveExtension)
- $(PackagesDirectory)/dotnet-host-$(ProductMonikerRid).$(SharedHostVersion)$(InstallerExtension)
+ dotnet-host-$(ProductMonikerRid).$(SharedHostVersion)$(InstallerExtension)
+ $(PackagesDirectory)/$(SharedHostInstallerFileName)
- $(PackagesDirectory)/dotnet-hostfxr-$(ProductMonikerRid).$(HostFxrVersion)$(ArchiveExtension)
- $(PackagesDirectory)/dotnet-hostfxr-$(ProductMonikerRid).$(HostFxrVersion)$(InstallerExtension)
+ dotnet-hostfxr-$(ProductMonikerRid).$(HostFxrVersion)$(InstallerExtension)
+ $(PackagesDirectory)/$(HostFxrInstallerFileName)
- $(PackagesDirectory)/dotnet-sharedframework-$(ProductMonikerRid).$(SharedFrameworkVersion)$(ArchiveExtension)
- $(PackagesDirectory)/dotnet-sharedframework-$(ProductMonikerRid).$(SharedFrameworkVersion)$(InstallerExtension)
+ dotnet-sharedframework-$(ProductMonikerRid).$(SharedFrameworkVersion)$(InstallerExtension)
+ $(PackagesDirectory)/$(SharedFrameworkInstallerFileName)
- $(PackagesDirectory)/dotnet-$(ProductMonikerRid).$(SharedFrameworkVersion)$(ArchiveExtension)
- $(PackagesDirectory)/dotnet-$(ProductMonikerRid).$(SharedFrameworkVersion)$(BundleExtension)
+ dotnet-$(ProductMonikerRid).$(SharedFrameworkVersion)$(ArchiveExtension)
Microsoft .NET Core 1.0.0 - SDK Preview 2
@@ -104,11 +106,80 @@
-
+
+
+ https://dotnetcli.blob.core.windows.net/dotnet/$(CoreSetupChannel)
+ $(CoreSetupBlobRootUrl)/Binaries/$(SharedFrameworkVersion)
+ $(CoreSetupBlobRootUrl)/Installers
+
+ $(IntermediateDirectory)/coreSetupDownload/$(SharedFrameworkVersion)
+ $(CoreSetupDownloadDirectory)/combinedSharedHostAndFrameworkArchive
+
+
+
+ <_DownloadAndExtractItem Include="CombinedSharedHostAndFrameworkArchive"
+ Condition="!Exists('$(CombinedSharedHostAndFrameworkArchive)')">
+ $(SharedFrameworkArchiveBlobRootUrl)/$(CombinedFrameworkHostCompressedFileName)
+ $(CombinedSharedHostAndFrameworkArchive)
+ $(SharedFrameworkPublishDirectory)
+
+
+ <_DownloadAndExtractItem Include="SharedFrameworkInstallerFile"
+ Condition="!Exists('$(SharedFrameworkInstallerFile)')">
+ $(CoreSetupInstallerBlobRootUrl)/$(SharedFrameworkVersion)/$(SharedFrameworkInstallerFileName)
+ $(SharedFrameworkInstallerFile)
+
+
+
+ <_DownloadAndExtractItem Include="SharedHostInstallerFile"
+ Condition="!Exists('$(SharedHostInstallerFile)')">
+ $(CoreSetupInstallerBlobRootUrl)/$(SharedHostVersion)/$(SharedHostInstallerFileName)
+ $(SharedHostInstallerFile)
+
+
+
+ <_DownloadAndExtractItem Include="HostFxrInstallerFile"
+ Condition="!Exists('$(HostFxrInstallerFile)')">
+ $(CoreSetupInstallerBlobRootUrl)/$(HostFxrVersion)/$(HostFxrInstallerFileName)
+ $(HostFxrInstallerFile)
+
+
+
+
+
+
+
+
+
+
+
+
+
-
+
+
+
+
+
+ <_DotNetNewFolder>$(RepoRoot)/src/dotnet/commands/dotnet-new
+
+
+
+
+
+
+
diff --git a/build/package/Microsoft.DotNet.Cli.Installer.MSI.targets b/build/package/Microsoft.DotNet.Cli.Installer.MSI.targets
index afcc2a4a2..b5b81c41e 100644
--- a/build/package/Microsoft.DotNet.Cli.Installer.MSI.targets
+++ b/build/package/Microsoft.DotNet.Cli.Installer.MSI.targets
@@ -2,7 +2,7 @@
-
+
@@ -73,8 +73,8 @@
DestinationPath="$(WixDestinationPath)"
Overwrite="false" />
-
diff --git a/build_projects/dotnet-cli-build/ArchiveDirectory.cs b/build_projects/dotnet-cli-build/ArchiveDirectory.cs
index 11285ca04..2227f9aaf 100644
--- a/build_projects/dotnet-cli-build/ArchiveDirectory.cs
+++ b/build_projects/dotnet-cli-build/ArchiveDirectory.cs
@@ -1,14 +1,8 @@
-using System;
-using System.Collections.Generic;
-using System.IO;
+using System.IO;
using System.IO.Compression;
-using System.Runtime.InteropServices;
-using Microsoft.Build.Utilities;
-using Microsoft.DotNet.Cli.Build.Framework;
-using Microsoft.DotNet.InternalAbstractions;
using Microsoft.Build.Framework;
using Microsoft.Build.Utilities;
-
+using Microsoft.DotNet.Cli.Build.Framework;
using static Microsoft.DotNet.Cli.Build.Framework.BuildHelpers;
namespace Microsoft.DotNet.Cli.Build
@@ -24,6 +18,8 @@ namespace Microsoft.DotNet.Cli.Build
[Required]
public string InputDirectory { get; set; }
+ public bool ForceZipArchive { get; set; }
+
[Output]
public string OutputArchive { get; set; }
@@ -34,15 +30,17 @@ namespace Microsoft.DotNet.Cli.Build
return true;
}
- if (CurrentPlatform.IsPlatform(BuildPlatform.Windows))
+ if (CurrentPlatform.IsPlatform(BuildPlatform.Windows) || ForceZipArchive)
{
OutputArchive = GenerateZip();
}
- else
+ else
{
OutputArchive = GenerateTarGz();
}
+ Log.LogMessage($"Created Archive '{OutputArchive}'");
+
return true;
}
diff --git a/build_projects/dotnet-cli-build/DecompressZip.cs b/build_projects/dotnet-cli-build/DecompressZip.cs
deleted file mode 100644
index 6daaa97fb..000000000
--- a/build_projects/dotnet-cli-build/DecompressZip.cs
+++ /dev/null
@@ -1,34 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.IO;
-using System.IO.Compression;
-using System.Runtime.InteropServices;
-using System.Net.Http;
-using Microsoft.Build.Utilities;
-using Microsoft.DotNet.Cli.Build.Framework;
-using Microsoft.DotNet.InternalAbstractions;
-using Microsoft.Build.Framework;
-using Microsoft.Build.Utilities;
-
-using static Microsoft.DotNet.Cli.Build.Framework.BuildHelpers;
-
-namespace Microsoft.DotNet.Cli.Build
-{
- public class DecompressZip : Task
- {
- [Required]
- public string InputZip { get; set; }
-
- [Required]
- public string DestinationDirectory { get; set; }
-
- public override bool Execute()
- {
- FS.Mkdirp(DestinationDirectory);
-
- ZipFile.ExtractToDirectory(InputZip, DestinationDirectory);
-
- return true;
- }
- }
-}
diff --git a/build_projects/dotnet-cli-build/DotNetTool.cs b/build_projects/dotnet-cli-build/DotNetTool.cs
index d3d8581b7..388cacade 100644
--- a/build_projects/dotnet-cli-build/DotNetTool.cs
+++ b/build_projects/dotnet-cli-build/DotNetTool.cs
@@ -5,8 +5,6 @@ namespace Microsoft.DotNet.Cli.Build
{
public abstract class DotNetTool : ToolTask
{
- private const string ExeName = "dotnet.exe";
-
public DotNetTool()
{
}
@@ -19,7 +17,7 @@ namespace Microsoft.DotNet.Cli.Build
protected override string ToolName
{
- get { return ExeName; }
+ get { return HostArtifactNames.DotnetHostBaseName; }
}
protected override MessageImportance StandardOutputLoggingImportance
@@ -34,7 +32,7 @@ namespace Microsoft.DotNet.Cli.Build
// if ToolPath was not provided by the MSBuild script
if (string.IsNullOrEmpty(path))
{
- Log.LogError($"Could not find the Path to {ExeName}");
+ Log.LogError($"Could not find the Path to {ToolName}");
return string.Empty;
}
diff --git a/build_projects/dotnet-cli-build/DownloadFile.cs b/build_projects/dotnet-cli-build/DownloadFile.cs
index c08a05590..f008c14de 100644
--- a/build_projects/dotnet-cli-build/DownloadFile.cs
+++ b/build_projects/dotnet-cli-build/DownloadFile.cs
@@ -1,17 +1,8 @@
-using System;
-using System.Collections.Generic;
-using System.IO;
-using System.IO.Compression;
-using System.Runtime.InteropServices;
+using System.IO;
using System.Net.Http;
-using Microsoft.Build.Utilities;
-using Microsoft.DotNet.Cli.Build.Framework;
-using Microsoft.DotNet.InternalAbstractions;
using Microsoft.Build.Framework;
using Microsoft.Build.Utilities;
-using static Microsoft.DotNet.Cli.Build.Framework.BuildHelpers;
-
namespace Microsoft.DotNet.Cli.Build
{
public class DownloadFile : Task
@@ -33,6 +24,8 @@ namespace Microsoft.DotNet.Cli.Build
return true;
}
+ Log.LogMessage($"Downloading '{Uri}' to '{DestinationPath}'");
+
using (var httpClient = new HttpClient())
{
var getTask = httpClient.GetStreamAsync(Uri);
diff --git a/build_projects/dotnet-cli-build/ExtractArchive.cs b/build_projects/dotnet-cli-build/ExtractArchive.cs
new file mode 100644
index 000000000..9535cfa2e
--- /dev/null
+++ b/build_projects/dotnet-cli-build/ExtractArchive.cs
@@ -0,0 +1,35 @@
+using System.IO.Compression;
+using Microsoft.Build.Framework;
+using Microsoft.Build.Utilities;
+using Microsoft.DotNet.Cli.Build.Framework;
+using static Microsoft.DotNet.Cli.Build.Framework.BuildHelpers;
+
+namespace Microsoft.DotNet.Cli.Build
+{
+ public class ExtractArchive : Task
+ {
+ [Required]
+ public string InputFile { get; set; }
+
+ [Required]
+ public string DestinationDirectory { get; set; }
+
+ public override bool Execute()
+ {
+ FS.Mkdirp(DestinationDirectory);
+
+ Log.LogMessage($"Extracting Archive '{InputFile}' to '{DestinationDirectory}'");
+
+ if (CurrentPlatform.IsWindows)
+ {
+ ZipFile.ExtractToDirectory(InputFile, DestinationDirectory);
+ }
+ else
+ {
+ Exec("tar", "xf", InputFile, "-C", DestinationDirectory);
+ }
+
+ return true;
+ }
+ }
+}
diff --git a/build_projects/dotnet-cli-build/GenerateGuidFromName.cs b/build_projects/dotnet-cli-build/GenerateGuidFromName.cs
index 4df4fe250..98ddc39b4 100644
--- a/build_projects/dotnet-cli-build/GenerateGuidFromName.cs
+++ b/build_projects/dotnet-cli-build/GenerateGuidFromName.cs
@@ -1,17 +1,7 @@
using System;
-using System.Collections.Generic;
-using System.IO;
-using System.IO.Compression;
-using System.Runtime.InteropServices;
-using System.Net.Http;
-using Microsoft.Build.Utilities;
-using Microsoft.DotNet.Cli.Build.Framework;
-using Microsoft.DotNet.InternalAbstractions;
+using System.Security.Cryptography;
using Microsoft.Build.Framework;
using Microsoft.Build.Utilities;
-using System.Security.Cryptography;
-
-using static Microsoft.DotNet.Cli.Build.Framework.BuildHelpers;
namespace Microsoft.DotNet.Cli.Build
{
diff --git a/build_projects/dotnet-cli-build/build.ps1 b/build_projects/dotnet-cli-build/build.ps1
index 7142e78c2..bbc5dde50 100644
--- a/build_projects/dotnet-cli-build/build.ps1
+++ b/build_projects/dotnet-cli-build/build.ps1
@@ -71,7 +71,7 @@ $env:DOTNET_SKIP_FIRST_TIME_EXPERIENCE=1
# Restore the build scripts
Write-Host "Restoring Build Script projects..."
-pushd "$PSScriptRoot\.."
+pushd "$PSScriptRoot"
dotnet restore
if($LASTEXITCODE -ne 0) { throw "Failed to restore" }
popd
diff --git a/build_projects/dotnet-cli-build/build.sh b/build_projects/dotnet-cli-build/build.sh
index 7cb3649ec..11fee896c 100755
--- a/build_projects/dotnet-cli-build/build.sh
+++ b/build_projects/dotnet-cli-build/build.sh
@@ -110,7 +110,7 @@ export DOTNET_SKIP_FIRST_TIME_EXPERIENCE=1
# Restore the build scripts
echo "Restoring Build Script projects..."
(
- cd "$DIR/.."
+ cd "$DIR"
dotnet restore
)
@@ -118,13 +118,12 @@ echo "Restoring Build Script projects..."
echo "Compiling Build Scripts..."
dotnet publish "$DIR" -o "$DIR/bin" --framework netcoreapp1.0
-if [-z "$DOTNET_BUILD_SKIP_RUN" ]
-then
+if [ -z "$DOTNET_BUILD_SKIP_RUN" ]; then
export PATH="$OLDPATH"
# Run the builder
echo "Invoking Build Scripts..."
echo "Configuration: $CONFIGURATION"
+
+ $DIR/bin/dotnet-cli-build ${targets[@]}
fi
-
-$DIR/bin/dotnet-cli-build ${targets[@]}
exit $?