Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a fair amount of experience with Cygwin and it's setup, however this time it is behaving strangely. When I installed it everything seemed to work great, but upon opening the Cygwin prompt I received none of the usual setup your account info lines. Upon looking in my c:/cygwin/home/ directory I found that it did not create a user for me or any of the files it normally does, like .bashrc, etc. I then set Cygwin to run as an Administrator, with no effect. Next I ran the cygwin.bat file as a possible fix suggested it might force the user profile file creation. Next I created a User directory of my name(the same as my windows user account name and what Cygwin is expecting from the /etc/passwd file) and put my .ssh directory in there and was able to use the ssh keys as normal to connect to remote servers. However, Cygwin still did not create any of the Cygwin files. I then chmod'ed the directory to 777 to make sure cygwin could write to it, also with no effect.

So it appears Cygwin is able to read from that directory but cannot or does not even try to create the user files.

share|improve this question
I'm not aware of any process to auto create this content. The last few times that I have installed Cygwin on a fresh system, I have created the .bash_profile, .bashrc, etc files myself by copying the templates in the /etc/skel folder. – Costa Sep 9 '13 at 14:25
hmm, whenever I have installed upon first starting an account it creates those files. – DrCord Sep 9 '13 at 18:36
The thing that really makes me think that something is wrong is it fails with a "cannot write" error to add to the known hosts file... – DrCord Sep 9 '13 at 18:36
up vote 1 down vote accepted

The answer to this question was fairly simple: I was unaware that the windows environment would be the first option for setting the $HOME variable, so cygwin was trying to read my config files from /cygdrive/c/User/[UserName] rather than /home/[UserName]. I put symbolic links to the cygwin location in my Windows user directory and that fixed the issue.

I was able to find enough useful info to help me debug my problem from this related superuser post: Cygwin .bashrc not being source because cygwin starting in Windows home

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .