Bookmarks

From WikEmacs
Revision as of 15:55, 31 March 2012 by Monotux (talk | contribs) (Minor typo fix + how to set another bookmarks-file manually.)
Jump to navigation Jump to search

Bookmarks are somewhat like registers in that they record positions you can jump to. Unlike registers, they have long names, and they persist automatically from one Emacs session to the next. The prototypical use of bookmarks is to record “where you were reading” in various files.

recentf
Description helps opening a file that is recently visited
Author name of author
Maintainer FSF
Source http://git.savannah.gnu.org/cgit/emacs.git/tree/lisp/bookmarks.el
Part of Emacs yes

Command about Bookmarks

  • C-x r m <RET> Set the bookmark for the visited file, at point.
  • C-x r m bookmark <RET> Set the bookmark named bookmark at point (bookmark-set).
  • C-x r b bookmark <RET> Jump to the bookmark named bookmark (bookmark-jump).
  • C-x r l List all bookmarks (list-bookmarks).
  • M-x bookmark-save Save all the current bookmark values in the default bookmark file.

Changing the default bookmarks-file

By default, bookmarks are saved to the file ~/.emacs.bmk, outside of your ~/.emacs.d directory. To change this to another file, set the variable bookmark-default-file to what you like:

(setq bookmark-default-file "~/.emacs.d/bookmarks")