||3 weeks ago|
|.elisp-autofmt||1 year ago|
|LICENSE||1 year ago|
|bookmark-in-project.el||3 weeks ago|
|changelog.rst||12 months ago|
|readme.rst||1 year ago|
Bookmark in Project
By default Emacs built-in bookmark are global (shared across all projects), This package exposes functions that limit bookmarks to the current project.
Available via melpa.
When working on multiple projects at once, it's not always desirable to use a global list of bookmarks, especially for features such as jumping to the next/previous bookmarks.
This package aims to make working on a single project convenient without interfering the functionality of existing built-in commands.
This package doesn't make any and changes to Emacs bookmarking functionality. Instead it exposes commands which you may bind to keys
The key features provided are:
- Limit bookmark switching to other bookmarks in the same project.
- Support for toggling a bookmark (with automatic naming based on the context).
- Jump next/previous bookmark within the project.
All other built-in bookmarking functions can be used too, however all other projects bookmarks will be accessible too.
Jump to the next/previous bookmark in the current project.
Jump to another bookmark in the project (equivalent to
Create/delete a bookmark on the current line, named using
Delete all bookmarks in the project.
Note that in general these settings can be left as-is, but may be extended to adjust default behavior.
Function that finds the projects root-directory from the current buffer. This callback takes no arguments and must return a string or nil.
The default function uses
projectilewhen available, falling back to version-control and finally
default-directoryif all other methods fail.
Function that uses the current buffer and point to create a bookmark name. This function takes no arguments and returns a string or nil.
The default function uses the project relative file name and the context at or before the cursor-location (calculated using
A simpler callback is also provided, called:
Function that applies highlighting to the bookmarks. This function takes and returns a string representing the bookmark name.
To disable highlighting set the value to
Show a message when toggling bookmarks.
Show a message when jumping to next/previous bookmarks.
Jumping to bookmarks uses
ivywhen available, since it supports switching bookmarks without closing the completing read (see
Otherwise the default completing read is used.
Bookmarks are skipped when obscured by narrowing.
The package is available in melpa as
bookmark-in-project, here is an example with
(use-package bookmark-in-project :commands (bookmark-in-project-jump bookmark-in-project-jump-next bookmark-in-project-jump-previous bookmark-in-project-delete-all) ;; Example key bindings. :bind (("M-n" . bookmark-in-project-jump-next) ("M-p" . bookmark-in-project-jump-previous) ("M-*" . bookmark-in-project-toggle) ("M-o" . bookmark-in-project-jump)))