From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Yuri Khan Newsgroups: gmane.emacs.help Subject: Re: require (was: Re: Hooks in minor modes) Date: Tue, 4 May 2021 12:40:42 +0700 Message-ID: References: <87wnsktmqp.fsf@zoho.eu> <87sg38tmag.fsf_-_@zoho.eu> <87tunoictd.fsf@zoho.eu> <87mttfh224.fsf@zoho.eu> <87eeerfge1.fsf@zoho.eu> <877dkjdlxm.fsf@zoho.eu> <87czu7mdt8.fsf@zoho.eu> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="36296"; mail-complaints-to="usenet@ciao.gmane.io" To: Emanuel Berg , help-gnu-emacs Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Tue May 04 07:41:36 2021 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ldnoO-0009MJ-Fq for geh-help-gnu-emacs@m.gmane-mx.org; Tue, 04 May 2021 07:41:36 +0200 Original-Received: from localhost ([::1]:38228 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ldnoN-00017v-Hk for geh-help-gnu-emacs@m.gmane-mx.org; Tue, 04 May 2021 01:41:35 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:58476) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ldnnk-00017n-BF for help-gnu-emacs@gnu.org; Tue, 04 May 2021 01:40:56 -0400 Original-Received: from mail-vs1-xe32.google.com ([2607:f8b0:4864:20::e32]:39861) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ldnni-0005wg-QU for help-gnu-emacs@gnu.org; Tue, 04 May 2021 01:40:56 -0400 Original-Received: by mail-vs1-xe32.google.com with SMTP id v188so4164596vsb.6 for ; Mon, 03 May 2021 22:40:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :content-transfer-encoding; bh=nyUtQHXtvrv+8Uus+A8lC3ZgfbCMP/S83dzw0EERdFk=; b=GiKiX813MTp896oJoR0/sQLjxdUIbFFnchBWXTua9lRlOdLF8g6gdz+Pts31YAZ6+8 NYUFCK06JZl3bxpw7S6YFEanhiK4i0G9J1C6t4eCNiF3+5L25RuRf0aG8YyB+BEDegR8 rkNqH8era6MQ6ZC50JwUZn2wElTS1C0ppINV5pBor9IIHk1plLmaQ8s5JFNXGiA3FOD/ Se7NqUkA3zz6S+RfqpB8L09HwP2MAMazFXCbEnoVf93DhfExaqkcPOFEpn6XDr+Rfs+E TUQgMVlglKpWGhGmhPpVMI152xFqF7epvWCea0osIBiwVxOMPtI3rkt6NMtk/GUJXPTQ XOhg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:content-transfer-encoding; bh=nyUtQHXtvrv+8Uus+A8lC3ZgfbCMP/S83dzw0EERdFk=; b=SVdRiO0V+G/BH4ZmeywZ+MR2sTXCdxAFjC99f93o7AeTjKzour99QBpi1Mkoqi8lss SnWyg1Ebk7sPirWphe6e/WA95Xbbh+vCkFofPttfgj4NYCMdqU3LBnUMezXk1VAxzewC leRX07F9p3yLVmKoVi4ErJH6nVErTkjaPJixk8O/iJinsVIBLaPYibJacJWReP0z8PcJ qdnh664+XPnE3C1mdLkq3om0R9eG2q8IP1Gm8FQ4zzUBw5T1zq0ZSSGQro1lEKqQOT6q rNXRrBKT6PEbObvWDkle0XF2IwdIsqP5+C7yIY9QxW6xKbhi0HVBHUTRVvDgj9JfSi25 KZLA== X-Gm-Message-State: AOAM533k6ziL0mjBNzKzXMVtzUdIzdoq3X70FqeggqmeDQ7uX6zsTsEb fWOhFHhYHRQUcKRf5KYW3cPSge9EpmogYpwUKpVrqMbvl4Llkg== X-Google-Smtp-Source: ABdhPJxzmd3DjBH04fHHv4QfCF/fOH5zdVMNBkDZobiqF/iRylVhBdtYDufmgtJBdqS0osyH4RgI/OLa8gXLpHD7P78= X-Received: by 2002:a67:c283:: with SMTP id k3mr5435920vsj.12.1620106853779; Mon, 03 May 2021 22:40:53 -0700 (PDT) In-Reply-To: <87czu7mdt8.fsf@zoho.eu> Received-SPF: pass client-ip=2607:f8b0:4864:20::e32; envelope-from=yurivkhan@gmail.com; helo=mail-vs1-xe32.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "help-gnu-emacs" Xref: news.gmane.io gmane.emacs.help:129400 Archived-At: On Tue, 4 May 2021 at 09:30, Emanuel Berg via Users list for the GNU Emacs text editor wrote: > The objective is to make sure when you `require' B from A, > as long as they are in the same directory, A will find B, > because A will first look in its own directory. It does not work that way. Relative directory names in load-path are not resolved against the =E2=80=98require=E2=80=99ing file. $ cat /tmp/test-load-path/foo/xyzzy.el (require 'plugh) (message "foo/xyzzy") (provide 'xyzzy) $ cat /tmp/test-load-path/foo/plugh.el (message "foo/plugh") (provide 'plugh) $ emacs -Q (add-to-list 'load-path ".") (load-library "/tmp/test-load-path/foo/xyzzy.el") =E2=87=92 Lisp error: (file-missing "Cannot open load file" "No such file o= r directory" "plugh")