mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2026-01-30 02:44:42 +01:00
hostname in cygwin doesn't support option -s
This commit is contained in:
parent
27c6becffd
commit
816c015cf5
1 changed files with 5 additions and 1 deletions
|
|
@ -8,7 +8,11 @@
|
|||
|
||||
# Machine name.
|
||||
function box_name {
|
||||
[ -f ~/.box-name ] && cat ~/.box-name || hostname -s
|
||||
if [[ `uname -o` == "Cygwin" ]]; then
|
||||
[ -f ~/.box-name ] && cat ~/.box-name || hostname
|
||||
else
|
||||
[ -f ~/.box-name ] && cat ~/.box-name || hostname -s
|
||||
fi
|
||||
}
|
||||
|
||||
# Directory info.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue