Search code examples
cygwin

Changing Home Directory for cygwin


I know that this question has been asked before on this site, but I am very new with Cygwin and am really confused by a lot of the other answers.

What is the best method to change my home directory in Cygwin?


Solution

  • Perhaps the most easier way is to make a folder junction with mklink.exe windows command. Assuming that you would like to use windows home directory:

    1. Press Win + R and type cmd.
    2. rename your cygwin home e.g.: c:\cygwin\home\username --> username_backup
    3. type mklink /j c:\cygwin\home\username c:\Users\username
    4. if you would like to use the contents of your old home directory you should copy them to the new one