Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free.

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 was wondering if anybody knew a command that would allow me to open a Nautilus (if that's the right name for the Ubuntu 12.04 graphic/window explorer) window from the command line at the current directory that the user is at.

So, if I open a command line, and type:

cd /home/myUser/some/long/path/to/a/directory

Then, I'd like to be able to issue some command:

nautilus open-sesame

And have a graphic window opened to /home/myUser/some/long/path/to/a/directory. Is this even possible?

share|improve this question
up vote 51 down vote accepted

You can type in the terminal:

cd /home/myUser/some/long/path/to/a/directory

and then:

nautilus .

The above command will open nautilus in the folder /home/myUser/some/long/path/to/a/directory (the period is the current directory)

Or in the Terminal just type:

nautilus /home/myUser/some/long/path/to/a/directory
share|improve this answer
1  
+1 I made an alias: alias n.='nautilus .' – Stat-R Dec 13 '13 at 18:25

You can also do gnome-open .. gnome-open is similar to open on Mac which tries to open the file using the best matching application. By default, gnome-open . on Ubuntu will open the current directory in Nautilus.

There is an open command in Ubuntu as well but it does not work in this case.

share|improve this answer

Stop Nautilus with:

$ nautilus -q

Then install package nautilus-open-terminal.

Restart Nautilus with:

$ nautilus

Right click in the right pane and choose Open in terminal

share|improve this answer
    
This is the opposite of what OP wants to do. – Andy Apr 19 at 19:54

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.