After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 560701 - ~/.recently-used.xbel cannot be a symlink
~/.recently-used.xbel cannot be a symlink
Status: RESOLVED WONTFIX
Product: gtk+
Classification: Platform
Component: Class: GtkRecent
2.14.x
Other All
: Normal normal
: ---
Assigned To: gtk-bugs
Emmanuele Bassi (:ebassi)
Depends on:
Blocks:
 
 
Reported: 2008-11-13 21:49 UTC by Richard Laager
Modified: 2016-04-10 16:35 UTC
See Also:
GNOME target: ---
GNOME version: 2.23/2.24


Attachments
A patch to fix this. (1.36 KB, patch)
2008-11-13 21:50 UTC, Richard Laager
none Details | Review

Description Richard Laager 2008-11-13 21:49:19 UTC
Please describe the problem:
I'd like to be able to move ~/.recently-used.xbel (to an encrypted ~/Private on Ubuntu). I tried doing this with a symlink, but it is overwritten.

Steps to reproduce:
1. touch ~/Private/.recently-used.xbel
2. rm ~/.recently-used.xbel
3. cd ; ln -s Private/.recently-used.xbel
4. gedit
5. Open some file.
6. Close gedit.


Actual results:
~/.recently-used.xbel is a file and no longer a symlink. The data has been written to ~.

Expected results:
~/.recently-used.xbel would still be a symlink and the data would've been written to ~/Private/.recently-used.xbel.

Does this happen every time?
Yes.

Other information:
If there is some other way to redirect this filename, please let me know. If there were some way to set a "filename" GObject property on every GtkRecentManager when it's created, that seems like it should work, based on the code.

Otherwise, I'll upload a patch which makes this honor symlinks. It uses g_file_read_link(), which was introduced in glib 2.4. I'm not sure if that's an issue.
Comment 1 Richard Laager 2008-11-13 21:50:45 UTC
Created attachment 122605 [details] [review]
A patch to fix this.
Comment 2 Behdad Esfahbod 2009-04-18 05:33:54 UTC
Doesn't sounds like a bad idea.
Comment 3 Emmanuele Bassi (:ebassi) 2016-04-10 16:35:59 UTC
This would break the use case of people symlinking recently-used.xbel to /dev/null to disable the recently used files.

Also, nothing happened in the last 7 years, so I doubt it'll happen now.