Skip to content

Commit 30ff134

Browse files
committed
use recommenedd coreconsole from https://github.com/dotnet/cli
1 parent e7ac156 commit 30ff134

File tree

6 files changed

+23
-11
lines changed

6 files changed

+23
-11
lines changed

tools/CLU/BuildAndInstallClu.bat

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,21 @@ REM note, for known nuget bugs, skip --install by copying over cmdlet packages.
2828
xcopy %root%\drop\clurun\win7-x64\pkgs %root%\drop\clurun\osx.10.10-x64\pkgs /S /Q /I /Y
2929
copy /Y %root%\drop\clurun\win7-x64\azure.lx %root%\drop\clurun\osx.10.10-x64
3030
copy /Y %root%\drop\clurun\win7-x64\msclu.cfg %root%\drop\clurun\osx.10.10-x64
31+
32+
REM: copy over the pre-cooked azure.sh and ensure correct line endings
3133
copy /Y %~dp0\azure.sh %root%\drop\clurun\osx.10.10-x64
34+
set azuresh=%root%\drop\clurun\osx.10.10-x64\azure.sh
35+
echo Get-ChildItem %azuresh% ^| ForEach-Object { > %temp%\fixLineEndings.ps1
36+
echo $contents = [IO.File]::ReadAllText($_) -replace "`r`n?", "`n" >> %temp%\fixLineEndings.ps1
37+
echo [IO.File]::WriteAllText($_, $contents) >> %temp%\fixLineEndings.ps1
38+
echo } >> %temp%\fixLineEndings.ps1
39+
@powershell -file %temp%\fixLineEndings.ps1
3240

3341
xcopy %root%\drop\clurun\win7-x64\pkgs %root%\drop\clurun\ubuntu.14.04-x64\pkgs /S /Q /I /Y
3442
copy /Y %root%\drop\clurun\win7-x64\azure.lx %root%\drop\clurun\ubuntu.14.04-x64
3543
copy /Y %root%\drop\clurun\win7-x64\msclu.cfg %root%\drop\clurun\ubuntu.14.04-x64
36-
copy /Y %~dp0\azure.sh %root%\drop\clurun\ubuntu.14.04-x64
44+
copy /Y %azuresh% %root%\drop\clurun\ubuntu.14.04-x64
45+
46+
REM, windows version also needs it for bash based testing
47+
copy /Y %azuresh% %root%\drop\clurun\win7-x64
48+

tools/CLU/BuildDrop.ps1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,8 +50,8 @@ if (!($excludeCluRun))
5050

5151
if (!($runtime.StartsWith("win")))
5252
{
53-
# Fix current x-plat dotnet publish by correctly renaming ConsoleHost to clurun
54-
Move-Item -Path "$cluRunOutput\coreconsole" -Destination "$cluRunOutput\clurun" -Force
53+
# use released coreconsole file from https://github.com/dotnet/cli
54+
Copy-Item -Path "$workspaceDirectory\tools\CLU\$runtime\coreconsole" -Destination "$cluRunOutput\clurun" -Force
5555

5656
# Remove all extra exes that end up in the output directory...
5757
Get-ChildItem -Path "$cluRunOutput" -Filter "*.exe" | Remove-Item

tools/CLU/BuildPackage.ps1

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,16 +2,16 @@
22

33
if (!(Test-Path $cmdletsDir))
44
{
5-
throw "cmdletsDir: '$cmdletsDir' must be an existing directory containing cmdlet code"
5+
throw "cmdletsDir: '$cmdletsDir' must be an existing directory containing cmdlet code"
66
}
77
if (!(Test-Path $outputDir))
88
{
9-
throw "outputDir: '$outputDir' must be an existing directory"
9+
throw "outputDir: '$outputDir' must be an existing directory"
1010
}
1111

1212
if ([string]::IsNullOrWhiteSpace($env:WORKSPACE) -or !(Test-Path $env:WORKSPACE))
1313
{
14-
throw "env:WORKSPACE: '$env:WORKSPACE' must be an existing directory"
14+
throw "env:WORKSPACE: '$env:WORKSPACE' must be an existing directory"
1515
}
1616

1717
$packageSource = $packageSource.TrimEnd('\\')
@@ -34,19 +34,19 @@ $contentFileText = ""
3434
$contentFiles | %{ $contentFileText += (" <file src=""" + $_.Name + """ target=""content""/>`r`n")}
3535
if ($packageId -ne "Microsoft.CLU.Commands")
3636
{
37-
$contentFileText += " <file src=""content\azure.lx"" target=""content""/>`r`n"
37+
$contentFileText += " <file src=""content\azure.lx"" target=""content""/>`r`n"
3838
}
3939
if ($renameFileExists)
4040
{
41-
$contentFileText += " <file src=""content\rename.cfg"" target=""content""/>`r`n"
41+
$contentFileText += " <file src=""content\rename.cfg"" target=""content""/>`r`n"
4242
}
4343
$contentFileText += " <file src=""content\package.cfg"" target=""content""/>`r`n"
4444
$sourceFileText = ""
4545
$refFiles | %{$sourceFileText += (" <file src=""" + $_.Name + """ target=""lib\dnxcore50""/>`r`n")}
4646
$outputContent = $fileContent -replace "%PackageVersion%", $packageVersion
4747
$outputContent = $outputContent -replace "%ReferenceFiles%", $refFileText
48-
$outputContent = $outputContent -replace "%SourceFiles%", $sourceFileText
49-
$outputContent = $outputContent -replace "%ContentFiles%", $contentFileText
48+
$outputContent = $outputContent -replace "%SourceFiles%", $sourceFileText
49+
$outputContent = $outputContent -replace "%ContentFiles%", $contentFileText
5050
Set-Content -Value $outputContent -Path $nuspecOutput
5151

5252
Write-Host "Creating nuget package..."

tools/CLU/SetupEnv.bat

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ set DebugCLU=
1414
call %~dp0\BuildAndInstallClu.bat
1515
set Path=%Path%;%root%\drop\clurun\win7-x64
1616
REM run 'azure help' to verify all are wired up
17-
azure help
17+
azure.bat help
1818
if ERRORLEVEL 1 (
1919
echo Build and deploy clu package failed
2020
exit /B 1

tools/CLU/osx.10.10-x64/coreconsole

21.7 KB
Binary file not shown.
24.2 KB
Binary file not shown.

0 commit comments

Comments
 (0)