Wednesday, January 21, 2009

Change home directory in Cygwin

Put the new home directory in /etc/passwd file.

i.e. Change the following line from:
$ more /etc/passwd
userID:unused_by_nt/2000/xp:57827:10513:LastName, FirstName,DomanName\userID,S-1-5-21-1123561945-1708537768-1801674531-47827: /OldHome/userID:/bin/bash

to:
$ more /etc/passwd
userID:unused_by_nt/2000/xp:57827:10513:LastName, FirstName,DomanName\userID,S-1-5-21-1123561945-1708537768-1801674531-47827: /NewHome/userID:/bin/bash

No comments: