unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: Reiner Steib <4.uce.03.r.s@nurfuerspam.de>
Subject: Re: alternative to (require ...)
Date: Tue, 24 Feb 2004 18:36:26 +0100	[thread overview]
Message-ID: <v9y8qss7l1.fsf@marauder.physik.uni-ulm.de> (raw)
In-Reply-To: 403B882C.7030204@yahoo.com

On Tue, Feb 24 2004, Kevin Rodgers wrote:

> 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) 

Often you can `autoload' some functions instead of requiring the whole
package.

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

What's wrong with (require 'foo nil t)?

,----[ C-h f require RET ]
| require is a built-in function.
| (require FEATURE &optional FILENAME NOERROR)
| 
| [...]
| If the optional third argument NOERROR is non-nil,
| then return nil if the file is not found instead of signaling an error.
`----

Bye, Reiner.
-- 
       ,,,
      (o o)
---ooO-(_)-Ooo--- PGP key available via WWW   http://rsteib.home.pages.de/

  reply	other threads:[~2004-02-24 17:36 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-02-24 16:32 alternative to (require ...) Sam Halliday
2004-02-24 17:19 ` Eli Zaretskii
2004-02-24 17:21 ` Kevin Rodgers
2004-02-24 17:36   ` Reiner Steib [this message]
2004-02-24 17:40 ` David Kastrup
2004-02-24 18:47 ` Ole Laursen
2004-02-24 21:12 ` Jason Rumney
2004-02-24 22:41   ` Sam Halliday

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=v9y8qss7l1.fsf@marauder.physik.uni-ulm.de \
    --to=4.uce.03.r.s@nurfuerspam.de \
    --cc=reiner.steib@gmx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).