!SlMumQZnFjwLRjWFbW:nixos.org

Nix + Doom Emacs

228 Members
Running Doom Emacs with Nix | You probably want https://github.com/nix-community/nix-doom-emacs48 Servers

Load older messages


SenderMessageTime
20 Jun 2023
@j4:matrix.orgj4m3s I have a kind of setup script in my repo that I use to ln -sf outside of Nix basically 21:33:37
@hdzki:hdzki.kozow.comhdzki ⚡️Oh so a shell script. I thought you found a way to do it in nix 😅21:34:40
@hdzki:hdzki.kozow.comhdzki ⚡️I could probably afford hardcoding git repo location since it's consistent in all of my machines21:35:12
@hdzki:hdzki.kozow.comhdzki ⚡️ How do you deal with extra config stuff then? Write out a file and load it in config.el ? 21:35:40
@j4:matrix.orgj4m3swdym by extra config ? 21:36:31
@hdzki:hdzki.kozow.comhdzki ⚡️ *

How do you deal with extra config stuff then? Write out a file and load it in config.el ?
I'm asking because i used to have a setup like this with NDE

extraConfig = ''
    (setq exec-path (append exec-path '( ${
    pkgs.lib.concatMapStringsSep " " (x: ''"${x}/bin"'') extraBins
    } )))
    (setenv "PATH" (concat (getenv "PATH") ":${
    pkgs.lib.concatMapStringsSep ":" (x: "${x}/bin") extraBins
    }"))
';
21:36:34
@j4:matrix.orgj4m3sOoh err, currently I'm not doing this21:37:02
@hdzki:hdzki.kozow.comhdzki ⚡️
In reply to@j4:matrix.org
wdym by extra config ?
I used to use the extraConfig option to pass in store paths and for doom emacs for stuff such as parinfer and co
21:37:12
@j4:matrix.orgj4m3sBut I guess I woud symlink something from the nix store with home-manager as well 21:37:16
@hdzki:hdzki.kozow.comhdzki ⚡️
In reply to@j4:matrix.org
wdym by extra config ?
* I used to use the extraConfig option to pass in store paths and for doom emacs for stuff such as parinfer and co which by default download exec on first run
21:37:22
@j4:matrix.orgj4m3sIt it's just runtime path of your emacs, can't you wrap your emacs and provide your own derivation ? (to programs.emacs or w/e else you use)21:38:00
@hdzki:hdzki.kozow.comhdzki ⚡️
In reply to@j4:matrix.org
It it's just runtime path of your emacs, can't you wrap your emacs and provide your own derivation ? (to programs.emacs or w/e else you use)
Because i need to set the variables inside of doom emacs. Some modules are stubborn and won't load from PATH unless you specify it
21:39:01
@hdzki:hdzki.kozow.comhdzki ⚡️and if you're doing that already, why not just set them to store paths in the first place.21:39:18
@hdzki:hdzki.kozow.comhdzki ⚡️i'm probably gonna write it out and then load it from my config.el21:39:42
@hdzki:hdzki.kozow.comhdzki ⚡️For example ```21:41:29
@hdzki:hdzki.kozow.comhdzki ⚡️ *

For example, these 2 won't load from path

      (use-package langtool
        :config
        (setq langtool-bin "${pkgs.languagetool}/bin/languagetool-commandline"))
      (setq parinfer-rust-library "${pkgs.kakounePlugins.parinfer-rust}/lib/libparinfer_rust.dylib")
21:41:38
@hdzki:hdzki.kozow.comhdzki ⚡️ *

For example, these 2 won't load from path so you have to set them

      (use-package langtool
        :config
        (setq langtool-bin "${pkgs.languagetool}/bin/languagetool-commandline"))
      (setq parinfer-rust-library "${pkgs.kakounePlugins.parinfer-rust}/lib/libparinfer_rust.dylib")
21:41:48
@j4:matrix.orgj4m3s You could generate a separate file and link via home.file.".doom.d.generated".source = ... something and then load it from your doom emacs config I guess 21:46:15
21 Jun 2023
@washort:greyface.orgdash joined the room.19:54:07
23 Jun 2023
@novaviper:matrix.orgNova Leary joined the room.03:02:08
@novaviper:matrix.orgNova Leary left the room.04:28:42
@asbjorn:olli.ngAsbjørn

Latest nix-doom-emacs is broken for me. Can open emacs standalone, but the systemd service dumps a bunch of errors elated to not finding something called "annalist"
(I'm noticing I really need to pin my emacs setup now 😅)

Jun 23 21:09:23 plate bash[1525906]: Loading /nix/store/qgq41l3x4fbdx36qx7xxl4b1sn5sj70x-doom-modeline-workarounds.el (source)...
Jun 23 21:09:23 plate bash[1525906]: Loading /nix/store/qgq41l3x4fbdx36qx7xxl4b1sn5sj70x-doom-modeline-workarounds.el (source)...done
Jun 23 21:09:23 plate bash[1525906]: Loading /nix/store/j7qpa26x2g5wkv7d9rzvd4fwfvadz9ii-doom.d/config.el (source)...
Jun 23 21:09:23 plate bash[1525906]: Loading /nix/store/j7qpa26x2g5wkv7d9rzvd4fwfvadz9ii-doom.d/config.el (source)...done
Jun 23 21:09:23 plate bash[1525906]: Loading /nix/store/mfwnjy57ilyzqw56978i5amspw882614-doom-private/config.extra.el (source)...
Jun 23 21:09:23 plate bash[1525906]: Loading /nix/store/mfwnjy57ilyzqw56978i5amspw882614-doom-private/config.extra.el (source)...done
Jun 23 21:09:23 plate bash[1525906]: Loading /nix/store/ik1ni0r6lncx4fkac4grkzfm4nmr5vnp-doom-emacs/lisp/doom-start.el (source)...done
Jun 23 21:09:23 plate bash[1525906]: Loading /nix/store/z2mzf110hlkq9ca7cbnm47s93sczg0mw-info-workarounds.el (source)...
Jun 23 21:09:23 plate bash[1525906]: Loading /nix/store/z2mzf110hlkq9ca7cbnm47s93sczg0mw-info-workarounds.el (source)...done
Jun 23 21:09:24 plate bash[1525906]: evil-collection error: (file-missing Cannot open load file No such file or directory annalist)
Jun 23 21:09:25 plate bash[1525906]: evil-collection error: (file-missing Cannot open load file No such file or directory annalist)
Jun 23 21:09:25 plate bash[1525906]: evil-collection error: (file-missing Cannot open load file No such file or directory annalist)
Jun 23 21:09:25 plate bash[1525906]: evil-collection error: (file-missing Cannot open load file No such file or directory annalist)
Jun 23 21:09:25 plate bash[1525906]: evil-collection error: (file-missing Cannot open load file No such file or directory annalist)
Jun 23 21:09:25 plate bash[1525906]: evil-collection error: (file-missing Cannot open load file No such file or directory annalist)
Jun 23 21:09:25 plate bash[1525906]: evil-collection error: (file-missing Cannot open load file No such file or directory annalist)
Jun 23 21:09:27 plate bash[1525906]: evil-collection error: (file-missing Cannot open load file No such file or directory annalist)
Jun 23 21:09:27 plate bash[1525906]: evil-collection error: (file-missing Cannot open load file No such file or directory annalist)
Jun 23 21:09:27 plate bash[1525906]: evil-collection error: (file-missing Cannot open load file No such file or directory annalist)
Jun 23 21:09:27 plate bash[1525906]: evil-collection error: (file-missing Cannot open load file No such file or directory annalist)
Jun 23 21:09:27 plate bash[1525906]: evil-collection error: (file-missing Cannot open load file No such file or directory annalist)
Jun 23 21:09:28 plate bash[1525906]: evil-collection error: (file-missing Cannot open load file No such file or directory annalist)
Jun 23 21:09:28 plate bash[1525906]: evil-collection error: (file-missing Cannot open load file No such file or directory annalist)
Jun 23 21:09:28 plate bash[1525906]: Starting Emacs daemon.
Jun 23 21:09:28 plate systemd[1765]: Started Emacs text editor.
19:11:09
@asbjorn:olli.ngAsbjørnnot sure if this is the right place to dump this kind of thing. I fixed my own setup, but not in any generalizable way19:18:25
@roman.gonzalez:matrix.orgroman.gonzalezI'm seeing the same issue with annalist 😑19:42:57
26 Jun 2023
@roman.gonzalez:matrix.orgroman.gonzalez

ugh, I think I know what is going on with the evil-collection package 😬

So first, context.

evil-collection is a package to add evil keybindings to a bunch of other modes.

I added a change to the nix-doom-emacs repository to change the resolution of evil-collection to be an extra dependency (not going through the regular emacs' dependency resolution, but through nix machinery).

I did this as the regular emac's dependency resolution hangs on the latest version of macOS, specifically when compiling the evil-collection-speedbar.el file.

Now, this "worked" ok. Everything compiles and we are good right? Not so much.

I found out that when the extra dependencies compilation fail, it does not fail the whole build. After whacking a few moles making it compile, I noticed that the final installation does not include a modes subdirectory that the package needs. I think this is due to the nix machinery only taking .el files into consideration (not directories).

I'm trying to make evil-collection work in macOS, ideally I would be able to skip a specific extension from evil-collection (the one hanging the build).

21:14:55
@roman.gonzalez:matrix.orgroman.gonzalez at this point, I would recommend reverting the evil-collection dependency resolution to come from emacs (e.g. remove it from the overrides.nix). This may work for Linux folks so no need to stop that from happening. 21:16:31
@roman.gonzalez:matrix.orgroman.gonzalezbefore I do the PR, I'm interested in your thoughts21:16:49
27 Jun 2023
@ckie:ckie.devckie (they/them) roman.gonzalez: it seems like you currently know what's going on better than me (: 01:56:42
@ckie:ckie.devckie (they/them)is modes an empty subdir? 01:56:49
@ckie:ckie.devckie (they/them) * is modes an empty subdir? that'd make sense 01:56:56

Show newer messages


Back to Room ListRoom Version: 9