Remove 'kill' alias for Stop-Process cmdlet on Unix (#10098)

This commit is contained in:
Ilya 2019-07-15 08:12:26 +05:00 committed by GitHub
parent 540737ebe1
commit 0ae7d50d5c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 1 deletions

View File

@ -4616,7 +4616,9 @@ end {
new SessionStateAliasEntry("dir", "Get-ChildItem", string.Empty, AllScope),
new SessionStateAliasEntry("echo", "Write-Output", string.Empty, AllScope),
new SessionStateAliasEntry("fc", "Format-Custom", string.Empty, ReadOnly),
#if !UNIX
new SessionStateAliasEntry("kill", "Stop-Process"),
#endif
new SessionStateAliasEntry("pwd", "Get-Location"),
new SessionStateAliasEntry("type", "Get-Content"),
// #if !CORECLR is used to disable aliases for cmdlets which are not available on OneCore or not appropriate for PSCore6 due to conflicts

View File

@ -94,7 +94,7 @@ Describe "Verify approved aliases list" -Tags "CI" {
"Alias", "ise", "powershell_ise.exe", $($FullCLR ), "ReadOnly", "", ""
"Alias", "iwmi", "Invoke-WMIMethod", $($FullCLR ), "ReadOnly", "", ""
"Alias", "iwr", "Invoke-WebRequest", $($FullCLR -or $CoreWindows -or $CoreUnix), "ReadOnly", "", ""
"Alias", "kill", "Stop-Process", $($FullCLR -or $CoreWindows -or $CoreUnix), "", "", ""
"Alias", "kill", "Stop-Process", $($FullCLR -or $CoreWindows ), "", "", ""
"Alias", "lp", "Out-Printer", $($FullCLR ), "ReadOnly", "", ""
"Alias", "ls", "Get-ChildItem", $($FullCLR -or $CoreWindows ), "", "", ""
"Alias", "man", "help", $($FullCLR -or $CoreWindows ), "", "", ""