Skip to content
This repository has been archived by the owner on Feb 16, 2021. It is now read-only.

Commit

Permalink
Comply with POSIX
Browse files Browse the repository at this point in the history
All Linux and Mac systems have `hostname`, but `uname -n` will continue working if PowerShell is released on other POSIX systems.
  • Loading branch information
pavelbraginskiy authored and JanDeDobbeleer committed Jul 26, 2018
1 parent b43b113 commit 5080d38
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Helpers/Prompt.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ function Get-ComputerName {
if ($env:NAME) {
return $env:NAME
} else {
return (hostname)
return (uname -n)
}
}
return $env:COMPUTERNAME
Expand Down

0 comments on commit 5080d38

Please sign in to comment.