all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Info, dir, and Emacs packages ?
@ 2023-03-11  5:14 David Masterson
  2023-03-11 10:33 ` Philip Kaludercic
  0 siblings, 1 reply; 3+ messages in thread
From: David Masterson @ 2023-03-11  5:14 UTC (permalink / raw)
  To: emacs-devel

I'm missing something.  When and what causes a package directory to get
added to Info-directory-list? I've constructed a simple .info and dir
for an existing Emacs package I'm playing with, but, when I copy them to
the installed package and restart Emacs, it doesn't get added to the
Info-directory-list, so isn't seen by 'info'.  Any help?

-- David Masterson



^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Info, dir, and Emacs packages ?
  2023-03-11  5:14 Info, dir, and Emacs packages ? David Masterson
@ 2023-03-11 10:33 ` Philip Kaludercic
  2023-03-12  2:36   ` David Masterson
  0 siblings, 1 reply; 3+ messages in thread
From: Philip Kaludercic @ 2023-03-11 10:33 UTC (permalink / raw)
  To: David Masterson; +Cc: emacs-devel

David Masterson <dsmasterson@gmail.com> writes:

> I'm missing something.  When and what causes a package directory to get
> added to Info-directory-list? I've constructed a simple .info and dir
> for an existing Emacs package I'm playing with, but, when I copy them to
> the installed package and restart Emacs, it doesn't get added to the
> Info-directory-list, so isn't seen by 'info'.  Any help?

In `package-activate-1' (invoked by `package-activate' (invoked by
`package--activate-all' using `package--alist' (which uses
`package-load-all-descriptors'))) you will find this snippet:

--8<---------------cut here---------------start------------->8---
      ;; Add info node.
      (when (file-exists-p (expand-file-name "dir" pkg-dir))
        ;; FIXME: not the friendliest, but simple.
        (require 'info)
        (info-initialize)
        (add-to-list 'Info-directory-list pkg-dir))
--8<---------------cut here---------------end--------------->8---

So unless the dir or the .info file is broken (and this is an issue
caused by info), it might be that the package is not being detected?

-- 
Philip Kaludercic



^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Info, dir, and Emacs packages ?
  2023-03-11 10:33 ` Philip Kaludercic
@ 2023-03-12  2:36   ` David Masterson
  0 siblings, 0 replies; 3+ messages in thread
From: David Masterson @ 2023-03-12  2:36 UTC (permalink / raw)
  To: Philip Kaludercic; +Cc: emacs-devel

Philip Kaludercic <philipk@posteo.net> writes:

> David Masterson <dsmasterson@gmail.com> writes:
>
>> I'm missing something.  When and what causes a package directory to get
>> added to Info-directory-list? I've constructed a simple .info and dir
>> for an existing Emacs package I'm playing with, but, when I copy them to
>> the installed package and restart Emacs, it doesn't get added to the
>> Info-directory-list, so isn't seen by 'info'.  Any help?
>
> In `package-activate-1' (invoked by `package-activate' (invoked by
> `package--activate-all' using `package--alist' (which uses
> `package-load-all-descriptors'))) you will find this snippet:
>
>       ;; Add info node.
>       (when (file-exists-p (expand-file-name "dir" pkg-dir))
>         ;; FIXME: not the friendliest, but simple.
>         (require 'info)
>         (info-initialize)
>         (add-to-list 'Info-directory-list pkg-dir))
>
> So unless the dir or the .info file is broken (and this is an issue
> caused by info), it might be that the package is not being detected?

Interesting.  The package itself loads fine -- it's just not adding the
pkg-dir to Info-directory-list. This code suggests that it's not parsing
the 'dir' file -- it's simply just checks its existence.  The package is
in package-alist.

Oh, wait.  I put the dir/info files in the old package directory.  Doh!

-- 
David Masterson



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2023-03-12  2:36 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-03-11  5:14 Info, dir, and Emacs packages ? David Masterson
2023-03-11 10:33 ` Philip Kaludercic
2023-03-12  2:36   ` David Masterson

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.