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

Once I upgraded to Maverick Ubuntu, bash shell in gnome-terminal starts by default at root rather than my home directory, this was easily fixable by adding a cd command in .bashrc. However, this is undesirable for two reasons:

  • when new tabs are created in gnome-terminal, .bashrc executes, and the folder is set to the home directory, rather than the folder I was working in previously.
  • more importantly, some (not all) applications other than the terminal are also starting at root. The Emacs open file feature and the open file dialog of my programming IDE look for files at root by default.

Is there some environment variable that is the cause of all this?

share|improve this question

Is your home directory set correctly in /etc/passwd? It should read something like:

christi:x:1000:1000:christi,,,:/home/christi:/bin/bash

So the field before the last colon should point to your home dir.

share|improve this answer
    
Yes, that's exactly what I have – harsha Apr 12 '11 at 21:07

You must log in to answer this question.

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