A FAQ do Cygwin explica como $HOME
está definido:
When starting Cygwin from Windows,
HOME
is determined as follows in order of decreasing priority:
HOME
from the Windows environment, translated to POSIX form.- The entry in
/etc/passwd
/home/USERNAME
When using Cygwin from the network (telnet, ssh,...),
HOME
is set from/etc/passwd
.If your
HOME
is set to a value such as/cygdrive/c
, it is likely that it was set in Windows. Start a DOS Command Window and typeset HOME
to verify if this is the case.Access to shared drives is often restricted when starting from the network, thus Domain users may wish to have a different
HOME
in the Windows environment (on shared drive) than in/etc/passwd
(on local drive). Note that ssh only considers/etc/passwd
, disregardingHOME
.
Meu melhor palpite é que você errou o arquivo /etc/passwd
. (O diretório base do Windows é %USERPROFILE%
, não %HOME%
.)
O que grep USERNAME /etc/passwd
imprime (substituindo USERNAME
pelo seu nome de usuário)?