Function: info-xref-check
info-xref-check is an autoloaded, interactive and byte-compiled
function defined in info-xref.el.gz.
Signature
(info-xref-check FILENAME)
Documentation
Check external references in FILENAME, an info document.
Interactively from an Info-mode or texinfo-mode buffer the
current info file is the default.
Results are shown in a compilation-mode buffer. The format is
a bit rough, but there shouldn't be many problems normally. The
file:line:column: is the info document, but of course normally
any correction should be made in the original .texi file.
Finding the right place in the .texi is a manual process.
When a target info file doesn't exist there's obviously no way to validate node references within it. A message is given for missing target files once per source document. It could be simply that you don't have the target installed, or it could be a mistake in the reference.
Indirect info files are understood, just pass the top-level
foo.info to info-xref-check and it traverses all sub-files.
Compressed info files are accepted too as usual for Info-mode.
"makeinfo" checks references internal to an info document, but
not external references, which makes it rather easy for mistakes
to creep in or node name changes to go unnoticed.
Info-validate doesn't check external references either.
Key Bindings
Source Code
;; Defined in /usr/src/emacs/lisp/info-xref.el.gz
;;-----------------------------------------------------------------------------
;;;###autoload
(defun info-xref-check (filename)
"Check external references in FILENAME, an info document.
Interactively from an `Info-mode' or `texinfo-mode' buffer the
current info file is the default.
Results are shown in a `compilation-mode' buffer. The format is
a bit rough, but there shouldn't be many problems normally. The
file:line:column: is the info document, but of course normally
any correction should be made in the original .texi file.
Finding the right place in the .texi is a manual process.
When a target info file doesn't exist there's obviously no way to
validate node references within it. A message is given for
missing target files once per source document. It could be
simply that you don't have the target installed, or it could be a
mistake in the reference.
Indirect info files are understood, just pass the top-level
foo.info to `info-xref-check' and it traverses all sub-files.
Compressed info files are accepted too as usual for `Info-mode'.
\"makeinfo\" checks references internal to an info document, but
not external references, which makes it rather easy for mistakes
to creep in or node name changes to go unnoticed.
`Info-validate' doesn't check external references either."
(interactive
(list
(let* ((default-filename
(cond ((eq major-mode 'Info-mode)
Info-current-file)
((eq major-mode 'texinfo-mode)
;; look for @setfilename like makeinfo.el does
(save-excursion
(goto-char (point-min))
(if (re-search-forward
"^@setfilename[ \t]+\\([^ \t\n]+\\)[ \t]*"
(line-beginning-position 100) t)
(expand-file-name (match-string 1)))))))
(prompt (if default-filename
(format "Info file (%s): " default-filename)
"Info file: ")))
(read-file-name prompt nil default-filename t))))
(info-xref-check-list (list filename)))