[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#64842: 30.0.50; org-mode hook doesn't load as expected
From: |
Eli Zaretskii |
Subject: |
bug#64842: 30.0.50; org-mode hook doesn't load as expected |
Date: |
Tue, 25 Jul 2023 14:52:25 +0300 |
> Date: Tue, 25 Jul 2023 01:37:12 +0000
> From: Protonmail via "Bug reports for GNU Emacs,
> the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
>
> I add several modes hooks to org-mode via `use-package` and `straight.el`.
> However, it doesn't load
> any of them as it did in several previous versions.
>
> Here is my configuration:
>
> ```elisp
> (use-package org
> ;;:straight (:type built-in)
> :ensure org-plus-contrib
> :hook
> (
> (org-mode . org-indent-mode)
> (org-mode . visual-line-mode)
> (org-mode . ejira-mode)
> ))
> ```
>
> Regardless of whether `:straight (:type built-in)` is configured or not, the
> modes that are being hooked
> don't load.
AFAICT, you are using :hook incorrectly. The "Hooks" node of the
use-package manual explains how to use it correctly. In a nutshell,
:hook is not for adding stuff to the hook of the package you are
declaring with use-package.