Reputation: 96408
After typing C-x r l
I get a buffer called *Bookmark List*
In this buffer I see:
Bookmark file:
/tmp/bmkp-temp/19236bkt
If I open help (i.e. press h
), I see:
Bookmark file: /tmp/bmkp-temp-19236bkt
Sorted:
Filtering: none
Marked: 0
Omitted: 0
Autosave bookmarks: no
Autosave list display: yes
This is even though I have the following in my .emacs
file:
(setq bookmark-file "~/.emacs.d/bookmarks")
(setq bookmark-default-file "~/.emacs.d/bookmarks")
(setq bmkp-default-bookmark-file "~/.emacs.d/bookmarks")
(setq bmkp-last-as-first-bookmark-file nil)
Why is it using a different bookmark file from the one I specified?
I also noticed that when I load Emacs the following happens:
Emptying bookmark file `/tmp/bmkp-temp-23808OMn'...
Saving file /tmp/bmkp-temp-23808OMn...
Wrote /tmp/bmkp-temp-23808OMn
Emptying bookmark file `/tmp/bmkp-temp-23808OMn'...done
...
Helm completion enabled
Emptying bookmark file `/tmp/bmkp-temp-23808bWt'...
Saving file /tmp/bmkp-temp-23808bWt...
Wrote /tmp/bmkp-temp-23808bWt
Emptying bookmark file `/tmp/bmkp-temp-23808bWt'...done
...
Emacs goes on a spree deleting temporary bookmark files. ?
Upvotes: 4
Views: 625
Reputation: 333
It's quite an old question, but since I had just the same problem and the other answers didn't help me I'll post my solution:
I'm using desktop files from desktop.el and the temporary mode was set there in the desktop file! Removing that setting from all my desktop files fixed the problem.
This might be handy:
find ~ -name .emacs.desktop -print0 | xargs -0 grep -l bmkp-temporary-bookmarking-mode
Upvotes: 0
Reputation: 30708
It looks like something, somewhere (e.g. check your .emacs file) has turned on bmkp-temporary-bookmarking-mode
. When that mode is on, any bookmarks you create are for the current session only -- they are not saved to your bookmark file.
And that means that your bookmark-file location settings are ignored. (Note, BTW, that bmkp-default-bookmark-file
is a function, not a variable -- it is not something that you set. And you don't need all of those bookmark-file settings; some are redundant: old names from old versions of Emacs bookmarking.)
I don't know why you are getting multiple temporary bookmark-file creations and saves. You didn't provide a complete recipe. You should get only one such. This is all I see in *Messages*
in this regard, for instance:
Emptying bookmark file `c:/DOCUME~1/me/LOCALS~1/Temp/bmkp-temp-5348su1'... Saving file c:/Documents and Settings/me/Local Settings/Temp/bmkp-temp-5348su1... Wrote c:/Documents and Settings/me/Local Settings/Temp/bmkp-temp-5348su1 Emptying bookmark file `c:/DOCUME~1/me/LOCALS~1/Temp/bmkp-temp-5348su1'...done
It also appears that you have a lot of stuff going on (Helm etc.). When trying to understand or debug a problem, it helps to narrow things down as much as possible. Who can tell what other interactions might be involved here?
All of that said, my advice would be to not start out using the temporary bookmarking mode. I would not suggest you use that until you are quite familiar with Bookmark+. You can use temporary bookmarks without using this mode.
Here is the doc about using temporary bookmarks: http://www.emacswiki.org/cgi-bin/wiki/BookmarkPlus#toc55
Finally, as Stefan suggested, please follow up by email. It's a lot easier for debugging/discussing things in detail.
Thx -- Drew
Update 2019-04-21:
I think what might have happened is that you quit Emacs with bmkp-temporary-bookmarking-mode
enabled. Although Bookmark+ (correctly) does not save the file of temporary bookmarks it was not preventing the recording of bmkp-last-as-first-bookmark-file
from being updated to point to the temporary file. In your next Emacs session that temporary file (if it still existed) was loaded because of bmkp-last-as-first-bookmark-file
.
That should be OK now. Enabling bmkp-temporary-bookmarking-mode
now resets bmkp-last-as-first-bookmark-file
to nil
, so if you quit with the temp mode still enabled, then when you load your bookmark file in a new session the file that is read is the value of bookmark-default-file
. (The value of bookmark-default-file
is never changed, except by your
customizations.)
Upvotes: 1
Reputation: 2076
Perhaps you were trying to use "bookmark-file bookmarks"? Or anyways, accidently hit C-x p x
?
These are claimed to correspond, at EmacsWiki: Bookmark Plus / Bookmark-File Bookmarks, where they say, "bmkp-set-bookmark-file-bookmark
, bound to C-x p x
". For my Emacs, this is not true.
By typing C-x p C-h
, I can check key-bindings that start with C-x p
. I find
C-x p x
is bound to bmkp-toggle-autotemp-on-set
, and
C-x p y
is bound to bmkp-set-bookmark-file-bookmark
.
Then, the link should say C-x p y
instead.
Upvotes: 1