all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Akib Azmain Turja <akib@disroot.org>
To: "(" <paren@disroot.org>
Cc: Gottfried <gottfried@posteo.de>,  help-guix@gnu.org
Subject: Re: Guix SD and Emacs
Date: Thu, 24 Nov 2022 10:20:20 +0600	[thread overview]
Message-ID: <87tu2p3rwb.fsf@disroot.org> (raw)
In-Reply-To: <Y36BsBNbs92vCjsJ@ws> (wolf@wolfsden.cz's message of "Wed, 23 Nov 2022 21:25:20 +0100")

[-- Attachment #1: Type: text/plain, Size: 1304 bytes --]

Wolf <wolf@wolfsden.cz> writes:

> On 2022-11-23 17:30:07 +0000, ( wrote:
>> That's why I use this code to redirect all custom customisations into
>> ~/.config/emacs/custom.el:
>> 
>>   (setq custom-file
>>         (concat (or (getenv "XDG_CONFIG_HOME")
>>                     (concat (getenv "HOME") "/.config"))
>>                 "/emacs/custom.el"))
>>   (load custom-file)
>
> I'm totally new to emacs, so this might be very stupid question, but
> based on the internets I've put the following into the init.el:
>
>   (setq custom-file (expand-file-name "custom.el" user-emacs-directory))
>   (load-file custom-file)
>
> Is there any practical difference or reason to prefer your version?
>
> W.

No, I think yours one is better, because it's OS independent.  I can
suggest the following, which basically the same but will save you a few
byte on your HDD/SSD:

--8<---------------cut here---------------start------------->8---
(setq custom-file (locate-user-emacs-file "custom.el"))
(load-file custom-file)
--8<---------------cut here---------------end--------------->8---

-- 
Akib Azmain Turja, GPG key: 70018CE5819F17A3BBA666AFE74F0EFA922AE7F5
Fediverse: akib@hostux.social
Codeberg: akib
emailselfdefense.fsf.org | "Nothing can be secure without encryption."

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]

  parent reply	other threads:[~2022-11-24  7:41 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-23 17:16 Guix SD and Emacs Gottfried
2022-11-23 17:30 ` (
2022-11-23 20:25   ` Wolf
2022-11-23 21:47     ` Felix Lechner via
2022-11-23 22:29     ` (
2022-11-24  4:20     ` Akib Azmain Turja [this message]
2022-11-24  4:16 ` Akib Azmain Turja
2022-11-24 14:29   ` Gottfried
2022-11-24 14:33     ` (
2022-11-25  7:45     ` Akib Azmain Turja
2022-11-25 19:12       ` Gottfried
2022-11-30 21:46         ` Mekeor Melire

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

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

  git send-email \
    --in-reply-to=87tu2p3rwb.fsf@disroot.org \
    --to=akib@disroot.org \
    --cc=gottfried@posteo.de \
    --cc=help-guix@gnu.org \
    --cc=paren@disroot.org \
    /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.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.