this post was submitted on 28 Oct 2023
2 points (100.0% liked)

Emacs

313 readers
3 users here now

A community for the timeless and infinitely powerful editor. Want to see what Emacs is capable of?!

Get Emacs

Rules

  1. Posts should be emacs related
  2. Be kind please
  3. Yes, we already know: Google results for "emacs" and "vi" link to each other. We good.

Emacs Resources

Emacs Tutorials

Useful Emacs configuration files and distributions

Quick pain-saver tip

founded 1 year ago
MODERATORS
 

(use-package elfeed)

(leader-key "w" elfeed)

Is it possible to combine the two in a simple way? I tried using :general keyword in use-package ensuring that it loads after general, but it still does not work...

you are viewing a single comment's thread
view the rest of the comments
[–] github-alphapapa@alien.top 1 points 1 year ago (1 children)

Why did you add :after general? I use :general in many of my use-package forms, but never have I added that.

[–] g06lin@alien.top 1 points 1 year ago (1 children)

hmmm... without it I assumed I would get an error about unrecognized keyword. In any case, I tried this configuration again and I am getting the same error.

```Error (use-package): Failed to parse package elfeed: use-package: Unrecognized keyword: :general```

(Regardless of whether I use `:after general`)

[–] g06lin@alien.top 1 points 1 year ago (1 children)

I found an old post from you (https://www.reddit.com/r/emacs/comments/ogiiyp/in_2021_what_is_the_state_of_the_art_in_emacs/), and I tried the following, and it worked! Thanks a ton!!!

(use-package elfeed :config (leader-key "w" #'elfeed))

where leader-key is a key definer created using general-create-definer

But I don't know why :general does not work in my config.

[–] g06lin@alien.top 1 points 1 year ago

Ah.... made a mistake! It does not work.

:config only fires after the package is loaded, but this key binding in :config is the one loading the package. Bad! For now, moved these bindings to :config of general.

It would be nice if I can figure out why :general does not work with use-package.