Changing the Default File Manager in Gnome

It doesn't come up very often, but every now and then, someone on the Ubuntu Forums wants to know how to change the default file manager in Gnome from Nautilus to something else. It's all been a big mystery until now. Special thanks to forum member ciscosurfer for starting to unravel the mystery. I'm hoping these scripts will finish the job, even though they don't work perfectly.

Changing from Nautilus to Thunar
Step 1: Download this script to your desktop.

Step 2: Paste these commands in the terminal:

cd ~/Desktop
chmod +x defaultthunar.sh
./defaultthunar.sh

Changing from Nautilus to Konqueror
Step 1: Download this script to your desktop.

Step 2: Paste these commands in the terminal:

cd ~/Desktop
chmod +x defaultkonqueror.sh
./defaultkonqueror.sh

Changing from Nautilus to Krusader
Step 1: Download this script to your desktop.

Step 2: Paste these commands in the terminal:

cd ~/Desktop
chmod +x defaultkrusader.sh
./defaultkrusader.sh

Restoring Nautilus as the default
If you wish to restore Nautilus as the default file manager in Gnome, download this script to your desktop and paste these commands in the terminal:

cd ~/Desktop
chmod +x restorenautilus.sh
./restorenautilus.sh