From 0cfc6140b60e272303e654aebdfb359e3bd33b0d Mon Sep 17 00:00:00 2001 From: Ryan Yin Date: Sat, 30 Dec 2023 12:59:32 +0800 Subject: [PATCH] feat: replace nix-doom-emacs with hlissner's config --- flake.lock | 496 +++--------------- flake.nix | 2 +- home/base/desktop/emacs/default.nix | 70 ++- .../desktop/emacs/{doom.d => doom}/config.el | 0 .../desktop/emacs/{doom.d => doom}/init.el | 0 .../emacs/{doom.d => doom}/packages.el | 0 home/darwin/shell.nix | 14 +- hosts/idols/ai/home.nix | 27 +- modules/base.nix | 2 + 9 files changed, 144 insertions(+), 467 deletions(-) rename home/base/desktop/emacs/{doom.d => doom}/config.el (100%) rename home/base/desktop/emacs/{doom.d => doom}/init.el (100%) rename home/base/desktop/emacs/{doom.d => doom}/packages.el (100%) diff --git a/flake.lock b/flake.lock index a86daf18..9e474351 100644 --- a/flake.lock +++ b/flake.lock @@ -116,149 +116,23 @@ "type": "github" } }, - "doom-emacs": { - "flake": false, - "locked": { - "lastModified": 1662497747, - "narHash": "sha256-4n7E1fqda7cn5/F2jTkOnKw1juG6XMS/FI9gqODL3aU=", - "owner": "doomemacs", - "repo": "doomemacs", - "rev": "3853dff5e11655e858d0bfae64b70cb12ef685ac", - "type": "github" - }, - "original": { - "owner": "doomemacs", - "repo": "doomemacs", - "rev": "3853dff5e11655e858d0bfae64b70cb12ef685ac", - "type": "github" - } - }, - "doom-snippets": { - "flake": false, - "locked": { - "lastModified": 1694887483, - "narHash": "sha256-KlKhruPSLPSKqUnr5/U65arm16VrY9ORzm+XKNZhpTQ=", - "owner": "doomemacs", - "repo": "snippets", - "rev": "f022984ee1318a4015d5d081b3c3dab5a60dc6ff", - "type": "github" - }, - "original": { - "owner": "doomemacs", - "repo": "snippets", - "type": "github" - } - }, "emacs-overlay": { - "flake": false, + "inputs": { + "flake-utils": "flake-utils", + "nixpkgs": "nixpkgs", + "nixpkgs-stable": "nixpkgs-stable" + }, "locked": { - "lastModified": 1676366521, - "narHash": "sha256-i4UAY8t9Au9SJtsgYppa3NHSVf1YkV6yqnNIQd+Km4g=", + "lastModified": 1703897863, + "narHash": "sha256-c1fzGuRbz6B2r9f3lT5a9C8rS1zYI3IeLd+NBuxKu1k=", "owner": "nix-community", "repo": "emacs-overlay", - "rev": "c16be6de78ea878aedd0292aa5d4a1ee0a5da501", + "rev": "285a626fe34c40d6f3e3f63f69f4ceb0cfc29e80", "type": "github" }, "original": { "owner": "nix-community", "repo": "emacs-overlay", - "rev": "c16be6de78ea878aedd0292aa5d4a1ee0a5da501", - "type": "github" - } - }, - "emacs-so-long": { - "flake": false, - "locked": { - "lastModified": 1575031854, - "narHash": "sha256-xIa5zO0ZaToDrec1OFjBK6l39AbA4l/CE4LInVu2hi0=", - "owner": "hlissner", - "repo": "emacs-so-long", - "rev": "ed666b0716f60e8988c455804de24b55919e71ca", - "type": "github" - }, - "original": { - "owner": "hlissner", - "repo": "emacs-so-long", - "type": "github" - } - }, - "evil-escape": { - "flake": false, - "locked": { - "lastModified": 1588439096, - "narHash": "sha256-aB2Ge5o/93B18tPf4fN1c+O46CNh/nOqwLJbox4c8Gw=", - "owner": "hlissner", - "repo": "evil-escape", - "rev": "819f1ee1cf3f69a1ae920e6004f2c0baeebbe077", - "type": "github" - }, - "original": { - "owner": "hlissner", - "repo": "evil-escape", - "type": "github" - } - }, - "evil-markdown": { - "flake": false, - "locked": { - "lastModified": 1626852210, - "narHash": "sha256-HBBuZ1VWIn6kwK5CtGIvHM1+9eiNiKPH0GUsyvpUVN8=", - "owner": "Somelauw", - "repo": "evil-markdown", - "rev": "8e6cc68af83914b2fa9fd3a3b8472573dbcef477", - "type": "github" - }, - "original": { - "owner": "Somelauw", - "repo": "evil-markdown", - "type": "github" - } - }, - "evil-org-mode": { - "flake": false, - "locked": { - "lastModified": 1607203864, - "narHash": "sha256-JxwqVYDN6OIJEH15MVI6XOZAPtUWUhJQWHyzcrUvrFg=", - "owner": "hlissner", - "repo": "evil-org-mode", - "rev": "a9706da260c45b98601bcd72b1d2c0a24a017700", - "type": "github" - }, - "original": { - "owner": "hlissner", - "repo": "evil-org-mode", - "type": "github" - } - }, - "evil-quick-diff": { - "flake": false, - "locked": { - "lastModified": 1575189609, - "narHash": "sha256-oGzl1ayW9rIuq0haoiFS7RZsS8NFMdEA7K1BSozgnJU=", - "owner": "rgrinberg", - "repo": "evil-quick-diff", - "rev": "69c883720b30a892c63bc89f49d4f0e8b8028908", - "type": "github" - }, - "original": { - "owner": "rgrinberg", - "repo": "evil-quick-diff", - "type": "github" - } - }, - "explain-pause-mode": { - "flake": false, - "locked": { - "lastModified": 1595842060, - "narHash": "sha256-++znrjiDSx+cy4okFBBXUBkRFdtnE2x+trkmqjB3Njs=", - "owner": "lastquestion", - "repo": "explain-pause-mode", - "rev": "2356c8c3639cbeeb9751744dbe737267849b4b51", - "type": "github" - }, - "original": { - "owner": "lastquestion", - "repo": "explain-pause-mode", "type": "github" } }, @@ -294,22 +168,6 @@ "type": "github" } }, - "flake-compat_3": { - "flake": false, - "locked": { - "lastModified": 1673956053, - "narHash": "sha256-4gtG9iQuiKITOjNQQeQIpoIB6b16fm+504Ch3sNKLd8=", - "owner": "edolstra", - "repo": "flake-compat", - "rev": "35bb57c0c8d8b62bbfd284272c928ceb64ddbde9", - "type": "github" - }, - "original": { - "owner": "edolstra", - "repo": "flake-compat", - "type": "github" - } - }, "flake-parts": { "inputs": { "nixpkgs-lib": [ @@ -354,14 +212,14 @@ }, "flake-utils": { "inputs": { - "systems": "systems_2" + "systems": "systems" }, "locked": { - "lastModified": 1681202837, - "narHash": "sha256-H+Rh19JDwRtpVPAWp64F+rlEtxUWBAQW28eAi3SRSzg=", + "lastModified": 1701680307, + "narHash": "sha256-kAuep2h5ajznlPMD9rnQyffWG8EM/C73lejGofXvdM8=", "owner": "numtide", "repo": "flake-utils", - "rev": "cfacdce06f30d2b68473a46042957675eebb3401", + "rev": "4022d587cbbfd70fe950c1e2083a02621806a725", "type": "github" }, "original": { @@ -375,11 +233,11 @@ "systems": "systems_3" }, "locked": { - "lastModified": 1694529238, - "narHash": "sha256-zsNZZGTGnMOf9YpHKJqMSsa0dXbfmxeoJ7xHlrt+xmY=", + "lastModified": 1681202837, + "narHash": "sha256-H+Rh19JDwRtpVPAWp64F+rlEtxUWBAQW28eAi3SRSzg=", "owner": "numtide", "repo": "flake-utils", - "rev": "ff7b65b44d01cf9ba6a71320833626af21126384", + "rev": "cfacdce06f30d2b68473a46042957675eebb3401", "type": "github" }, "original": { @@ -442,23 +300,6 @@ "type": "github" } }, - "format-all": { - "flake": false, - "locked": { - "lastModified": 1581716637, - "narHash": "sha256-ul7LCe60W8TIvUmUtZtZRo8489TK9iTPDsLHmzxY57M=", - "owner": "lassik", - "repo": "emacs-format-all-the-code", - "rev": "47d862d40a088ca089c92cd393c6dca4628f87d3", - "type": "github" - }, - "original": { - "owner": "lassik", - "repo": "emacs-format-all-the-code", - "rev": "47d862d40a088ca089c92cd393c6dca4628f87d3", - "type": "github" - } - }, "gitignore": { "inputs": { "nixpkgs": [ @@ -572,7 +413,7 @@ "nixpkgs": [ "nixpkgs" ], - "systems": "systems", + "systems": "systems_2", "wlroots": "wlroots", "xdph": "xdph" }, @@ -636,7 +477,7 @@ "crane": "crane", "flake-compat": "flake-compat", "flake-parts": "flake-parts_2", - "flake-utils": "flake-utils", + "flake-utils": "flake-utils_2", "nixpkgs": [ "nixpkgs" ], @@ -712,64 +553,6 @@ "type": "github" } }, - "nix-doom-emacs": { - "inputs": { - "doom-emacs": "doom-emacs", - "doom-snippets": "doom-snippets", - "emacs-overlay": "emacs-overlay", - "emacs-so-long": "emacs-so-long", - "evil-escape": "evil-escape", - "evil-markdown": "evil-markdown", - "evil-org-mode": "evil-org-mode", - "evil-quick-diff": "evil-quick-diff", - "explain-pause-mode": "explain-pause-mode", - "flake-compat": "flake-compat_2", - "flake-utils": "flake-utils_2", - "format-all": "format-all", - "nix-straight": "nix-straight", - "nixpkgs": "nixpkgs", - "nose": "nose", - "ob-racket": "ob-racket", - "org": "org", - "org-contrib": "org-contrib", - "org-yt": "org-yt", - "php-extras": "php-extras", - "revealjs": "revealjs", - "rotate-text": "rotate-text", - "sln-mode": "sln-mode", - "ts-fold": "ts-fold", - "ws-butler": "ws-butler" - }, - "locked": { - "lastModified": 1701264882, - "narHash": "sha256-MBXR7x7Ua8qystlGr+lenwjQd7dsFNFpEFmtHhh10zM=", - "owner": "nix-community", - "repo": "nix-doom-emacs", - "rev": "f7413022370f24bb53cb450bfb2803233510113e", - "type": "github" - }, - "original": { - "owner": "nix-community", - "repo": "nix-doom-emacs", - "type": "github" - } - }, - "nix-straight": { - "flake": false, - "locked": { - "lastModified": 1694361489, - "narHash": "sha256-kjDp+j6OtrmqbtjQB5uuOtjS08+kgJQuxFqhWE1Y9Rw=", - "owner": "nix-community", - "repo": "nix-straight.el", - "rev": "748be99b84be0b130e946288099806a0f16d6e57", - "type": "github" - }, - "original": { - "owner": "nix-community", - "repo": "nix-straight.el", - "type": "github" - } - }, "nixlib": { "locked": { "lastModified": 1693701915, @@ -864,17 +647,18 @@ }, "nixpkgs": { "locked": { - "lastModified": 1695806987, - "narHash": "sha256-fX5kGs66NZIxCMcpAGIpxuftajHL8Hil1vjHmjjl118=", + "lastModified": 1703438236, + "narHash": "sha256-aqVBq1u09yFhL7bj1/xyUeJjzr92fXVvQSSEx6AdB1M=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "f3dab3509afca932f3f4fd0908957709bb1c1f57", + "rev": "5f64a12a728902226210bf01d25ec6cbb9d9265b", "type": "github" }, "original": { - "id": "nixpkgs", - "ref": "nixpkgs-unstable", - "type": "indirect" + "owner": "NixOS", + "ref": "nixos-unstable", + "repo": "nixpkgs", + "type": "github" } }, "nixpkgs-darwin": { @@ -894,6 +678,22 @@ } }, "nixpkgs-stable": { + "locked": { + "lastModified": 1703467016, + "narHash": "sha256-/5A/dNPhbQx/Oa2d+Get174eNI3LERQ7u6WTWOlR1eQ=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "d02d818f22c777aa4e854efc3242ec451e5d462a", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixos-23.11", + "repo": "nixpkgs", + "type": "github" + } + }, + "nixpkgs-stable_2": { "locked": { "lastModified": 1678872516, "narHash": "sha256-/E1YwtMtFAu2KUQKV/1+KFuReYPANM2Rzehk84VxVoc=", @@ -909,7 +709,7 @@ "type": "github" } }, - "nixpkgs-stable_2": { + "nixpkgs-stable_3": { "locked": { "lastModified": 1685801374, "narHash": "sha256-otaSUoFEMM+LjBI1XL/xGB5ao6IwnZOXc47qhIgJe8U=", @@ -1019,22 +819,6 @@ "type": "github" } }, - "nose": { - "flake": false, - "locked": { - "lastModified": 1400604510, - "narHash": "sha256-daEi8Kta1oGaDEmUUDDQMahTTPOpvNpDKk22rlr7cB0=", - "owner": "emacsattic", - "repo": "nose", - "rev": "f8528297519eba911696c4e68fa88892de9a7b72", - "type": "github" - }, - "original": { - "owner": "emacsattic", - "repo": "nose", - "type": "github" - } - }, "nuenv": { "inputs": { "nixpkgs": "nixpkgs_5", @@ -1072,86 +856,6 @@ "type": "github" } }, - "ob-racket": { - "flake": false, - "locked": { - "lastModified": 1584656173, - "narHash": "sha256-rBUYDDCXb+3D4xTPQo9UocbTPZ32kWV1Uya/1DmZknU=", - "owner": "xchrishawk", - "repo": "ob-racket", - "rev": "83457ec9e1e96a29fd2086ed19432b9d75787673", - "type": "github" - }, - "original": { - "owner": "xchrishawk", - "repo": "ob-racket", - "type": "github" - } - }, - "org": { - "flake": false, - "locked": { - "lastModified": 1695726851, - "narHash": "sha256-qgbjspklSoI8M3cbCJOcUdjuijRgsL/+PSyEOW9VX4I=", - "owner": "emacs-straight", - "repo": "org-mode", - "rev": "aa9177e1a8b039c357d369c1c9aaab710bb247a9", - "type": "github" - }, - "original": { - "owner": "emacs-straight", - "repo": "org-mode", - "type": "github" - } - }, - "org-contrib": { - "flake": false, - "locked": { - "lastModified": 1694946041, - "narHash": "sha256-X/HFG6NZe5BY00KvGbcsIuf9R6Lg8x7Uhd0Y5+Q3qZU=", - "owner": "emacsmirror", - "repo": "org-contrib", - "rev": "5eabbf22bdd4523c922a30787e98ee66c24221aa", - "type": "github" - }, - "original": { - "owner": "emacsmirror", - "repo": "org-contrib", - "type": "github" - } - }, - "org-yt": { - "flake": false, - "locked": { - "lastModified": 1527381913, - "narHash": "sha256-dzQ6B7ryzatHCTLyEnRSbWO0VUiX/FHYnpHTs74aVUs=", - "owner": "TobiasZawada", - "repo": "org-yt", - "rev": "40cc1ac76d741055cbefa13860d9f070a7ade001", - "type": "github" - }, - "original": { - "owner": "TobiasZawada", - "repo": "org-yt", - "type": "github" - } - }, - "php-extras": { - "flake": false, - "locked": { - "lastModified": 1573312690, - "narHash": "sha256-r4WyVbzvT0ra4Z6JywNBOw5RxOEYd6Qe2IpebHXkj1U=", - "owner": "arnested", - "repo": "php-extras", - "rev": "d410c5af663c30c01d461ac476d1cbfbacb49367", - "type": "github" - }, - "original": { - "owner": "arnested", - "repo": "php-extras", - "type": "github" - } - }, "polybar-themes": { "flake": false, "locked": { @@ -1216,7 +920,7 @@ "lanzaboote", "nixpkgs" ], - "nixpkgs-stable": "nixpkgs-stable" + "nixpkgs-stable": "nixpkgs-stable_2" }, "locked": { "lastModified": 1681413034, @@ -1234,13 +938,13 @@ }, "pre-commit-hooks_2": { "inputs": { - "flake-compat": "flake-compat_3", + "flake-compat": "flake-compat_2", "flake-utils": "flake-utils_5", "gitignore": "gitignore_3", "nixpkgs": [ "nixpkgs" ], - "nixpkgs-stable": "nixpkgs-stable_2" + "nixpkgs-stable": "nixpkgs-stable_3" }, "locked": { "lastModified": 1702456155, @@ -1256,34 +960,18 @@ "type": "github" } }, - "revealjs": { - "flake": false, - "locked": { - "lastModified": 1695738029, - "narHash": "sha256-Z9c9Q41jMkj/DyXOiZYyIa7Gmn8VB8yauTyWrSsT+ps=", - "owner": "hakimel", - "repo": "reveal.js", - "rev": "88fbfc5751ad01e3f6adee5819eabeb9e73c3757", - "type": "github" - }, - "original": { - "owner": "hakimel", - "repo": "reveal.js", - "type": "github" - } - }, "root": { "inputs": { "agenix": "agenix", "anyrun": "anyrun", "astronvim": "astronvim", + "emacs-overlay": "emacs-overlay", "home-manager": "home-manager_2", "hyprland": "hyprland", "impermanence": "impermanence", "lanzaboote": "lanzaboote", "mysecrets": "mysecrets", "nix-darwin": "nix-darwin", - "nix-doom-emacs": "nix-doom-emacs", "nixos-generators": "nixos-generators", "nixos-hardware": "nixos-hardware", "nixos-licheepi4a": "nixos-licheepi4a", @@ -1298,22 +986,6 @@ "wallpapers": "wallpapers" } }, - "rotate-text": { - "flake": false, - "locked": { - "lastModified": 1322962747, - "narHash": "sha256-SOeOgSlcEIsKhUiYDJv0p+mLUb420s9E2BmvZQvZ0wk=", - "owner": "debug-ito", - "repo": "rotate-text.el", - "rev": "48f193697db996855aee1ad2bc99b38c6646fe76", - "type": "github" - }, - "original": { - "owner": "debug-ito", - "repo": "rotate-text.el", - "type": "github" - } - }, "rust-overlay": { "inputs": { "flake-utils": [ @@ -1361,38 +1033,7 @@ "type": "github" } }, - "sln-mode": { - "flake": false, - "locked": { - "lastModified": 1423727528, - "narHash": "sha256-XqkqPyEJuTtFslOz1fpTf/Klbd/zA7IGpzpmum/MGao=", - "owner": "sensorflo", - "repo": "sln-mode", - "rev": "0f91d1b957c7d2a7bab9278ec57b54d57f1dbd9c", - "type": "github" - }, - "original": { - "owner": "sensorflo", - "repo": "sln-mode", - "type": "github" - } - }, "systems": { - "locked": { - "lastModified": 1689347949, - "narHash": "sha256-12tWmuL2zgBgZkdoB6qXZsgJEH9LR3oUgpaQq2RbI80=", - "owner": "nix-systems", - "repo": "default-linux", - "rev": "31732fcf5e8fea42e59c2488ad31a0e651500f68", - "type": "github" - }, - "original": { - "owner": "nix-systems", - "repo": "default-linux", - "type": "github" - } - }, - "systems_2": { "locked": { "lastModified": 1681028828, "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", @@ -1407,6 +1048,21 @@ "type": "github" } }, + "systems_2": { + "locked": { + "lastModified": 1689347949, + "narHash": "sha256-12tWmuL2zgBgZkdoB6qXZsgJEH9LR3oUgpaQq2RbI80=", + "owner": "nix-systems", + "repo": "default-linux", + "rev": "31732fcf5e8fea42e59c2488ad31a0e651500f68", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default-linux", + "type": "github" + } + }, "systems_3": { "locked": { "lastModified": 1681028828, @@ -1484,22 +1140,6 @@ "type": "github" } }, - "ts-fold": { - "flake": false, - "locked": { - "lastModified": 1695278494, - "narHash": "sha256-O4NcUC1u08W8ZslqoA/i+iTaLotKwheURXQWBxLLMFc=", - "owner": "jcs-elpa", - "repo": "ts-fold", - "rev": "70b2c79ff4daa7351d4e2917b0343b9a18d4d4f2", - "type": "github" - }, - "original": { - "owner": "jcs-elpa", - "repo": "ts-fold", - "type": "github" - } - }, "wallpapers": { "flake": false, "locked": { @@ -1535,22 +1175,6 @@ "type": "gitlab" } }, - "ws-butler": { - "flake": false, - "locked": { - "lastModified": 1634511126, - "narHash": "sha256-c0y0ZPtxxICPk+eaNbbQf6t+FRCliNY54CCz9QHQ8ZI=", - "owner": "hlissner", - "repo": "ws-butler", - "rev": "572a10c11b6cb88293de48acbb59a059d36f9ba5", - "type": "github" - }, - "original": { - "owner": "hlissner", - "repo": "ws-butler", - "type": "github" - } - }, "xdph": { "inputs": { "hyprland-protocols": [ diff --git a/flake.nix b/flake.nix index fe5a0bfd..40f1fd1e 100644 --- a/flake.nix +++ b/flake.nix @@ -155,7 +155,7 @@ }; nuenv.url = "github:DeterminateSystems/nuenv"; - nix-doom-emacs.url = "github:nix-community/nix-doom-emacs"; + emacs-overlay.url = "github:nix-community/emacs-overlay"; ######################## Some non-flake repositories ######################################### diff --git a/home/base/desktop/emacs/default.nix b/home/base/desktop/emacs/default.nix index 265a7d1c..595854b3 100644 --- a/home/base/desktop/emacs/default.nix +++ b/home/base/desktop/emacs/default.nix @@ -1,25 +1,73 @@ +# ============================================== +# based on doomemacs's auther's config: +# https://github.com/hlissner/dotfiles/blob/master/modules/editors/emacs.nix { - pkgs, config, lib, - nix-doom-emacs, + pkgs, ... }: with lib; let - cfg = config.modules.desktop.emacs; + cfg = config.modules.editors.emacs; + envExtra = '' + export PATH="$XDG_CONFIG_HOME/emacs/bin:$PATH" + ''; in { - imports = [nix-doom-emacs.hmModule]; - - options.modules.desktop.emacs = { + options.modules.editors.emacs = { enable = mkEnableOption "Emacs Editor"; + doom = { + enable = mkEnableOption "Doom Emacs"; + repoUrl = mkOption { + type = types.str; + default = "https://github.com/doomemacs/doomemacs"; + }; + }; }; config = mkIf cfg.enable { - programs.doom-emacs = { - enable = true; - # Directory containing your config.el, init.el and packages.el files - doomPrivateDir = ./doom.d; - emacsPackage = pkgs.emacs-nox; + home.packages = with pkgs; [ + ## Emacs itself + binutils # native-comp needs 'as', provided by this + # 28.2 + native-comp + ((emacsPackagesFor emacs-unstable-nox).emacsWithPackages + (epkgs: [epkgs.vterm])) + emacs-all-the-icons-fonts + + ## Doom dependencies + git + (ripgrep.override {withPCRE2 = true;}) + gnutls # for TLS connectivity + + ## Optional dependencies + fd # faster projectile indexing + imagemagick # for image-dired + zstd # for undo-fu-session/undo-tree compression + + ## Module dependencies + # :checkers spell + (aspellWithDicts (ds: with ds; [en en-computers en-science])) + # :tools editorconfig + editorconfig-core-c # per-project style config + # :tools lookup & :lang org +roam + sqlite + # :lang latex & :lang org (latex previews) + texlive.combined.scheme-medium + ]; + + programs.bash.bashrcExtra = envExtra; + programs.zsh.envExtra = envExtra; + # allow fontconfig to discover fonts and configurations installed through `home.packages` + fonts.fontconfig.enable = true; + + xdg.configFile."doom".source = ./doom; + + home.activation = mkIf cfg.doom.enable { + installDoomEmacs = lib.hm.dag.entryBefore ["checkLinkTargets"] '' + if [ ! -d "${config.xdg.configHome}/emacs" ]; then + echo "Installing Doom Emacs..." + ${pkgs.git}/bin/git clone --depth=1 --single-branch "${cfg.doom.repoUrl}" "${config.xdg.configHome}/emacs" + fi + ''; }; }; } diff --git a/home/base/desktop/emacs/doom.d/config.el b/home/base/desktop/emacs/doom/config.el similarity index 100% rename from home/base/desktop/emacs/doom.d/config.el rename to home/base/desktop/emacs/doom/config.el diff --git a/home/base/desktop/emacs/doom.d/init.el b/home/base/desktop/emacs/doom/init.el similarity index 100% rename from home/base/desktop/emacs/doom.d/init.el rename to home/base/desktop/emacs/doom/init.el diff --git a/home/base/desktop/emacs/doom.d/packages.el b/home/base/desktop/emacs/doom/packages.el similarity index 100% rename from home/base/desktop/emacs/doom.d/packages.el rename to home/base/desktop/emacs/doom/packages.el diff --git a/home/darwin/shell.nix b/home/darwin/shell.nix index 7c391cdb..aab02675 100644 --- a/home/darwin/shell.nix +++ b/home/darwin/shell.nix @@ -1,4 +1,8 @@ -{ +let + envExtra = '' + export PATH="/opt/homebrew/bin:/usr/local/bin:$PATH" + ''; +in { # Homebrew's default install location: # /opt/homebrew for Apple Silicon # /usr/local for macOS Intel @@ -6,14 +10,10 @@ # in /opt/homebrew for Apple Silicon and /usr/local for Rosetta 2 to coexist and use bottles. programs.bash = { enable = true; - bashrcExtra = '' - export PATH="/opt/homebrew/bin:/usr/local/bin:$PATH" - ''; + bashrcExtra = envExtra; }; programs.zsh = { enable = true; - envExtra = '' - export PATH="/opt/homebrew/bin:/usr/local/bin:$PATH" - ''; + envExtra = envExtra; }; } diff --git a/hosts/idols/ai/home.nix b/hosts/idols/ai/home.nix index 1b3659ef..6a79e66a 100644 --- a/hosts/idols/ai/home.nix +++ b/hosts/idols/ai/home.nix @@ -1,18 +1,21 @@ { - modules.desktop.hyprland = { - nvidia = true; - settings = { - # Configure your Display resolution, offset, scale and Monitors here, use `hyprctl monitors` to get the info. - # highres: get the best possible resolution - # auto: postition automatically - # 1.5: scale to 1.5 times - # bitdepth,10: enable 10 bit support - monitor = "DP-2,highres,auto,1.5,bitdepth,10"; + modules.desktop = { + hyprland = { + nvidia = true; + settings = { + # Configure your Display resolution, offset, scale and Monitors here, use `hyprctl monitors` to get the info. + # highres: get the best possible resolution + # auto: postition automatically + # 1.5: scale to 1.5 times + # bitdepth,10: enable 10 bit support + monitor = "DP-2,highres,auto,1.5,bitdepth,10"; + }; }; + i3.nvidia = true; }; - modules.desktop.emacs.enable = true; - modules.desktop.i3 = { - nvidia = true; + modules.editors.emacs = { + enable = true; + doom.enable = true; }; programs.ssh = { diff --git a/modules/base.nix b/modules/base.nix index 5372dc52..27bedc2e 100644 --- a/modules/base.nix +++ b/modules/base.nix @@ -2,11 +2,13 @@ username, userfullname, nuenv, + emacs-overlay, ... } @ args: { nixpkgs.overlays = [ nuenv.overlays.default + emacs-overlay.overlay ] ++ (import ../overlays args);