Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I want to achieve the following:

  • I have a Nautilus windows showing the /foo/bar dir.
  • I hit Ctrl+n (new window).
  • I want the new window to show /foo/bar instead of my home dir.
share|improve this question
    
Why not use a tab instead- Ctrl + t? –  i08in May 28 at 12:02
2  
It is easier to drag'n'drop between windows than tabs –  kispaljr May 28 at 12:03

2 Answers 2

up vote 3 down vote accepted

There is no option for changing or customizing the New Window action behavior.

But you can create a nautilus script with the behavior you want and use it instead of the built in action. It's a one-liner that simply opens Nautilus at a given folder. In your case, the current folder. Save the script at ~/.gnome2/nautilus-scripts (~/.local/share/nautilus/scripts for Ubuntu 13.04 onwards).

To invoke such script with CTRL+N you must edit ~/.gnome2/accels/nautilus (~/.local/share/nautilus/accels for 13.04+) and edit the corresponding lines for both your script and New Window builtin action.

You could also request this feature at gnome buglist for Nautilus:

https://bugzilla.gnome.org/browse.cgi?product=nautilus

share|improve this answer

This Nautilus script should do the trick:

#!/bin/bash
# opens new Nautilus window showing the same folder

nautilus "$NAUTILUS_SCRIPT_CURRENT_URI"

General installation instructions for Nautilus scripts and assigning Nautilus keyboard shortcuts.

share|improve this answer
    
@MestreLion Well, keyboard assignments do work on older releases of Ubuntu but you are right, we didn't really have a canonical answer concerning keyboard shortcuts for Nautilus. I edited my generic installation instructions to add a section on that. –  Glutanimate May 30 at 13:02
    
Wow, fantastic! Your updated answer has all the pieces of the puzzle. It should be the accepted answer, at least until someone (either of us?) post the details for his specific scenario –  MestreLion Jun 1 at 13:03

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.