help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: alternative to (require ...)


From: Kevin Rodgers
Subject: Re: alternative to (require ...)
Date: Tue, 24 Feb 2004 10:21:48 -0700
User-agent: Mozilla/5.0 (X11; U; SunOS i86pc; en-US; rv:0.9.4.1) Gecko/20020406 Netscape6/6.2.2

Sam Halliday wrote:

most of the 3rd party packages i have for emacs (such as color-theme, php-mode,
htmlize) are loaded in my ~/.emacs file by statements such as

  (require 'htmlize)

but if this package is not installed on the system, emacs bails on loading the
rest of my ~/.emacs file. this is quite annoying as i like to maintain a single
~/.emacs file and use it wherever i am using emacs.

is there an alternative command i can use, which doesn't result in emacs crying
if it can't find the package? or at least if there is an "if exists" check i
could do and incorporate into a wrapper function, say called (requests ...)

(condition-case nil
   (require 'foo)
 (error nil))


--
Kevin Rodgers



reply via email to

[Prev in Thread] Current Thread [Next in Thread]