From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id GNm4MkbDsGNEfwEAbAwnHQ (envelope-from ) for ; Sun, 01 Jan 2023 00:18:30 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id GIReMkbDsGM9WQAAauVa8A (envelope-from ) for ; Sun, 01 Jan 2023 00:18:30 +0100 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 8F0994EE5 for ; Sun, 1 Jan 2023 00:18:30 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pBl6v-0001Ov-Ta; Sat, 31 Dec 2022 18:17:53 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pBl6t-0001Of-Ip for guix-devel@gnu.org; Sat, 31 Dec 2022 18:17:52 -0500 Received: from mx2.dismail.de ([159.69.191.136]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pBl6r-0000sP-7c for guix-devel@gnu.org; Sat, 31 Dec 2022 18:17:51 -0500 Received: from mx2.dismail.de (localhost [127.0.0.1]) by mx2.dismail.de (OpenSMTPD) with ESMTP id 4215841a; Sun, 1 Jan 2023 00:17:43 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed; d=dismail.de; h=from:to:cc :subject:in-reply-to:references:date:message-id:mime-version :content-type; s=20190914; bh=tenHnZ3zDx9Nn+r4P6i3vXdJYOluxHv661 Fkgtcb77g=; b=cojPSWmkyFftziLIbuL2PDj7op16PcwYyesnnKoGtgw9KnBhPj KLDc1PsDx1pf9SCsS+w5VklI+REr+WBIoTbUhQ4GQvHFoi0xn7RhKoQJbddHERzi nc6jojuY9gfov/yEgid/AUSui5lHs7XS5JVtXDW3tC/hiJMPekmYseWnziKVstvL G0yMP/gS+vk4bAy2McLvtitPpWwCoyzlwRsITbcJVpiJiHF+Vu9tZZqyAwQO73tS /vFWqynp9/Du674Ucw2Ht+Mb8+C2Y6ehSGsLjm+uvYSaHT3gtR95NtvhtofcQSnV mTuMp4/bPO4/XS9tRiI51I1BUC9RjMLbfYuw== Received: from smtp1.dismail.de ( [10.240.26.11]) by mx2.dismail.de (OpenSMTPD) with ESMTP id e0f99c47; Sun, 1 Jan 2023 00:17:43 +0100 (CET) Received: from smtp1.dismail.de (localhost [127.0.0.1]) by smtp1.dismail.de (OpenSMTPD) with ESMTP id 9e9f3abd; Sun, 1 Jan 2023 00:17:43 +0100 (CET) Received: by dismail.de (OpenSMTPD) with ESMTPSA id 53e4e5a5 (TLSv1.3:TLS_AES_256_GCM_SHA384:256:NO); Sun, 1 Jan 2023 00:17:43 +0100 (CET) From: Joshua Branson To: Feng Shu Cc: guix-devel@gnu.org Subject: Re: Suggest improve emacs setting in 'The Perfect Setup' In-Reply-To: <87k02990ee.fsf@163.com> (Feng Shu's message of "Fri, 30 Dec 2022 08:54:17 +0800") References: <87k02990ee.fsf@163.com> User-Agent: Gnus/5.13 (Gnus v5.13) X-Gnus-Sucks: I know man Date: Sat, 31 Dec 2022 18:17:30 -0500 Message-ID: <87mt73jh85.fsf@dismail.de> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=159.69.191.136; envelope-from=jbranso@dismail.de; helo=mx2.dismail.de X-Spam_score_int: -43 X-Spam_score: -4.4 X-Spam_bar: ---- X-Spam_report: (-4.4 / 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, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: guix-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+larch=yhetil.org@gnu.org Sender: guix-devel-bounces+larch=yhetil.org@gnu.org X-Migadu-Country: US X-Migadu-Flow: FLOW_IN ARC-Seal: i=1; s=key1; d=yhetil.org; t=1672528710; a=rsa-sha256; cv=none; b=XgL1AKKCQufPQHjh7Bc2Clypt7+RbdmrkiKQ66TFV0OGW/NRz1bExfDq907vSuTu8h9iF0 xiMKPJXeDYRjIsdoCtfYjxV6U0lI/nJGSleNLssW/BpfDs7PhpKnb4XiGjnoRNWs4k5UUD IHbxt1G+R5vxx2rJJMss9vwu7YoTL+EWE/d0jk23ra2Z6pQHkG/3daAawnwTzyTjggcxW1 QsZuOtP40ugbUWhMglgHxrcKmqmJad5DA1JdxLHej2dShZWQxcSPbTTbvB2V6o6abLSUfq zHCdzOxVtRmH5WwSiQ6e78JfOlehOp349orOo0QQJR7jayHqIQUAfaUaW8DCuw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=dismail.de header.s=20190914 header.b=cojPSWmk; spf=pass (aspmx1.migadu.com: domain of "guix-devel-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-devel-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=reject) header.from=dismail.de ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1672528710; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=eHZ/75AGj0GNzA3bIrFr2nriftm4eshFgwdyEtpQefI=; b=ZIzOcnb67q8x5SelcXMUPnwWLoi4UBtP9eWF4asCHU0RvCsj6knQZ5YQAluqxh41XEybKk JRX88q/C+EPnuI0Gb36O2lp4GwPlL6PMw3Bcg1G5Kcw9O6iGkGPafiQpgcmrXwFUwprEbV jqs6IZKWY4kqIzAgckKXbtGP7rSn2220XjsRlFnTetTQ1st40UxtrcMYLagpDHKZTnIBdw SqjWf4kuUoE363lvJRrvTwLjOFCcA6XIF/YNyUyM9KszcpbFL4t7BA55nXTFEIgbUrHUBL lo0WpicQtkI5ljf9kgCKiVP5gFEKIP5XVtI6B01cF05iZo/BPxwv/57OqeMo1g== X-Spam-Score: -9.61 X-Migadu-Queue-Id: 8F0994EE5 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=dismail.de header.s=20190914 header.b=cojPSWmk; spf=pass (aspmx1.migadu.com: domain of "guix-devel-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-devel-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=reject) header.from=dismail.de X-Migadu-Scanner: scn0.migadu.com X-Migadu-Spam-Score: -9.61 X-TUID: L3bLgWBju5fl Feng Shu writes: > Hello: > > In 'The Perfect Setup', we suggest user to use the below emacs config: > > ``` > ;; Assuming the Guix checkout is in ~/src/guix. > (with-eval-after-load 'geiser-guile > (add-to-list 'geiser-guile-load-path "~/src/guix")) > ``` > > This config need user to deal with %load-path of guix, which seem to be > a hard job for new guile user for many dirs of guix and other guix channels, > why not suggest new user to use the below config: > How about you go ahead and make a patch on guix-patches@gnu.org, that way this issue is not forgotten? > > ``` > (setq geiser-guile-binary (list "guix" "repl")) > ``` > > > or: > > ``` > (setq geiser-guile-binary (list "guix" "repl" "-L" "/path/to/user-own-config-dir")) > ``` > > when user just want to develop his own guix config, just run: > > ``` > emacs > ``` > > guix and other channels installed by 'guix pull' will be used properly. > > when user want to develop in guix.git, he just run emacs like the below: > > ``` > ./pre-inst-env emacs > ``` > > The below is my guix emacs config, seem to work: > > -------------------------------------------------------------------------------- > > (require 'geiser) > (require 'geiser-guile) > (require 'guix) > (require 'magit) > > ;; ** My own guix config. > (defvar eh-geeguix-dir (expand-file-name "~/geeguix")) > > ;; ** Let geiser-guile use 'guix repl' > (setq geiser-guile-binary (list "guix" "repl" "-L" eh-geeguix-dir)) > > ;; ** guix-devel-mode > (add-hook 'scheme-mode-hook #'guix-devel-mode) > > ;; ** Get guix dir installed by 'guix pull'. > (defun eh-guix-dir () > (file-name-as-directory > (cl-find-if > (lambda (dir) > (file-exists-p (expand-file-name "guix.scm" dir))) > (directory-files > (expand-file-name "~/.cache/guix/checkouts/") > t)))) > > ;; ** copyright-update > (when (eh-guix-dir) > (let* ((dir (eh-guix-dir)) > (file (expand-file-name "etc/copyright.el" dir))) > (when (file-exists-p file) > (load-file file) > ;; (add-hook 'after-save-hook 'copyright-update) > (setq copyright-names-regexp > (format "%s <%s>" user-full-name user-mail-address))))) > > ;; ** tempel > (when (eh-guix-dir) > (let* ((dir (eh-guix-dir)) > (path (expand-file-name "etc/snippets/tempel/*" dir))) > (add-to-list 'tempel-path path))) I would also add: (add-hook! 'scheme-mode-hook #'display-fill-column-indicator-mode) This creates a vertical line that reminds you that your code should fit inside 80 columns. Possible also mention how to set up page break lines: https://github.com/purcell/page-break-lines