8

So when I add a new user, I want them to have a nice set of Nautilus bookmarks pre-loaded.

If I look in:

~/.config/gtk-3.0/bookmarks

I see this:

...
file:///home/myuserid/Documents
file:///home/myuserid/Music
file:///home/myuserid/Pictures
file:///home/myuserid/Videos
file:///home/myuserid/Downloads
...

Simple enough but actually not very helpful. How does this file get created?

user447607
  • 734
  • 2
  • 15
  • 34

1 Answers1

2

You can edit your own bookmarks file. On each line, specify a bookmark URL (either as file:///... or smb:// or ftp://, etc) followed by a space and a user-friendly name, which may contain spaces. Nautilus will pick it up automatically.

Jos
  • 28,156
  • 8
  • 82
  • 88
  • Probably, but wouldn't that usually involve some kind of scripting? The `useradd` command doesn't create the bookmark file; the above bookmarks are created at installation time. I merely explained how such a file could be created on the fly for a new user. – Jos Feb 12 '15 at 09:17
  • What I think happens is that nautilus copies it from somewhere or creates it the first time you launch it. Easy test. Move the file, and launch. – user447607 Feb 12 '15 at 20:00
  • Test results: Moving the file did not result in the creation of a new file on re-launch. Hm... – user447607 Feb 12 '15 at 20:04
  • 1
    I can put the file/directory structure in /etc/skel and that works except because they used file:// urls and don't appear to support Unix standards (for heaven's sake!) like environment variables and ~/, you are stuck with /home/the wrong user/ As far as I can tell the only way to fix is by scripting a sed command or something. :-/ – user447607 Feb 12 '15 at 20:14