Difference between revisions of "Bookmarks"

From WikEmacs
Jump to: navigation, search
m (Minor typo fix + how to set another bookmarks-file manually.)
m (Reverted edits by 31.41.216.134 (talk) to last revision by Holocronweaver)
 
(13 intermediate revisions by 9 users not shown)
Line 2: Line 2:
 
|name=recentf
 
|name=recentf
 
|description=helps opening a file that is recently visited  
 
|description=helps opening a file that is recently visited  
|source=http://git.savannah.gnu.org/cgit/emacs.git/tree/lisp/bookmarks.el
+
|source=http://git.savannah.gnu.org/cgit/emacs.git/tree/lisp/bookmark.el
|maintainer=[[FSF]]
+
|maintainer=[[Karl Fogel]] & [[FSF]]
 
|in_emacs=yes
 
|in_emacs=yes
 
|Development status=active
 
|Development status=active
Line 10: Line 10:
 
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.
 
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.
  
== Command about Bookmarks ==
+
== Usage ==
  
 
*C-x r m <RET> Set the bookmark for the visited file, at point.  
 
*C-x r m <RET> Set the bookmark for the visited file, at point.  
Line 18: Line 18:
 
*M-x bookmark-save Save all the current bookmark values in the default bookmark file.
 
*M-x bookmark-save Save all the current bookmark values in the default bookmark file.
  
== Changing the default bookmarks-file ==
+
== Customizations ==
By default, bookmarks are saved to the file <tt>~/.emacs.bmk</tt>, outside of your <tt>~/.emacs.d</tt> directory. To change this to another file, set the variable <tt>bookmark-default-file</tt> to what you like:
+
=== Changing the default bookmarks-file ===
 +
By default, bookmarks are saved to the file {{Filename|.emacs.bmk}}, outside of your {{Dirname|~/.emacs.d}} directory. To change this to another file, set the variable {{Variable|bookmark-default-file}} to what you like:
 
<syntaxhighlight lang="lisp">
 
<syntaxhighlight lang="lisp">
 
(setq bookmark-default-file "~/.emacs.d/bookmarks")
 
(setq bookmark-default-file "~/.emacs.d/bookmarks")
 
</syntaxhighlight>
 
</syntaxhighlight>
  
[[Category:Utilities]] [[Category:Bookmarks]]
+
[[Category:Utilities]]
[[Category:Native Package]] [[ Category:File Navigation]]
+
[[Category:Bookmarks]]
 +
[[Category:Built-in Package]]
 +
[[ Category:File Navigation]]

Latest revision as of 20:34, 30 January 2014

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

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.

Usage[edit]

  • 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.

Customizations[edit]

Changing the default bookmarks-file[edit]

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

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