Skip to content

Show ghostel bookmarks properly in the bookmark list - #614

Merged
dakra merged 1 commit into
mainfrom
feat/bookmark-list-metadata
Aug 7, 2026
Merged

dakra merged 1 commit into
mainfrom
feat/bookmark-list-metadata

Conversation

@dakra

@dakra dakra commented Aug 7, 2026

Copy link
Copy Markdown
Owner

Fixes #613.

bookmark-bmenu-list (C-x r l) showed ghostel bookmarks with a blank
Type column and -- Unknown location -- in the File column.

Two causes:

  • The record stored the working directory under a private thisdir key
    inherited from vterm. bookmark-location reads location (or
    filename), so it fell through to its unknown-location fallback.
  • ghostel--bookmark-handler carried no bookmark-handler-type symbol
    property, which is what bookmark-type-from-full-record reads to fill
    the Type column.

Both fixed as suggested in the issue: the directory moves to location,
and the handler gets (put 'ghostel--bookmark-handler 'bookmark-handler-type "Ghostel") — matching how shell.el,
esh-mode.el, and the rest of Emacs core do it.

Compatibility

Bookmarks saved by an earlier ghostel keep their thisdir key and will
no longer restore; the handler reads location exclusively. Bookmark
support only landed a few weeks ago, so this is deliberate rather than
carrying a fallback forever.

The put is inert before Emacs 29, which introduced the Type column.
location is read by every supported version, so nothing needs a
version guard or a compat shim.

Verification

make -j8 all is green. The maker test now asserts bookmark-location
— the value the File column actually renders — rather than just the raw
property, plus a new test for the handler type. Rendering the real
bookmark-bmenu-list over a ghostel record now gives:

    ghostel: proj                  Ghostel  /Users/daniel/.emacs.d/lib/ghostel/

The bookmark record stored its directory under a private thisdir key
inherited from vterm, and the handler carried no type property, so
bookmark-bmenu-list rendered a blank Type column and the fallback
"-- Unknown location --" for every ghostel bookmark.

Store the directory under location, the key bookmark-location reads,
and register the handler type so the Type column reads "Ghostel".
Records saved by earlier versions keep their thisdir key and no
longer restore; the handler is only a few weeks old and reads the
new key exclusively.

The type property is inert before Emacs 29, which introduced the column.

Fixes #613
@dakra
dakra merged commit 037378b into main Aug 7, 2026
29 checks passed
@dakra
dakra deleted the feat/bookmark-list-metadata branch August 7, 2026 21:55

This branch was previously deployed

1 inactive deployment
github-pages — 037378b4 Deployed Aug 7, 2026 by dakra via deploy #151
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Bookmark list improvements

1 participant