How can I add a bookmark for recent files in Nautilus on Ubuntu 12.04.3 LTS?
You can try to upgrade several important packages (gvfs, glib, etc.) from the webupd8team/gvfs-libmtp ppa, to mount the "recent:///" URI in Nautilus 3.4.
NOTE: Due to you are going to upgrade important packages of your system, I strongly recommend to do this in a Virtual Machine or in a Test Machine to see is everything is OK.
In this example I'm running Ubuntu 12.04 with Nautilus 3.4.2.
Add PPA & upgrade packages.
1) Open a Terminal window and type the following in order to add the ppa and upgrade the packages.
sudo add-apt-repository ppa:webupd8team/gvfs-libmtp
sudo apt-get update && sudo apt-get upgrade
sudo apt-get dist-upgrade
2) Reboot your system.
3) Test if you can mount the recent uri.
- Open nautilus, then Ctrl+L, then type recent:/// , then Enter to see if you can mount the recent files location.
Then to add as a Bookmark... in the recent uri mounted just press Ctrl+D.
NOTE:Now if you want to add recent not in bookmarks... just in the side panel under computer, above the Home directory like Nautilus 3.6... You should edit the nautilus 3.4 source code.
Add Recent Files to Nautilus Panel.
1) Make sure you have enable the Source code repository
- Open the Ubuntu Software Center
- In the Menu Bar choose Edit -> Software Sources. Click to enable "Source code repository". Just in case I use the "Main Server" to Download.
Open a Terminal window and type:
sudo apt-get update
2) In the Terminal window type the following to install the necessary packages.
sudo apt-get install build-essential quilt
3) Install build dependencies.
sudo apt-get build-dep nautilus
4) Create a folder to download the source code.
5) Download the source code & Export variables.
apt-get source nautilus
6) Create the patch and Edit the source code.
quilt new 99_my_custom_recent.patch
quilt edit src/nautilus-places-sidebar.c
After line 694 add:
/* Recent Files */ mount_uri = "recent:///"; icon = g_themed_icon_new ("document-open-recent"); add_place (sidebar, PLACES_BUILT_IN, SECTION_COMPUTER, _("Recent"), icon, mount_uri, NULL, NULL, NULL, 0, _("Recent files")); g_object_unref (icon);
Save the changes and close gedit.
NOTE: If you are not using English Language.. feel free to translate and write the string "Recent" and the tooltip string "Recent files" in your Language.
7) Build the deb packages.
8) Install the deb packages.
sudo dpkg -i *deb
9) Finally you can logout and Login to see the changes.
Hope this helps.