Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 4 additions & 11 deletions build.cmd
Original file line number Diff line number Diff line change
@@ -1,15 +1,8 @@
@echo off
setlocal

if "%~1"=="-h" goto help
if "%~1"=="-help" goto help
if "%~1"=="-?" goto help
if "%~1"=="/?" goto help
set _args="%*"
if "%~1"=="-?" set _args="-help"
Comment thread
ViktorHofer marked this conversation as resolved.

powershell -ExecutionPolicy ByPass -NoProfile -File "%~dp0eng\build.ps1" %*
goto end

:help
powershell -ExecutionPolicy ByPass -NoProfile -Command "& { . '%~dp0eng\build.ps1'; Get-Help }"

:end
powershell -ExecutionPolicy ByPass -NoProfile -File "%~dp0eng\build.ps1" %_args%
exit /b %ERRORLEVEL%
7 changes: 6 additions & 1 deletion coreclr.cmd
Original file line number Diff line number Diff line change
@@ -1,2 +1,7 @@
@echo off
"%~dp0build.cmd" -subsetCategory coreclr %*
setlocal

set _args="-subsetCategory coreclr %*"
if "%~1"=="-?" set _args="-help"

"%~dp0build.cmd" %_args%
6 changes: 6 additions & 0 deletions eng/build.ps1
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
[CmdletBinding(PositionalBinding=$false)]
Param(
[switch][Alias('h')]$help,
[switch][Alias('b')]$build,
[switch][Alias('t')]$test,
[switch]$buildtests,
Expand Down Expand Up @@ -57,6 +58,11 @@ if ($MyInvocation.InvocationName -eq ".") {
exit 0
}
Copy link
Copy Markdown
Member

@ViktorHofer ViktorHofer Jan 7, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are we still dot sourcing this script anywhere? If not, we can remove the if block.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmmm I'm not sure about that. I don't think so. Would searching for -Command be enough?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm relatively sure that this is dead code and you can just remove it.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok. Will remove it then.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks


if ($help -or (($null -ne $properties) -and ($properties.Contains('/help') -or $properties.Contains('/?')))) {
Get-Help
exit 0
}

$subsetCategory = $subsetCategory.ToLowerInvariant()

# VS Test Explorer support for libraries
Expand Down
7 changes: 6 additions & 1 deletion installer.cmd
Original file line number Diff line number Diff line change
@@ -1,2 +1,7 @@
@echo off
"%~dp0build.cmd" -subsetCategory installer %*
setlocal

set _args="-subsetCategory installer %*"
if "%~1"=="-?" set _args="-help"

"%~dp0build.cmd" %_args%
7 changes: 6 additions & 1 deletion libraries.cmd
Original file line number Diff line number Diff line change
@@ -1,2 +1,7 @@
@echo off
"%~dp0build.cmd" -subsetCategory libraries %*
setlocal

set _args="-subsetCategory libraries %*"
if "%~1"=="-?" set _args="-help"

"%~dp0build.cmd" %_args%