[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]
Re: Rough start... (emacs byte-compiling)
- From: Karsten Wade <kwade redhat com>
- To: For participants of the docs project <fedora-docs-list redhat com>
- Subject: Re: Rough start... (emacs byte-compiling)
- Date: Tue, 31 Aug 2004 11:24:11 -0700
On Tue, 2004-08-31 at 11:20, Paul W. Frields wrote:
> On Tue, 2004-08-31 at 13:30, Dave Pawson wrote:
> > > Well, I'll be darned. It really is faster loading!
> >
> > The other trick, once documents become large, is to
> > 'compile' the dtd producing xyz.ced, which psgml then
> > uses, and it 'reads' the dtd so much quicker.
> > Probably not noticable until the file size is significant;
> > but well worth doing.
>
> Ah, now *that* I've done before. Since my markup of Strunk's book was in
> separate chapter files, that step was invaluable.
That's SOP for internal Red Hat guides, which are many multiple
chapters. So much so that one developer I worked with on a doc got so
tired of doing M-x sgml-load-dtd each time that he wrote this bit for
our .emacs files; it assigns C-c d to the task of loading a .ced file
(from the $PWD only):
;; Vadim Nasardinov's <vadimn redhat com> wrote this to save some
;; keystrokes when loading DTDs; this presumes the existence of only
;; one .ced file.
(defun rh-sgml-load-dtd ()
"Load the .ced file from the current directory."
(interactive)
(let* ((files (directory-files "." nil "\\.ced$"))
(ced-file (car files)))
(if (or (not ced-file)
(cdr files))
(error (format "Expected one .ced file, but found: %S" files))
(progn
(message (format "Loading the DTD from %s..." ced-file))
(sgml-load-dtd (car files))))))
(add-hook
'sgml-mode-hook
(lambda ()
(local-set-key "\C-cd" 'rh-sgml-load-dtd)))
--
Karsten Wade, RHCE, Tech Writer
a lemon is just a melon in disguise
http://people.redhat.com/kwade/
gpg fingerprint: 2680 DBFD D968 3141 0115 5F1B D992 0E06 AD0E 0C41
[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]