Skip to content

Instantly share code, notes, and snippets.

@jeffhandley
Created November 24, 2022 00:26
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jeffhandley/e52ae72bc8d1adee331fc233fd6220f7 to your computer and use it in GitHub Desktop.
Save jeffhandley/e52ae72bc8d1adee331fc233fd6220f7 to your computer and use it in GitHub Desktop.
PowerShell alias for invoking the dotnet/runtime build script
# Yes, I hate having to type "./" _that_ much.
New-Alias -Name "build" -Value BuildRuntime
function BuildRuntime {
$root = $((git rev-parse --show-toplevel 2> $Null) ?? "").Replace("\", "/")
$runtime = (Resolve-Path "~/git/dotnet/runtime").Path.Replace("\", "/")
if ($root -eq $runtime) {
& "~/git/dotnet/runtime/build.cmd" $ARGS
} else {
echo "Not in the runtime repo"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment