From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Hongyi Zhao Newsgroups: gmane.emacs.help Subject: Re: Emacs Modular Configuration: the preferable way. Date: Mon, 21 Jun 2021 18:26:50 +0800 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="1020"; mail-complaints-to="usenet@ciao.gmane.io" Cc: help-gnu-emacs To: Arthur Miller Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Mon Jun 21 12:48:58 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 1lvHUA-000AZx-S9 for geh-help-gnu-emacs@m.gmane-mx.org; Mon, 21 Jun 2021 12:48:58 +0200 Original-Received: from localhost ([::1]:55342 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lvHU9-0000Xa-RA for geh-help-gnu-emacs@m.gmane-mx.org; Mon, 21 Jun 2021 06:48:57 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:40664) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lvH91-0005rt-2R for help-gnu-emacs@gnu.org; Mon, 21 Jun 2021 06:27:07 -0400 Original-Received: from mail-lf1-x134.google.com ([2a00:1450:4864:20::134]:46752) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lvH8z-0006aU-2B for help-gnu-emacs@gnu.org; Mon, 21 Jun 2021 06:27:06 -0400 Original-Received: by mail-lf1-x134.google.com with SMTP id m21so29297591lfg.13 for ; Mon, 21 Jun 2021 03:27:04 -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 :cc; bh=QaYEC21GrCd8aXssb9eN/nSBuvYrxu+0p08UftYGnv4=; b=hM0okME78PqzTcH61gT2Ahr1SvF17VBRVPOYuKAL/QvBL3ZyLZTIvK6dEV6yFs1VUe 0p0FX/3VsU1OonkpHhZEz4tEVI0FVWEi0rEefAZBmWieH/cDN7zLqcorRTRJiZCZXlAD WKj3u1G8GqmlmOyA7VSdDKrw5gvC+xGs3T/l9u8/GXrvFoovVNwFC9VoVBzA15z8WUdY juv0T2/BEBfUHoMqVEaac4Ahcg3tGlPflvhT/uYPqUHnB8xx3qUIndWHumgByoTuSW3a HnviNdTjvtETmTO2voKOTQ18NNLyv2P0KQtBITUTKTJHP8SIgJS76KCXanOGRtDZrd1e dWpQ== 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:cc; bh=QaYEC21GrCd8aXssb9eN/nSBuvYrxu+0p08UftYGnv4=; b=b5uV+Y0jmU2a98ulXiwZG3p6gkL67q+LJ5v1fso38UOM1+64VXReovMdbybz842iZ4 8Xj1cLEGC2pXan7V+PztfqvldBnitX+m+SPk5NUJkfeU+Rol2zEs3ruMtJUCi0sK+Qzq kOwF4Zh8AW2Ml4UPqAEmCSSFweFaNIz+X2o9rMXuDPJFRtvx8KRsrN/zVylzddwwZNDf HHDIW9DaZqESh8t6scIAU3SVQHbtVH5ESsuKTyHmOefNzUbaNDmW2w5GOMwWc3dRQieW 1wsGvXZXxSU3ZQwpzF62NHN+RyAJtDhljOY2myajvPR2gPzgfizG/zlpyXjDpx8wrlH/ jKbw== X-Gm-Message-State: AOAM5328KewyzS0XlyDWyOwkk1pq856WkVU69QKnJZw8RT0q4bm8Awh8 aUWuJm1ACPisRPVn6tUF9mgG/K7MWFp0uSfe7e0= X-Google-Smtp-Source: ABdhPJzgDg+6c9GiiIZli7kzXGTqXm+K0AnICvEuMhHl13MhjWK0NnOXdgh7hFtSzgh6FEAzY8s4a5jX9XSz4hJlKIM= X-Received: by 2002:a19:ad46:: with SMTP id s6mr4174761lfd.466.1624271223198; Mon, 21 Jun 2021 03:27:03 -0700 (PDT) In-Reply-To: Received-SPF: pass client-ip=2a00:1450:4864:20::134; envelope-from=hongyi.zhao@gmail.com; helo=mail-lf1-x134.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:131135 Archived-At: On Mon, Jun 21, 2021 at 6:06 PM Arthur Miller wrote: > > Hongyi Zhao writes: > > > On Mon, Jun 21, 2021 at 2:40 PM Jean Louis wrote: > >> > >> * Hongyi Zhao [2021-06-21 04:51]: > >> > Dear all, > >> > > >> > I noticed the following instructions/tools for Emacs modular configuration: > >> > > >> > https://www.emacswiki.org/emacs/DotEmacsModular > >> > https://www.emacswiki.org/emacs/DotEmacsStructuring > >> > https://github.com/emacs-jp/init-loader > >> > > >> > There are so many ways to do this. What's the preferable way? > >> > >> Whatever you wish and want. You can feel if you need multiple files or > >> not. Solutions are very individuals. > > > > For now, my demand is as follows: > > > > 1. Use straight and use-package as the package manager. > > Why? Some special reason? For working/dealing with all packages, regardless that they are hosted by Emacs package repos or not. Straight works with git perfectly, and at the same time, it is also seamlessly integrates with use-package. > > > 2. All packages configuration file should call 1., especially for a > > testing scenario when debugging a package/several packages. > > Why? Just for sake of calling it or you have some better reason? Same as above. > > > 3. Better granular control based on different major mode, popular > > programming languages. > > > > You don't need straight, nor any special package for this, it is how > you structure your code. Check here, granularity is per package (mostly): > > https://github.com/amno1/.emacs.d/blob/main/init.org > > Nothing external required, just built-in stuff that comes out of the > box. Package.el is used to fetch packages from elpa/melpa and few > simple macros to save some typing, not even use-package needed and I > think it is pretty structured init file. I can even configure > early-init.el as it was a hook, which lets me structure entire init > process in one place. >From my experience, package.el's package fetch mechanism/speed is fragile and very poor by comparison with straight. Regards -- Assoc. Prof. Hongyi Zhao Theory and Simulation of Materials Hebei Vocational University of Technology and Engineering NO. 552 North Gangtie Road, Xingtai, China