update
This commit is contained in:
228
flake.lock
generated
228
flake.lock
generated
@@ -20,11 +20,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1763922789,
|
"lastModified": 1769428758,
|
||||||
"narHash": "sha256-XnkWjCpeXfip9tqYdL0b0zzBDjq+dgdISvEdSVGdVyA=",
|
"narHash": "sha256-0G/GzF7lkWs/yl82bXuisSqPn6sf8YGTnbEdFOXvOfU=",
|
||||||
"owner": "hyprwm",
|
"owner": "hyprwm",
|
||||||
"repo": "aquamarine",
|
"repo": "aquamarine",
|
||||||
"rev": "a20a0e67a33b6848378a91b871b89588d3a12573",
|
"rev": "def5e74c97370f15949a67c62e61f1459fcb0e15",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -54,28 +54,28 @@
|
|||||||
"base16-fish": {
|
"base16-fish": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1754405784,
|
"lastModified": 1765809053,
|
||||||
"narHash": "sha256-l9xHIy+85FN+bEo6yquq2IjD1rSg9fjfjpyGP1W8YXo=",
|
"narHash": "sha256-XCUQLoLfBJ8saWms2HCIj4NEN+xNsWBlU1NrEPcQG4s=",
|
||||||
"owner": "tomyun",
|
"owner": "tomyun",
|
||||||
"repo": "base16-fish",
|
"repo": "base16-fish",
|
||||||
"rev": "23ae20a0093dca0d7b39d76ba2401af0ccf9c561",
|
"rev": "86cbea4dca62e08fb7fd83a70e96472f92574782",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "tomyun",
|
"owner": "tomyun",
|
||||||
"repo": "base16-fish",
|
"repo": "base16-fish",
|
||||||
"rev": "23ae20a0093dca0d7b39d76ba2401af0ccf9c561",
|
"rev": "86cbea4dca62e08fb7fd83a70e96472f92574782",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"base16-helix": {
|
"base16-helix": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1752979451,
|
"lastModified": 1760703920,
|
||||||
"narHash": "sha256-0CQM+FkYy0fOO/sMGhOoNL80ftsAzYCg9VhIrodqusM=",
|
"narHash": "sha256-m82fGUYns4uHd+ZTdoLX2vlHikzwzdu2s2rYM2bNwzw=",
|
||||||
"owner": "tinted-theming",
|
"owner": "tinted-theming",
|
||||||
"repo": "base16-helix",
|
"repo": "base16-helix",
|
||||||
"rev": "27cf1e66e50abc622fb76a3019012dc07c678fac",
|
"rev": "d646af9b7d14bff08824538164af99d0c521b185",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -109,11 +109,11 @@
|
|||||||
"nixpkgs-stable": "nixpkgs-stable"
|
"nixpkgs-stable": "nixpkgs-stable"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1764667911,
|
"lastModified": 1770140424,
|
||||||
"narHash": "sha256-a6+pjl0UELkSB+Wata6eQlvhnM3iRQfxy8Vl1HOfsG0=",
|
"narHash": "sha256-OjLbCjC7TpcZ07cxSmjzELafXBay861hIhrfrRMXZ98=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "emacs-overlay",
|
"repo": "emacs-overlay",
|
||||||
"rev": "a8ce1761cde35c96690ff8ef7643b77df58ffa40",
|
"rev": "196631c2e3c55526c8a67bfa7f4f06aeb11ffac6",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -125,11 +125,11 @@
|
|||||||
"firefox-gnome-theme": {
|
"firefox-gnome-theme": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1758112371,
|
"lastModified": 1764873433,
|
||||||
"narHash": "sha256-lizRM2pj6PHrR25yimjyFn04OS4wcdbc38DCdBVa2rk=",
|
"narHash": "sha256-1XPewtGMi+9wN9Ispoluxunw/RwozuTRVuuQOmxzt+A=",
|
||||||
"owner": "rafaelmardojai",
|
"owner": "rafaelmardojai",
|
||||||
"repo": "firefox-gnome-theme",
|
"repo": "firefox-gnome-theme",
|
||||||
"rev": "0909cfe4a2af8d358ad13b20246a350e14c2473d",
|
"rev": "f7ffd917ac0d253dbd6a3bf3da06888f57c69f92",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -141,15 +141,15 @@
|
|||||||
"flake-compat": {
|
"flake-compat": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1761588595,
|
"lastModified": 1767039857,
|
||||||
"narHash": "sha256-XKUZz9zewJNUj46b4AJdiRZJAvSZ0Dqj2BNfXvFlJC4=",
|
"narHash": "sha256-vNpUSpF5Nuw8xvDLj2KCwwksIbjua2LZCqhV1LNRDns=",
|
||||||
"owner": "edolstra",
|
"owner": "NixOS",
|
||||||
"repo": "flake-compat",
|
"repo": "flake-compat",
|
||||||
"rev": "f387cd2afec9419c8ee37694406ca490c3f34ee5",
|
"rev": "5edf11c44bc78a0d334f6334cdaf7d60d732daab",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "edolstra",
|
"owner": "NixOS",
|
||||||
"repo": "flake-compat",
|
"repo": "flake-compat",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
@@ -157,11 +157,11 @@
|
|||||||
"flake-compat_2": {
|
"flake-compat_2": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1761588595,
|
"lastModified": 1767039857,
|
||||||
"narHash": "sha256-XKUZz9zewJNUj46b4AJdiRZJAvSZ0Dqj2BNfXvFlJC4=",
|
"narHash": "sha256-vNpUSpF5Nuw8xvDLj2KCwwksIbjua2LZCqhV1LNRDns=",
|
||||||
"owner": "edolstra",
|
"owner": "edolstra",
|
||||||
"repo": "flake-compat",
|
"repo": "flake-compat",
|
||||||
"rev": "f387cd2afec9419c8ee37694406ca490c3f34ee5",
|
"rev": "5edf11c44bc78a0d334f6334cdaf7d60d732daab",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -178,11 +178,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1756770412,
|
"lastModified": 1767609335,
|
||||||
"narHash": "sha256-+uWLQZccFHwqpGqr2Yt5VsW/PbeJVTn9Dk6SHWhNRPw=",
|
"narHash": "sha256-feveD98mQpptwrAEggBQKJTYbvwwglSbOv53uCfH9PY=",
|
||||||
"owner": "hercules-ci",
|
"owner": "hercules-ci",
|
||||||
"repo": "flake-parts",
|
"repo": "flake-parts",
|
||||||
"rev": "4524271976b625a4a605beefd893f270620fd751",
|
"rev": "250481aafeb741edfe23d29195671c19b36b6dca",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -233,11 +233,11 @@
|
|||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"host": "gitlab.gnome.org",
|
"host": "gitlab.gnome.org",
|
||||||
"lastModified": 1762869044,
|
"lastModified": 1767737596,
|
||||||
"narHash": "sha256-nwm/GJ2Syigf7VccLAZ66mFC8mZJFqpJmIxSGKl7+Ds=",
|
"narHash": "sha256-eFujfIUQDgWnSJBablOuG+32hCai192yRdrNHTv0a+s=",
|
||||||
"owner": "GNOME",
|
"owner": "GNOME",
|
||||||
"repo": "gnome-shell",
|
"repo": "gnome-shell",
|
||||||
"rev": "680e3d195a92203f28d4bf8c6e8bb537cc3ed4ad",
|
"rev": "ef02db02bf0ff342734d525b5767814770d85b49",
|
||||||
"type": "gitlab"
|
"type": "gitlab"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -255,11 +255,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1764636297,
|
"lastModified": 1769978395,
|
||||||
"narHash": "sha256-S41K55kw+hWgDfgKmZ9/fMZ3F0BQDMvqFfE120fMHeE=",
|
"narHash": "sha256-gj1yP3spUb1vGtaF5qPhshd2j0cg4xf51pklDsIm19Q=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "home-manager",
|
"repo": "home-manager",
|
||||||
"rev": "ff067cfc619fdf6f82d50344e7d19ff2323f0827",
|
"rev": "984708c34d3495a518e6ab6b8633469bbca2f77a",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -313,11 +313,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1763733840,
|
"lastModified": 1769284023,
|
||||||
"narHash": "sha256-JnET78yl5RvpGuDQy3rCycOCkiKoLr5DN1fPhRNNMco=",
|
"narHash": "sha256-xG34vwYJ79rA2wVC8KFuM8r36urJTG6/csXx7LiiSYU=",
|
||||||
"owner": "hyprwm",
|
"owner": "hyprwm",
|
||||||
"repo": "hyprgraphics",
|
"repo": "hyprgraphics",
|
||||||
"rev": "8f1bec691b2d198c60cccabca7a94add2df4ed1a",
|
"rev": "13c536659d46893596412d180449353a900a1d31",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -336,17 +336,18 @@
|
|||||||
"hyprlang": "hyprlang",
|
"hyprlang": "hyprlang",
|
||||||
"hyprutils": "hyprutils",
|
"hyprutils": "hyprutils",
|
||||||
"hyprwayland-scanner": "hyprwayland-scanner",
|
"hyprwayland-scanner": "hyprwayland-scanner",
|
||||||
|
"hyprwire": "hyprwire",
|
||||||
"nixpkgs": "nixpkgs",
|
"nixpkgs": "nixpkgs",
|
||||||
"pre-commit-hooks": "pre-commit-hooks",
|
"pre-commit-hooks": "pre-commit-hooks",
|
||||||
"systems": "systems",
|
"systems": "systems",
|
||||||
"xdph": "xdph"
|
"xdph": "xdph"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1764607679,
|
"lastModified": 1770079745,
|
||||||
"narHash": "sha256-1Bsem6lhJWMQmkLIml5oKOL+z1dYMewZ6ql0K35Y3TA=",
|
"narHash": "sha256-R1jcgcb7y4QSJVR3vorQefKazXw5cYG9nUhhOnTPQxk=",
|
||||||
"owner": "hyprwm",
|
"owner": "hyprwm",
|
||||||
"repo": "Hyprland",
|
"repo": "Hyprland",
|
||||||
"rev": "f82a8630d7a51dab4cc70924f500bf70e723db12",
|
"rev": "30756d871845a6058a840642ab1a4c3979f6d782",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -388,11 +389,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1763727565,
|
"lastModified": 1767023960,
|
||||||
"narHash": "sha256-vRff/2R1U1jzPBy4OODqh2kfUzmizW/nfV2ROzTDIKo=",
|
"narHash": "sha256-R2HgtVS1G3KSIKAQ77aOZ+Q0HituOmPgXW9nBNkpp3Q=",
|
||||||
"owner": "hyprwm",
|
"owner": "hyprwm",
|
||||||
"repo": "hyprland-guiutils",
|
"repo": "hyprland-guiutils",
|
||||||
"rev": "7724d3a12a0453e7aae05f2ef39474219f05a4b4",
|
"rev": "c2e906261142f5dd1ee0bfc44abba23e2754c660",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -418,11 +419,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1764636589,
|
"lastModified": 1769285097,
|
||||||
"narHash": "sha256-8j0QzbFF3QindJZ0DVEwLA1Ty1/4t4hcU5zHGQ2meI8=",
|
"narHash": "sha256-eVD4U3Oqzz0VU9ylJ5wo76xDcYKv2CpiiRXq4Is4QdA=",
|
||||||
"owner": "hyprwm",
|
"owner": "hyprwm",
|
||||||
"repo": "hyprland-plugins",
|
"repo": "hyprland-plugins",
|
||||||
"rev": "8f796f7cec39e7a9aa2bb65d28006025e1bc14ae",
|
"rev": "06c0749a0dac978d89b1a76ae6adc76a3c15dbfa",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -443,11 +444,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1759610243,
|
"lastModified": 1765214753,
|
||||||
"narHash": "sha256-+KEVnKBe8wz+a6dTLq8YDcF3UrhQElwsYJaVaHXJtoI=",
|
"narHash": "sha256-P9zdGXOzToJJgu5sVjv7oeOGPIIwrd9hAUAP3PsmBBs=",
|
||||||
"owner": "hyprwm",
|
"owner": "hyprwm",
|
||||||
"repo": "hyprland-protocols",
|
"repo": "hyprland-protocols",
|
||||||
"rev": "bd153e76f751f150a09328dbdeb5e4fab9d23622",
|
"rev": "3f3860b869014c00e8b9e0528c7b4ddc335c21ab",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -472,11 +473,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1763819661,
|
"lastModified": 1767983607,
|
||||||
"narHash": "sha256-0jLarTR/BLWdGlboM86bPVP2zKJNI2jvo3JietnDkOM=",
|
"narHash": "sha256-8C2co8NYfR4oMOUEsPROOJ9JHrv9/ktbJJ6X1WsTbXc=",
|
||||||
"owner": "hyprwm",
|
"owner": "hyprwm",
|
||||||
"repo": "hyprlang",
|
"repo": "hyprlang",
|
||||||
"rev": "a318deec0c12409ec39c68d2be8096b636dc2a5c",
|
"rev": "d4037379e6057246b408bbcf796cf3e9838af5b2",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -524,11 +525,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1763503177,
|
"lastModified": 1764592794,
|
||||||
"narHash": "sha256-VPoiswJBBmTLVuNncvT/8FpFR+sYcAi/LgP/zTZ+5rA=",
|
"narHash": "sha256-7CcO+wbTJ1L1NBQHierHzheQGPWwkIQug/w+fhTAVuU=",
|
||||||
"owner": "hyprwm",
|
"owner": "hyprwm",
|
||||||
"repo": "hyprtoolkit",
|
"repo": "hyprtoolkit",
|
||||||
"rev": "f4e1e12755567ecf39090203b8f43eace8279630",
|
"rev": "5cfe0743f0e608e1462972303778d8a0859ee63e",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -549,11 +550,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1763996058,
|
"lastModified": 1766253372,
|
||||||
"narHash": "sha256-DsqzFZvrEV+aDmavjaD4/bk5qxeZwhGxPWBQdpFyM9Y=",
|
"narHash": "sha256-1+p4Kw8HdtMoFSmJtfdwjxM4bPxDK9yg27SlvUMpzWA=",
|
||||||
"owner": "hyprwm",
|
"owner": "hyprwm",
|
||||||
"repo": "hyprutils",
|
"repo": "hyprutils",
|
||||||
"rev": "0168583075baffa083032ed13a8bea8ea12f281a",
|
"rev": "51a4f93ce8572e7b12b7284eb9e6e8ebf16b4be9",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -587,6 +588,35 @@
|
|||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"hyprwire": {
|
||||||
|
"inputs": {
|
||||||
|
"hyprutils": [
|
||||||
|
"hyprland",
|
||||||
|
"hyprutils"
|
||||||
|
],
|
||||||
|
"nixpkgs": [
|
||||||
|
"hyprland",
|
||||||
|
"nixpkgs"
|
||||||
|
],
|
||||||
|
"systems": [
|
||||||
|
"hyprland",
|
||||||
|
"systems"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1769202094,
|
||||||
|
"narHash": "sha256-gdJr/vWWLRW85ucatSjoBULPB2dqBJd/53CZmQ9t91Q=",
|
||||||
|
"owner": "hyprwm",
|
||||||
|
"repo": "hyprwire",
|
||||||
|
"rev": "a45ca05050d22629b3c7969a926d37870d7dd75c",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "hyprwm",
|
||||||
|
"repo": "hyprwire",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
"nix-darwin": {
|
"nix-darwin": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"nixpkgs": [
|
"nixpkgs": [
|
||||||
@@ -594,11 +624,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1764161084,
|
"lastModified": 1768764703,
|
||||||
"narHash": "sha256-HN84sByg9FhJnojkGGDSrcjcbeioFWoNXfuyYfJ1kBE=",
|
"narHash": "sha256-5ulSDyOG1U+1sJhkJHYsUOWEsmtLl97O0NTVMvgIVyc=",
|
||||||
"owner": "LnL7",
|
"owner": "LnL7",
|
||||||
"repo": "nix-darwin",
|
"repo": "nix-darwin",
|
||||||
"rev": "e95de00a471d07435e0527ff4db092c84998698e",
|
"rev": "0fc4e7ac670a0ed874abacf73c4b072a6a58064b",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -660,11 +690,11 @@
|
|||||||
},
|
},
|
||||||
"nixCats": {
|
"nixCats": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1764009888,
|
"lastModified": 1769578476,
|
||||||
"narHash": "sha256-hJekfTiW1792txgRSM4LcHnz1lDSY87LYbsJEn2V378=",
|
"narHash": "sha256-4+KbiBcC6hQ3sh0UbPXjy6TOfLh9yhskRlfPzyZ2FH4=",
|
||||||
"owner": "BirdeeHub",
|
"owner": "BirdeeHub",
|
||||||
"repo": "nixCats-nvim",
|
"repo": "nixCats-nvim",
|
||||||
"rev": "16ac3281f322ea15d39843829e42a44d22da3715",
|
"rev": "48f8be4bdafccfa19ceaaf08071a15eca36fdb1d",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -675,11 +705,11 @@
|
|||||||
},
|
},
|
||||||
"nixos-hardware": {
|
"nixos-hardware": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1764440730,
|
"lastModified": 1769302137,
|
||||||
"narHash": "sha256-ZlJTNLUKQRANlLDomuRWLBCH5792x+6XUJ4YdFRjtO4=",
|
"narHash": "sha256-QEDtctEkOsbx8nlFh4yqPEOtr4tif6KTqWwJ37IM2ds=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixos-hardware",
|
"repo": "nixos-hardware",
|
||||||
"rev": "9154f4569b6cdfd3c595851a6ba51bfaa472d9f3",
|
"rev": "a351494b0e35fd7c0b7a1aae82f0afddf4907aa8",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -695,11 +725,11 @@
|
|||||||
"nixpkgs": "nixpkgs_2"
|
"nixpkgs": "nixpkgs_2"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1764591717,
|
"lastModified": 1769217863,
|
||||||
"narHash": "sha256-T/HMA0Bb/O6UnlGQ0Xt+wGe1j8m7eyyQ5+vVcCJslsM=",
|
"narHash": "sha256-RY9kJDXD6+2Td/59LkZ0PFSereCXHdBX9wIkbYjRKCY=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "NixOS-WSL",
|
"repo": "NixOS-WSL",
|
||||||
"rev": "84d1dab290feb4865d0cfcffc7aa0cf9bc65c3b7",
|
"rev": "38a5250e57f583662eac3b944830e4b9e169e965",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -711,11 +741,11 @@
|
|||||||
},
|
},
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1763966396,
|
"lastModified": 1769461804,
|
||||||
"narHash": "sha256-6eeL1YPcY1MV3DDStIDIdy/zZCDKgHdkCmsrLJFiZf0=",
|
"narHash": "sha256-msG8SU5WsBUfVVa/9RPLaymvi5bI8edTavbIq3vRlhI=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "5ae3b07d8d6527c42f17c876e404993199144b6a",
|
"rev": "bfc1b8a4574108ceef22f02bafcf6611380c100d",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -759,11 +789,11 @@
|
|||||||
},
|
},
|
||||||
"nixpkgs-stable": {
|
"nixpkgs-stable": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1764560356,
|
"lastModified": 1767313136,
|
||||||
"narHash": "sha256-M5aFEFPppI4UhdOxwdmceJ9bDJC4T6C6CzCK1E2FZyo=",
|
"narHash": "sha256-16KkgfdYqjaeRGBaYsNrhPRRENs0qzkQVUooNHtoy2w=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "6c8f0cca84510cc79e09ea99a299c9bc17d03cb6",
|
"rev": "ac62194c3917d5f474c1a844b6fd6da2db95077d",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -775,11 +805,11 @@
|
|||||||
},
|
},
|
||||||
"nixpkgs_2": {
|
"nixpkgs_2": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1764517877,
|
"lastModified": 1768564909,
|
||||||
"narHash": "sha256-pp3uT4hHijIC8JUK5MEqeAWmParJrgBVzHLNfJDZxg4=",
|
"narHash": "sha256-Kell/SpJYVkHWMvnhqJz/8DqQg2b6PguxVWOuadbHCc=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "2d293cbfa5a793b4c50d17c05ef9e385b90edf6c",
|
"rev": "e4bae1bd10c9c57b2cf517953ab70060a828ee6f",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -791,11 +821,11 @@
|
|||||||
},
|
},
|
||||||
"nixpkgs_3": {
|
"nixpkgs_3": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1764517877,
|
"lastModified": 1770115704,
|
||||||
"narHash": "sha256-pp3uT4hHijIC8JUK5MEqeAWmParJrgBVzHLNfJDZxg4=",
|
"narHash": "sha256-KHFT9UWOF2yRPlAnSXQJh6uVcgNcWlFqqiAZ7OVlHNc=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "2d293cbfa5a793b4c50d17c05ef9e385b90edf6c",
|
"rev": "e6eae2ee2110f3d31110d5c222cd395303343b08",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -871,11 +901,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1758998580,
|
"lastModified": 1767810917,
|
||||||
"narHash": "sha256-VLx0z396gDCGSiowLMFz5XRO/XuNV+4EnDYjdJhHvUk=",
|
"narHash": "sha256-ZKqhk772+v/bujjhla9VABwcvz+hB2IaRyeLT6CFnT0=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "NUR",
|
"repo": "NUR",
|
||||||
"rev": "ba8d9c98f5f4630bcb0e815ab456afd90c930728",
|
"rev": "dead29c804adc928d3a69dfe7f9f12d0eec1f1a4",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -894,11 +924,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1763988335,
|
"lastModified": 1769069492,
|
||||||
"narHash": "sha256-QlcnByMc8KBjpU37rbq5iP7Cp97HvjRP0ucfdh+M4Qc=",
|
"narHash": "sha256-Efs3VUPelRduf3PpfPP2ovEB4CXT7vHf8W+xc49RL/U=",
|
||||||
"owner": "cachix",
|
"owner": "cachix",
|
||||||
"repo": "git-hooks.nix",
|
"repo": "git-hooks.nix",
|
||||||
"rev": "50b9238891e388c9fdc6a5c49e49c42533a1b5ce",
|
"rev": "a1ef738813b15cf8ec759bdff5761b027e3e1d23",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -959,11 +989,11 @@
|
|||||||
"tinted-zed": "tinted-zed"
|
"tinted-zed": "tinted-zed"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1764648840,
|
"lastModified": 1769978605,
|
||||||
"narHash": "sha256-hIj3aKL+G8TXrqvz0wCnUKESN5MEyrD4YxaLLARnkPs=",
|
"narHash": "sha256-Vjniae6HHJCb9xZLeUOP15aRQXSZuKeeaZFM+gRDCgo=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "stylix",
|
"repo": "stylix",
|
||||||
"rev": "71054adbc3629404b2f02e8385aec07f87980a2f",
|
"rev": "ce22070ec5ce6169a6841da31baea33ce930ed38",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -1038,11 +1068,11 @@
|
|||||||
"tinted-schemes": {
|
"tinted-schemes": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1757716333,
|
"lastModified": 1767710407,
|
||||||
"narHash": "sha256-d4km8W7w2zCUEmPAPUoLk1NlYrGODuVa3P7St+UrqkM=",
|
"narHash": "sha256-+W1EB79Jl0/gm4JqmO0Nuc5C7hRdp4vfsV/VdzI+des=",
|
||||||
"owner": "tinted-theming",
|
"owner": "tinted-theming",
|
||||||
"repo": "schemes",
|
"repo": "schemes",
|
||||||
"rev": "317a5e10c35825a6c905d912e480dfe8e71c7559",
|
"rev": "2800e2b8ac90f678d7e4acebe4fa253f602e05b2",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -1054,11 +1084,11 @@
|
|||||||
"tinted-tmux": {
|
"tinted-tmux": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1757811970,
|
"lastModified": 1767489635,
|
||||||
"narHash": "sha256-n5ZJgmzGZXOD9pZdAl1OnBu3PIqD+X3vEBUGbTi4JiI=",
|
"narHash": "sha256-e6nnFnWXKBCJjCv4QG4bbcouJ6y3yeT70V9MofL32lU=",
|
||||||
"owner": "tinted-theming",
|
"owner": "tinted-theming",
|
||||||
"repo": "tinted-tmux",
|
"repo": "tinted-tmux",
|
||||||
"rev": "d217ba31c846006e9e0ae70775b0ee0f00aa6b1e",
|
"rev": "3c32729ccae99be44fe8a125d20be06f8d7d8184",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -1070,11 +1100,11 @@
|
|||||||
"tinted-zed": {
|
"tinted-zed": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1757811247,
|
"lastModified": 1767488740,
|
||||||
"narHash": "sha256-4EFOUyLj85NRL3OacHoLGEo0wjiRJzfsXtR4CZWAn6w=",
|
"narHash": "sha256-wVOj0qyil8m+ouSsVZcNjl5ZR+1GdOOAooAatQXHbuU=",
|
||||||
"owner": "tinted-theming",
|
"owner": "tinted-theming",
|
||||||
"repo": "base16-zed",
|
"repo": "base16-zed",
|
||||||
"rev": "824fe0aacf82b3c26690d14e8d2cedd56e18404e",
|
"rev": "11abb0b282ad3786a2aae088d3a01c60916f2e40",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
|||||||
@@ -39,6 +39,7 @@
|
|||||||
nh
|
nh
|
||||||
android-tools
|
android-tools
|
||||||
todo-txt-cli
|
todo-txt-cli
|
||||||
|
age
|
||||||
];
|
];
|
||||||
|
|
||||||
programs.home-manager.enable = true;
|
programs.home-manager.enable = true;
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
enable = true;
|
enable = true;
|
||||||
settings = {
|
settings = {
|
||||||
email = "michael@michaelthomson.dev";
|
email = "michael@michaelthomson.dev";
|
||||||
base_url = "https://vaultwarden.michaelthomson.dev";
|
base_url = "https://bitwarden.michaelthomson.dev";
|
||||||
pinentry = pkgs.pinentry-tty;
|
pinentry = pkgs.pinentry-tty;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -8,6 +8,14 @@
|
|||||||
inherit (pkgs) system;
|
inherit (pkgs) system;
|
||||||
overlays = [inputs.emacs-overlay.overlays.default];
|
overlays = [inputs.emacs-overlay.overlays.default];
|
||||||
};
|
};
|
||||||
|
addPlistSupport = pkg:
|
||||||
|
pkg.overrideAttrs (old: {
|
||||||
|
buildPhase =
|
||||||
|
''
|
||||||
|
export LSP_USE_PLISTS=true
|
||||||
|
''
|
||||||
|
+ (old.buildPhase or "");
|
||||||
|
});
|
||||||
in {
|
in {
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
emacs-lsp-booster
|
emacs-lsp-booster
|
||||||
@@ -26,8 +34,13 @@ in {
|
|||||||
libtool
|
libtool
|
||||||
glibtool
|
glibtool
|
||||||
graphviz
|
graphviz
|
||||||
|
mu
|
||||||
];
|
];
|
||||||
|
|
||||||
|
home.sessionVariables = {
|
||||||
|
LSP_USE_PLISTS = "true";
|
||||||
|
};
|
||||||
|
|
||||||
programs.emacs = {
|
programs.emacs = {
|
||||||
enable = true;
|
enable = true;
|
||||||
package = myPkgs.emacsWithPackagesFromUsePackage {
|
package = myPkgs.emacsWithPackagesFromUsePackage {
|
||||||
@@ -40,6 +53,15 @@ in {
|
|||||||
vterm
|
vterm
|
||||||
treesit-grammars.with-all-grammars
|
treesit-grammars.with-all-grammars
|
||||||
];
|
];
|
||||||
|
override = final: prev: {
|
||||||
|
lsp-mode = prev.lsp-mode.overrideAttrs (old: {
|
||||||
|
buildPhase =
|
||||||
|
''
|
||||||
|
export LSP_USE_PLISTS=true
|
||||||
|
''
|
||||||
|
+ (old.buildPhase or "");
|
||||||
|
});
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
services.emacs.enable = true;
|
services.emacs.enable = true;
|
||||||
|
|||||||
@@ -1,297 +1,169 @@
|
|||||||
;; performance enhancements
|
(setq gc-cons-threshold 100000000)
|
||||||
(setq gc-cons-threshold #x40000000)
|
|
||||||
|
|
||||||
(setq read-process-output-max (* 1024 1024 4))
|
(setq read-process-output-max (* 1024 1024 4))
|
||||||
|
|
||||||
;; EMACS ----------
|
|
||||||
(use-package emacs
|
(use-package emacs
|
||||||
:ensure nil
|
:ensure nil
|
||||||
:custom
|
:custom ;; Set custom variables to configure Emacs behavior.
|
||||||
(column-number-mode t)
|
(auto-save-default nil) ;; Disable automatic saving of buffers.
|
||||||
(auto-save-default nil)
|
(column-number-mode t) ;; Display the column number in the mode line.
|
||||||
(create-lockfiles nil)
|
(create-lockfiles nil) ;; Prevent the creation of lock files when editing.
|
||||||
(display-line-numbers-type 'relative)
|
(delete-by-moving-to-trash t) ;; Move deleted files to the trash instead of permanently deleting them.
|
||||||
(global-auto-revert-non-file-buffers t)
|
(delete-selection-mode 1) ;; Enable replacing selected text with typed text.
|
||||||
(history-length 25)
|
(display-line-numbers-type 'relative) ;; Use relative line numbering in programming modes.
|
||||||
(inhibit-startup-message t)
|
(global-auto-revert-non-file-bUffers t) ;; Automatically refresh non-file buffers.
|
||||||
(initial-scratch-message "")
|
(history-length 25) ;; Set the length of the command history.
|
||||||
(ispell-dictionary "en_US")
|
(indent-tabs-mode nil) ;; Disable the use of tabs for indentation (use spaces instead).
|
||||||
(make-backup-files nil)
|
(inhibit-startup-message t) ;; Disable the startup message when Emacs launches.
|
||||||
(pixel-scroll-precision-mode t)
|
(initial-scratch-message "") ;; Clear the initial message in the *scratch* buffer.
|
||||||
(pixel-scroll-precision-use-momentum nil)
|
(ispell-dictionary "en_US") ;; Set the default dictionary for spell checking.
|
||||||
(ring-bell-function 'ignore)
|
(make-backup-files nil) ;; Disable creation of backup files.
|
||||||
(split-width-threshold 300)
|
(pixel-scroll-precision-mode t) ;; Enable precise pixel scrolling.
|
||||||
(switch-to-buffer-obey-display-actions t)
|
(pixel-scroll-precision-use-momentum nil) ;; Disable momentum scrolling for pixel precision.
|
||||||
(indent-tabs-mode nil)
|
(ring-bell-function 'ignore) ;; Disable the audible bell.
|
||||||
(treesit-font-lock-level 4)
|
(split-width-threshold 300) ;; Prevent automatic window splitting if the window width exceeds 300 pixels.
|
||||||
(truncate-lines t)
|
(switch-to-buffer-obey-display-actions t) ;; Make buffer switching respect display actions.
|
||||||
(use-dialog-box nil)
|
(tab-always-indent 'complete) ;; Make the TAB key complete text instead of just indenting.
|
||||||
(use-short-answers t)
|
(tab-width 4) ;; Set the tab width to 4 spaces.
|
||||||
|
(treesit-font-lock-level 4) ;; Use advanced font locking for Treesit mode.
|
||||||
|
(truncate-lines t) ;; Enable line truncation to avoid wrapping long lines.
|
||||||
|
(use-dialog-box nil) ;; Disable dialog boxes in favor of minibuffer prompts.
|
||||||
|
(use-short-answers t) ;; Use short answers in prompts for quicker responses (y instead of yes)
|
||||||
|
(warning-minimum-level :emergency) ;; Set the minimum level of warnings to display.
|
||||||
|
|
||||||
;; recommended from vertico
|
:hook ;; Add hooks to enable specific features in certain modes.
|
||||||
(context-menu-mode t)
|
(prog-mode . display-line-numbers-mode) ;; Enable line numbers in programming modes.
|
||||||
(enable-recursive-minibuffers t)
|
|
||||||
(read-extended-command-predicate #'command-completion-default-include-p)
|
|
||||||
(minibuffer-prompt-properties
|
|
||||||
'(read-only t cursor-intangible t face minibuffer-prompt))
|
|
||||||
|
|
||||||
;; recommended from corfu
|
|
||||||
(tab-always-indent 'complete)
|
|
||||||
(text-mode-ispell-word-completion nil)
|
|
||||||
|
|
||||||
:hook
|
|
||||||
(prog-mode . display-line-numbers-mode)
|
|
||||||
|
|
||||||
:config
|
:config
|
||||||
(set-face-attribute 'default nil :family "JetBrainsMono Nerd Font" :height 100)
|
(set-face-attribute 'default nil :family "JetBrainsMono Nerd Font" :height 100)
|
||||||
|
(when (eq system-type 'darwin) ;; Check if the system is macOS.
|
||||||
|
(setq mac-command-modifier 'meta) ;; Set the Command key to act as the Meta key.
|
||||||
|
(set-face-attribute 'default nil :family "JetBrainsMono Nerd Font" :height 130))
|
||||||
|
|
||||||
|
;; Save manual customizations to a separate file instead of cluttering `init.el'.
|
||||||
|
(setq custom-file (locate-user-emacs-file "custom-vars.el")) ;; Specify the custom file path.
|
||||||
|
(load custom-file 'noerror 'nomessage) ;; Load the custom file quietly, ignoring errors.
|
||||||
|
|
||||||
|
:init ;; Initialization settings that apply before the package is loaded.
|
||||||
|
(tool-bar-mode -1) ;; Disable the tool bar for a cleaner interface.
|
||||||
|
(menu-bar-mode -1) ;; Disable the menu bar for a more streamlined look.
|
||||||
|
(when scroll-bar-mode
|
||||||
|
(scroll-bar-mode -1)) ;; Disable the scroll bar if it is active.
|
||||||
|
(global-hl-line-mode -1) ;; Disable highlight of the current line
|
||||||
|
(global-auto-revert-mode 1) ;; Enable global auto-revert mode to keep buffers up to date with their corresponding files.
|
||||||
|
(recentf-mode 1) ;; Enable tracking of recently opened files.
|
||||||
|
(savehist-mode 1) ;; Enable saving of command history.
|
||||||
|
(save-place-mode 1) ;; Enable saving the place in files for easier return.
|
||||||
|
(winner-mode 1) ;; Enable winner mode to easily undo window configuration changes.
|
||||||
|
(xterm-mouse-mode 1) ;; Enable mouse support in terminal mode.
|
||||||
|
(file-name-shadow-mode 1) ;; Enable shadowing of filenames for clarity.
|
||||||
|
(modify-coding-system-alist 'file "" 'utf-8))
|
||||||
|
|
||||||
|
(use-package dired
|
||||||
|
:ensure nil ;; This is built-in, no need to fetch it.
|
||||||
|
:custom
|
||||||
|
(dired-listing-switches "-lah --group-directories-first") ;; Display files in a human-readable format and group directories first.
|
||||||
|
(dired-dwim-target t) ;; Enable "do what I mean" for target directories.
|
||||||
|
(dired-kill-when-opening-new-dired-buffer t)) ;; Close the previous buffer when opening a new `dired' instance.
|
||||||
|
|
||||||
|
(use-package eldoc
|
||||||
|
:ensure nil ;; This is built-in, no need to fetch it.
|
||||||
|
:config
|
||||||
|
(setq eldoc-idle-delay 0) ;; Automatically fetch doc help
|
||||||
|
(setq eldoc-echo-area-use-multiline-p nil) ;; We use the "K" floating help instead
|
||||||
|
;; set to t if you want docs on the echo area
|
||||||
|
(setq eldoc-echo-area-display-truncation-message nil)
|
||||||
:init
|
:init
|
||||||
(tool-bar-mode -1)
|
(global-eldoc-mode))
|
||||||
(menu-bar-mode -1)
|
|
||||||
(scroll-bar-mode -1)
|
|
||||||
(global-hl-line-mode 1)
|
|
||||||
(global-auto-revert-mode 1)
|
|
||||||
(indent-tabs-mode -1)
|
|
||||||
(recentf-mode 1)
|
|
||||||
(savehist-mode 1)
|
|
||||||
(save-place-mode 1)
|
|
||||||
(winner-mode 1)
|
|
||||||
(xterm-mouse-mode 1)
|
|
||||||
(file-name-shadow-mode 1))
|
|
||||||
|
|
||||||
;; THEMES AND MODELINE ----------
|
(use-package flymake
|
||||||
(use-package modus-themes
|
:ensure nil ;; This is built-in, no need to fetch it.
|
||||||
:ensure t
|
|
||||||
:config
|
|
||||||
(load-theme 'modus-operandi t))
|
|
||||||
|
|
||||||
(use-package doom-modeline
|
|
||||||
:ensure t
|
|
||||||
:config
|
|
||||||
(display-battery-mode t)
|
|
||||||
(display-time-mode t)
|
|
||||||
:config (doom-modeline-mode 1))
|
|
||||||
|
|
||||||
(use-package nerd-icons
|
|
||||||
:ensure t)
|
|
||||||
|
|
||||||
(use-package nerd-icons-dired
|
|
||||||
:ensure t
|
|
||||||
:hook
|
|
||||||
(dired-mode . nerd-icons-dired-mode))
|
|
||||||
|
|
||||||
(use-package spacious-padding
|
|
||||||
:ensure t
|
|
||||||
:config
|
|
||||||
(spacious-padding-mode t))
|
|
||||||
|
|
||||||
;; EVIL MODE ----------
|
|
||||||
(use-package evil
|
|
||||||
:ensure t
|
|
||||||
:defer t
|
:defer t
|
||||||
|
:hook (prog-mode . flymake-mode)
|
||||||
|
:custom
|
||||||
|
(flymake-margin-indicators-string
|
||||||
|
'((error "!»" compilation-error) (warning "»" compilation-warning) (note "»" compilation-info))))
|
||||||
|
|
||||||
|
(use-package which-key
|
||||||
|
:ensure nil ;; This is built-in, no need to fetch it.
|
||||||
|
:defer t ;; Defer loading Which-Key until after init.
|
||||||
:hook
|
:hook
|
||||||
(after-init . evil-mode)
|
(after-init . which-key-mode)) ;; Enable which-key mode after initialization.
|
||||||
:init
|
|
||||||
(setq evil-want-integration t)
|
|
||||||
(setq evil-want-keybinding nil)
|
|
||||||
(setq evil-want-C-u-scroll t)
|
|
||||||
(setq evil-want-C-u-delete t)
|
|
||||||
:config
|
|
||||||
(evil-set-undo-system 'undo-tree)
|
|
||||||
(evil-set-leader 'normal (kbd "SPC"))
|
|
||||||
(evil-set-leader 'visual (kbd "SPC")))
|
|
||||||
|
|
||||||
(use-package evil-collection
|
|
||||||
:after evil
|
|
||||||
:ensure t
|
|
||||||
:config
|
|
||||||
(evil-collection-init))
|
|
||||||
|
|
||||||
(use-package evil-surround
|
|
||||||
:after evil
|
|
||||||
:ensure t
|
|
||||||
:config
|
|
||||||
(global-evil-surround-mode 1))
|
|
||||||
|
|
||||||
;; MINAD STACK -----------
|
|
||||||
(use-package vertico
|
(use-package vertico
|
||||||
:ensure t
|
:ensure t
|
||||||
:config
|
:hook
|
||||||
(setq vertico-cycle t)
|
(after-init . vertico-mode) ;; Enable vertico after Emacs has initialized.
|
||||||
(setq vertico-resize t)
|
:custom
|
||||||
(vertico-mode))
|
(vertico-count 10) ;; Number of candidates to display in the completion list.
|
||||||
|
(vertico-resize nil) ;; Disable resizing of the vertico minibuffer.
|
||||||
|
(vertico-cycle nil)) ;; Do not cycle through candidates when reaching the end of the list.
|
||||||
|
|
||||||
(use-package orderless
|
(use-package orderless
|
||||||
:ensure t
|
:ensure t
|
||||||
:config
|
:defer t ;; Load Orderless on demand.
|
||||||
(setq completion-styles '(orderless partial-completion basic))
|
:after vertico ;; Ensure Vertico is loaded before Orderless.
|
||||||
;; (setq completion-category-overrides '((file (styles partial-completion))))
|
:init
|
||||||
(setq completion-category-overrides nil)
|
(setq completion-styles '(orderless basic) ;; Set the completion styles.
|
||||||
(setq completion-category-defaults nil)
|
completion-category-defaults nil ;; Clear default category settings.
|
||||||
(setq completion-pcm-leading-wildcard t))
|
completion-category-overrides '((file (styles partial-completion))))) ;; Customize file completion styles.
|
||||||
|
|
||||||
(use-package marginalia
|
(use-package marginalia
|
||||||
:ensure t
|
:ensure t
|
||||||
:config
|
:hook
|
||||||
(marginalia-mode))
|
(after-init . marginalia-mode))
|
||||||
|
|
||||||
(use-package consult
|
(use-package consult
|
||||||
:ensure t)
|
:ensure t
|
||||||
|
:defer t
|
||||||
|
:init
|
||||||
|
;; Enhance register preview with thin lines and no mode line.
|
||||||
|
(advice-add #'register-preview :override #'consult-register-window)
|
||||||
|
|
||||||
|
;; Use Consult for xref locations with a preview feature.
|
||||||
|
(setq xref-show-xrefs-function #'consult-xref
|
||||||
|
xref-show-definitions-function #'consult-xref))
|
||||||
|
|
||||||
(use-package embark
|
(use-package embark
|
||||||
:ensure t)
|
:ensure t
|
||||||
|
:defer t)
|
||||||
|
|
||||||
(use-package embark-consult
|
(use-package embark-consult
|
||||||
:ensure t
|
:ensure t
|
||||||
:hook
|
:hook
|
||||||
(embark-collect-mode . consult-preview-at-point-mode))
|
(embark-collect-mode . consult-preview-at-point-mode)) ;; Enable preview in Embark collect mode.
|
||||||
|
|
||||||
|
(use-package treesit-auto
|
||||||
|
:ensure t
|
||||||
|
:after emacs
|
||||||
|
:config
|
||||||
|
(treesit-auto-add-to-auto-mode-alist 'all)
|
||||||
|
(global-treesit-auto-mode t))
|
||||||
|
|
||||||
(use-package corfu
|
(use-package corfu
|
||||||
:ensure t
|
:ensure t
|
||||||
|
:defer t
|
||||||
|
:custom
|
||||||
|
(corfu-auto t) ;; Only completes when hitting TAB
|
||||||
|
(corfu-auto-delay 0) ;; Delay before popup (enable if corfu-auto is t)
|
||||||
|
(corfu-auto-prefix 1) ;; Trigger completion after typing 1 character
|
||||||
|
(corfu-quit-no-match t) ;; Quit popup if no match
|
||||||
|
(corfu-scroll-margin 5) ;; Margin when scrolling completions
|
||||||
|
(corfu-max-width 50) ;; Maximum width of completion popup
|
||||||
|
(corfu-min-width 50) ;; Minimum width of completion popup
|
||||||
|
(corfu-popupinfo-delay 0.5) ;; Delay before showing documentation popup
|
||||||
:config
|
:config
|
||||||
(setq corfu-cycle t)
|
(add-to-list 'corfu-margin-formatters #'nerd-icons-corfu-formatter)
|
||||||
(setq corfu-quit-at-boundary nil)
|
:init
|
||||||
(setq corfu-quit-no-match t)
|
|
||||||
(setq corfu-preselect 'prompt)
|
|
||||||
(setq corfu-on-exact-match nil)
|
|
||||||
(setq corfu-preview-current 'insert)
|
|
||||||
(setq corfu-auto t)
|
|
||||||
(setq corfu-auto-prefix 2)
|
|
||||||
(setq corfu-auto-delay 0)
|
|
||||||
(setq corfu-popupinfo-delay '(0.5 . 0.2))
|
|
||||||
(global-corfu-mode)
|
(global-corfu-mode)
|
||||||
(corfu-history-mode)
|
(corfu-popupinfo-mode t))
|
||||||
(corfu-popupinfo-mode))
|
|
||||||
|
|
||||||
(use-package nerd-icons-corfu
|
(use-package nerd-icons-corfu
|
||||||
:ensure t
|
:ensure t
|
||||||
:after corfu
|
:defer t
|
||||||
:config (add-to-list 'corfu-margin-formatters #'nerd-icons-corfu-formatter))
|
:after (:all corfu))
|
||||||
|
|
||||||
(use-package cape
|
|
||||||
:ensure t
|
|
||||||
:bind ("C-c p" . cape-prefix-map)
|
|
||||||
:config
|
|
||||||
(add-hook 'completion-at-point-functions #'cape-abbrev)
|
|
||||||
(add-hook 'completion-at-point-functions #'cape-dict)
|
|
||||||
(add-hook 'completion-at-point-functions #'cape-file)
|
|
||||||
(add-hook 'completion-at-point-functions #'cape-elisp-block)
|
|
||||||
(add-hook 'completion-at-point-functions #'cape-keyword)
|
|
||||||
(add-hook 'completion-at-point-functions #'cape-tex))
|
|
||||||
|
|
||||||
(use-package yasnippet
|
|
||||||
:ensure t
|
|
||||||
:config
|
|
||||||
(yas-global-mode 1))
|
|
||||||
|
|
||||||
(use-package yasnippet-snippets
|
|
||||||
:ensure t
|
|
||||||
:after yasnippet)
|
|
||||||
|
|
||||||
(use-package eldoc
|
|
||||||
:ensure nil
|
|
||||||
:init
|
|
||||||
(global-eldoc-mode))
|
|
||||||
|
|
||||||
;; LINTING ------------
|
|
||||||
(use-package flycheck
|
|
||||||
:ensure t
|
|
||||||
:config
|
|
||||||
(global-flycheck-mode))
|
|
||||||
|
|
||||||
;; LANGUAGE MODES -------
|
|
||||||
(use-package treesit-auto
|
|
||||||
:ensure t
|
|
||||||
:config
|
|
||||||
(treesit-auto-add-to-auto-mode-alist 'all)
|
|
||||||
(global-treesit-auto-mode))
|
|
||||||
|
|
||||||
(use-package nix-ts-mode
|
|
||||||
:ensure t
|
|
||||||
:mode "\\.nix\\'")
|
|
||||||
|
|
||||||
;; EDITOR CONFIG ------
|
|
||||||
(use-package editorconfig
|
|
||||||
:ensure nil
|
|
||||||
:config
|
|
||||||
(editorconfig-mode t))
|
|
||||||
|
|
||||||
;; LSP ---------
|
|
||||||
(use-package lsp-mode
|
|
||||||
:ensure t
|
|
||||||
:hook ((typescript-ts-mode . lsp)
|
|
||||||
(tsx-ts-mode . lsp)
|
|
||||||
(js-ts-mode . lsp)
|
|
||||||
(css-ts-mode . lsp)
|
|
||||||
(rust-ts-mode . lsp)
|
|
||||||
(go-ts-mode . lsp)
|
|
||||||
(lsp-mode . lsp-enable-which-key-integration))
|
|
||||||
:commands lsp
|
|
||||||
:config
|
|
||||||
;; core
|
|
||||||
(setq lsp-keymap-prefix "C-c l")
|
|
||||||
(setq lsp-completion-provider :none)
|
|
||||||
(setq lsp-log-io nil)
|
|
||||||
(setq lsp-keep-workspace-alive nil)
|
|
||||||
(setq lsp-idle-delay 0.5)
|
|
||||||
(setq lsp-enable-xref t)
|
|
||||||
(setq lsp-auto-configure t)
|
|
||||||
(setq lsp-eldoc-enable-hover t)
|
|
||||||
(setq lsp-enable-dap-auto-configure t)
|
|
||||||
(setq lsp-enable-file-watchers nil) ;; TODO: check this
|
|
||||||
(setq lsp-enable-folding nil)
|
|
||||||
(setq lsp-enable-imenu t)
|
|
||||||
(setq lsp-enable-indentation nil) ;; TODO: check this as well
|
|
||||||
(setq lsp-enable-links t)
|
|
||||||
(setq lsp-enable-on-type-formatting t)
|
|
||||||
(setq lsp-enable-suggest-server-download nil)
|
|
||||||
(setq lsp-enable-symbol-highlighting t)
|
|
||||||
(setq lsp-enable-text-document-color nil)
|
|
||||||
(setq lsp-auto-execute-action nil)
|
|
||||||
|
|
||||||
;; sideline
|
|
||||||
(setq lsp-ui-sideline-show-hover nil)
|
|
||||||
(setq lsp-ui-sideline-diagnostic-max-lines 20)
|
|
||||||
|
|
||||||
;; completion
|
|
||||||
(setq lsp-completion-enable t)
|
|
||||||
(setq lsp-completion-enable-additional-text-edit t)
|
|
||||||
(setq lsp-enable-snippet t)
|
|
||||||
(setq lsp-completion-show-kind t)
|
|
||||||
|
|
||||||
;; headerline
|
|
||||||
(setq lsp-headerline-breadcrumb-enable t)
|
|
||||||
(setq lsp-headerline-breadcrumb-icons-enable t)
|
|
||||||
|
|
||||||
;; modeline
|
|
||||||
(setq lsp-modeline-code-actions-enable nil)
|
|
||||||
(setq lsp-modeline-diagnostics-enable nil)
|
|
||||||
(setq lsp-modeline-workspace-status-enable nil)
|
|
||||||
(setq lsp-signature-doc-lines 1)
|
|
||||||
(setq lsp-ui-doc-use-childframe t)
|
|
||||||
|
|
||||||
;; lens
|
|
||||||
(setq lsp-lens-enable nil)
|
|
||||||
|
|
||||||
;; semantic
|
|
||||||
(setq lsp-semantic-tokens-enable nil)
|
|
||||||
|
|
||||||
;; misc
|
|
||||||
(setq lsp-use-plists nil)
|
|
||||||
|
|
||||||
;; language specific
|
|
||||||
(setq lsp-eslint-server-command '("vscode-eslint-language-server" "--stdio"))
|
|
||||||
)
|
|
||||||
|
|
||||||
(use-package lsp-ui
|
|
||||||
:ensure t
|
|
||||||
:after (lsp-mode evil)
|
|
||||||
:config (setq lsp-ui-doc-enable t
|
|
||||||
evil-lookup-func #'lsp-ui-doc-glance
|
|
||||||
lsp-ui-doc-show-with-cursor nil
|
|
||||||
lsp-ui-doc-include-signature t
|
|
||||||
lsp-ui-doc-position 'at-point))
|
|
||||||
|
|
||||||
|
;; LSP BOOSTER
|
||||||
(defun lsp-booster--advice-json-parse (old-fn &rest args)
|
(defun lsp-booster--advice-json-parse (old-fn &rest args)
|
||||||
"Try to parse bytecode instead of json."
|
"Try to parse bytecode instead of json."
|
||||||
(or
|
(or
|
||||||
@@ -323,39 +195,249 @@
|
|||||||
orig-result)))
|
orig-result)))
|
||||||
(advice-add 'lsp-resolve-final-command :around #'lsp-booster--advice-final-command)
|
(advice-add 'lsp-resolve-final-command :around #'lsp-booster--advice-final-command)
|
||||||
|
|
||||||
;; TOOLS ---------
|
(use-package lsp-mode
|
||||||
(use-package magit
|
:ensure t
|
||||||
|
:defer t
|
||||||
|
:hook (;; Replace XXX-mode with concrete major mode (e.g. python-mode)
|
||||||
|
(lsp-mode . lsp-enable-which-key-integration) ;; Integrate with Which Key
|
||||||
|
((js-mode ;; Enable LSP for JavaScript
|
||||||
|
tsx-ts-mode ;; Enable LSP for TSX
|
||||||
|
typescript-ts-mode ;; Enable LSP for TypeScript
|
||||||
|
css-ts-mode ;; Enable LSP for CSS
|
||||||
|
go-ts-mode ;; Enable LSP for Go
|
||||||
|
js-ts-mode ;; Enable LSP for JavaScript (TS mode)
|
||||||
|
nix-ts-mode
|
||||||
|
web-mode) . lsp-deferred)) ;; Enable LSP for Web (HTML)
|
||||||
|
:commands lsp
|
||||||
|
:custom
|
||||||
|
(lsp-keymap-prefix "C-c l") ;; Set the prefix for LSP commands.
|
||||||
|
(lsp-inlay-hint-enable nil) ;; Usage of inlay hints.
|
||||||
|
(lsp-completion-provider :none) ;; Disable the default completion provider.
|
||||||
|
(lsp-session-file (locate-user-emacs-file ".lsp-session")) ;; Specify session file location.
|
||||||
|
(lsp-log-io nil) ;; Disable IO logging for speed.
|
||||||
|
(lsp-idle-delay 0.5) ;; Set the delay for LSP to 0 (debouncing).
|
||||||
|
(lsp-keep-workspace-alive nil) ;; Disable keeping the workspace alive.
|
||||||
|
;; Core settings
|
||||||
|
(lsp-enable-xref t) ;; Enable cross-references.
|
||||||
|
(lsp-auto-configure t) ;; Automatically configure LSP.
|
||||||
|
(lsp-enable-links nil) ;; Disable links.
|
||||||
|
(lsp-eldoc-enable-hover t) ;; Enable ElDoc hover.
|
||||||
|
(lsp-enable-file-watchers nil) ;; Disable file watchers.
|
||||||
|
(lsp-enable-folding nil) ;; Disable folding.
|
||||||
|
(lsp-enable-imenu t) ;; Enable Imenu support.
|
||||||
|
(lsp-enable-indentation nil) ;; Disable indentation.
|
||||||
|
(lsp-enable-on-type-formatting nil) ;; Disable on-type formatting.
|
||||||
|
(lsp-enable-suggest-server-download t) ;; Enable server download suggestion.
|
||||||
|
(lsp-enable-symbol-highlighting t) ;; Enable symbol highlighting.
|
||||||
|
(lsp-enable-text-document-color t) ;; Enable text document color.
|
||||||
|
;; Modeline settings
|
||||||
|
(lsp-modeline-code-actions-enable nil) ;; Keep modeline clean.
|
||||||
|
(lsp-modeline-diagnostics-enable nil) ;; Use `flymake' instead.
|
||||||
|
(lsp-modeline-workspace-status-enable t) ;; Display "LSP" in the modeline when enabled.
|
||||||
|
(lsp-signature-doc-lines 1) ;; Limit echo area to one line.
|
||||||
|
(lsp-eldoc-render-all t) ;; Render all ElDoc messages.
|
||||||
|
;; Completion settings
|
||||||
|
(lsp-completion-enable t) ;; Enable completion.
|
||||||
|
(lsp-completion-enable-additional-text-edit t) ;; Enable additional text edits for completions.
|
||||||
|
(lsp-enable-snippet nil) ;; Disable snippets
|
||||||
|
(lsp-completion-show-kind t) ;; Show kind in completions.
|
||||||
|
;; Lens settings
|
||||||
|
(lsp-lens-enable t) ;; Enable lens support.
|
||||||
|
;; Headerline settings
|
||||||
|
(lsp-headerline-breadcrumb-enable-symbol-numbers t) ;; Enable symbol numbers in the headerline.
|
||||||
|
(lsp-headerline-arrow "▶") ;; Set arrow for headerline.
|
||||||
|
(lsp-headerline-breadcrumb-enable-diagnostics nil) ;; Disable diagnostics in headerline.
|
||||||
|
(lsp-headerline-breadcrumb-icons-enable nil) ;; Disable icons in breadcrumb.
|
||||||
|
;; Semantic settings
|
||||||
|
(lsp-semantic-tokens-enable nil)
|
||||||
|
:config
|
||||||
|
(add-to-list 'lsp-file-watch-ignored-directories "[/\\\\]\\node_modules\\'"))
|
||||||
|
|
||||||
|
(use-package nix-ts-mode
|
||||||
|
:ensure t
|
||||||
|
:mode "\\.nix\\'")
|
||||||
|
|
||||||
|
(use-package eldoc-box
|
||||||
:ensure t
|
:ensure t
|
||||||
:defer t)
|
:defer t)
|
||||||
|
|
||||||
(use-package vterm
|
(use-package diff-hl
|
||||||
:ensure t)
|
:defer t
|
||||||
|
:ensure t
|
||||||
|
:hook
|
||||||
|
(find-file . (lambda ()
|
||||||
|
(global-diff-hl-mode) ;; Enable Diff-HL mode for all files.
|
||||||
|
(diff-hl-flydiff-mode) ;; Automatically refresh diffs.
|
||||||
|
(diff-hl-margin-mode))) ;; Show diff indicators in the margin.
|
||||||
|
:custom
|
||||||
|
(diff-hl-side 'left))
|
||||||
|
|
||||||
(use-package multi-vterm
|
(use-package magit
|
||||||
:ensure t)
|
|
||||||
|
|
||||||
(use-package undo-tree
|
|
||||||
:ensure t
|
:ensure t
|
||||||
:config
|
:config
|
||||||
(setq undo-tree-visualizer-timestamps t
|
(setopt magit-format-file-function #'magit-format-file-nerd-icons) ;; Turns on magit nerd-icons
|
||||||
undo-tree-visualizer-diff t
|
:defer t)
|
||||||
undo-limit 800000
|
|
||||||
undo-strong-limit 12000000
|
|
||||||
undo-outer-limit 120000000)
|
|
||||||
(setq undo-tree-history-directory-alist '(("." . "~/.config/emacs/.cache/undo")))
|
|
||||||
(global-undo-tree-mode))
|
|
||||||
|
|
||||||
(use-package ledger-mode
|
(use-package evil
|
||||||
|
:ensure t
|
||||||
|
:defer t
|
||||||
|
:hook
|
||||||
|
(after-init . evil-mode)
|
||||||
|
:init
|
||||||
|
(setq evil-want-integration t) ;; Integrate `evil' with other Emacs features (optional as it's true by default).
|
||||||
|
(setq evil-want-keybinding nil) ;; Disable default keybinding to set custom ones.
|
||||||
|
(setq evil-want-C-u-scroll t) ;; Makes C-u scroll
|
||||||
|
(setq evil-want-C-u-delete t) ;; Makes C-u delete on insert mode
|
||||||
|
:config
|
||||||
|
(evil-set-undo-system 'undo-tree) ;; Uses the undo-tree package as the default undo system
|
||||||
|
(evil-set-leader 'normal (kbd "SPC"))
|
||||||
|
(evil-set-leader 'visual (kbd "SPC"))
|
||||||
|
(setq evil-want-fine-undo t))
|
||||||
|
|
||||||
|
|
||||||
|
(use-package evil-collection
|
||||||
|
:defer t
|
||||||
:ensure t
|
:ensure t
|
||||||
:custom
|
:custom
|
||||||
((ledger-binary-path "hledger")
|
(evil-collection-want-find-usages-bindings t)
|
||||||
(ledger-mode-should-check-version nil)
|
:hook
|
||||||
(ledger-report-auto-width nil)
|
(evil-mode . evil-collection-init))
|
||||||
(ledger-report-links-in-register nil)
|
|
||||||
(ledger-report-native-highlighting-arguments '("--color=always")))
|
|
||||||
:mode ("\\.hledger\\'" "\\.ledger\\'" "\\.journal\\'"))
|
(use-package evil-surround
|
||||||
|
:ensure t
|
||||||
|
:after evil-collection
|
||||||
|
:config
|
||||||
|
(global-evil-surround-mode 1))
|
||||||
|
|
||||||
|
|
||||||
|
(use-package evil-matchit
|
||||||
|
:ensure t
|
||||||
|
:after evil-collection
|
||||||
|
:config
|
||||||
|
(global-evil-matchit-mode 1))
|
||||||
|
|
||||||
|
(use-package general
|
||||||
|
:ensure t
|
||||||
|
:after (evil evil-collection)
|
||||||
|
:init
|
||||||
|
(setq general-override-states '(insert
|
||||||
|
emacs
|
||||||
|
hybrid
|
||||||
|
normal
|
||||||
|
visual
|
||||||
|
motion
|
||||||
|
operator
|
||||||
|
replace))
|
||||||
|
:config
|
||||||
|
(general-evil-setup t)
|
||||||
|
(general-define-key
|
||||||
|
:states 'normal
|
||||||
|
"] d" '(flymake-goto-next-error :wk "Goto next error")
|
||||||
|
"[ d" '(flymake-goto-prev-error :wk "Goto prev error")
|
||||||
|
"] c" '(diff-hl-next-hunk :wk "Goto next hunk")
|
||||||
|
"[ c" '(diff-hl-previous-hunk :wk "Goto prev hunk")
|
||||||
|
"g r" '(lsp-find-references :wk "Goto references")
|
||||||
|
"K" '(eldoc-box-help-at-point :wk "Describe"))
|
||||||
|
|
||||||
|
(general-create-definer my-leader-def
|
||||||
|
:states '(normal insert visual motion emacs)
|
||||||
|
:keymaps 'override
|
||||||
|
:prefix "SPC"
|
||||||
|
:global-prefix "C-SPC")
|
||||||
|
|
||||||
|
(my-leader-def
|
||||||
|
"f" '(:ignore t :wk "Find")
|
||||||
|
"f c" '((lambda () (interactive) (find-file "~/.config/emacs/init.el")) :wk "Edit emacs config")
|
||||||
|
"f r" '(consult-recent-file :wk "Recent files")
|
||||||
|
"f f" '(consult-find :wk "Find Files")
|
||||||
|
"f g" '(consult-ripgrep :wk "Ripgrep search in files")
|
||||||
|
"f G" '(consult-git-grep :wk "Ripgrep search in files")
|
||||||
|
"f l" '(consult-line :wk "Find line")
|
||||||
|
"f i" '(consult-imenu :wk "Imenu buffer locations"))
|
||||||
|
|
||||||
|
(my-leader-def
|
||||||
|
"c" '(:ignore t :wk "Code")
|
||||||
|
"c a" '(lsp-execute-code-action :wk "Code actions"))
|
||||||
|
|
||||||
|
(my-leader-def
|
||||||
|
"h" '(:ignore t :wk "Help")
|
||||||
|
"h v" '(describe-variable :wk "Describe variable")
|
||||||
|
"h f" '(describe-function :wk "Describe function")
|
||||||
|
"h k" '(describe-key :wk "Describe key"))
|
||||||
|
|
||||||
|
(my-leader-def
|
||||||
|
"p" '(:ignore t :wk "Project")
|
||||||
|
"p b" '(consult-project-buffer :wk "Project buffers")
|
||||||
|
"p p" '(project-switch-project :wk "Project switch")
|
||||||
|
"p f" '(project-find-file :wk "Project find file")
|
||||||
|
"p g" '(project-find-regexp :wk "Project grep file")
|
||||||
|
"p k" '(project-kill-buffers :wk "Project kill buffers")
|
||||||
|
"p d" '(project-dired :wk "Project dired"))
|
||||||
|
|
||||||
|
(my-leader-def
|
||||||
|
"x" '(:ignore t :wk "Flymake")
|
||||||
|
"x x" '(consult-flymake :wk "Show diagnostics"))
|
||||||
|
|
||||||
|
(my-leader-def
|
||||||
|
"g" '(:ignore t :wk "Git")
|
||||||
|
"g g" '(magit-status :wk "Magit status")
|
||||||
|
"g l" '(magit-log-current :wk "Magit log"))
|
||||||
|
|
||||||
|
(my-leader-def
|
||||||
|
"r n" '(lsp-rename :wk "Rename"))
|
||||||
|
|
||||||
|
(my-leader-def
|
||||||
|
"u" '(undo-tree-visualize :wk "Undo-tree")))
|
||||||
|
|
||||||
|
(use-package undo-tree
|
||||||
|
:defer t
|
||||||
|
:ensure t
|
||||||
|
:hook
|
||||||
|
(after-init . global-undo-tree-mode)
|
||||||
|
:init
|
||||||
|
(setq undo-tree-visualizer-timestamps t
|
||||||
|
undo-tree-visualizer-diff t
|
||||||
|
undo-limit 800000 ;; Limit for undo entries.
|
||||||
|
undo-strong-limit 12000000 ;; Strong limit for undo entries.
|
||||||
|
undo-outer-limit 120000000) ;; Outer limit for undo entries.
|
||||||
|
:config
|
||||||
|
(setq undo-tree-history-directory-alist '(("." . "~/.config/emacs/.cache/undo"))))
|
||||||
|
|
||||||
|
(use-package dotenv-mode
|
||||||
|
:defer t
|
||||||
|
:ensure t)
|
||||||
|
|
||||||
|
(use-package doom-modeline
|
||||||
|
:ensure t
|
||||||
|
:defer t
|
||||||
|
:custom
|
||||||
|
(doom-modeline-buffer-file-name-style 'buffer-name) ;; Set the buffer file name style to just the buffer name (without path).
|
||||||
|
(doom-modeline-project-detection 'project) ;; Enable project detection for displaying the project name.
|
||||||
|
(doom-modeline-buffer-name t) ;; Show the buffer name in the mode line.
|
||||||
|
(doom-modeline-vcs-max-length 25) ;; Limit the version control system (VCS) branch name length to 25 characters.
|
||||||
|
:config
|
||||||
|
(setq doom-modeline-icon t) ;; Enable icons in the mode line if nerd fonts are used.
|
||||||
|
:hook
|
||||||
|
(after-init . doom-modeline-mode))
|
||||||
|
|
||||||
|
(use-package nerd-icons
|
||||||
|
:ensure t
|
||||||
|
:defer t)
|
||||||
|
|
||||||
|
(use-package nerd-icons-dired
|
||||||
|
:ensure t ;; Ensure the package is installed.
|
||||||
|
:defer t ;; Load the package only when needed to improve startup time.
|
||||||
|
:hook
|
||||||
|
(dired-mode . nerd-icons-dired-mode))
|
||||||
|
|
||||||
|
(use-package nerd-icons-completion
|
||||||
|
:ensure t ;; Ensure the package is installed.
|
||||||
|
:after (:all nerd-icons marginalia) ;; Load after `nerd-icons' and `marginalia' to ensure proper integration.
|
||||||
|
:config
|
||||||
|
(nerd-icons-completion-mode) ;; Activate nerd icons for completion interfaces.
|
||||||
|
(add-hook 'marginalia-mode-hook #'nerd-icons-completion-marginalia-setup)) ;; Setup icons in the marginalia mode for enhanced completion display.
|
||||||
|
|
||||||
;; PATH STUFF --------
|
|
||||||
(use-package exec-path-from-shell
|
(use-package exec-path-from-shell
|
||||||
:ensure t
|
:ensure t
|
||||||
:init
|
:init
|
||||||
@@ -368,7 +450,11 @@
|
|||||||
:hook
|
:hook
|
||||||
(after-init . envrc-global-mode))
|
(after-init . envrc-global-mode))
|
||||||
|
|
||||||
;; ORG ----------
|
(use-package modus-themes
|
||||||
|
:ensure t
|
||||||
|
:config
|
||||||
|
(load-theme 'modus-vivendi t))
|
||||||
|
|
||||||
(use-package org
|
(use-package org
|
||||||
:ensure nil
|
:ensure nil
|
||||||
:defer t
|
:defer t
|
||||||
@@ -378,9 +464,8 @@
|
|||||||
(org-hide-emphasis-markers t)
|
(org-hide-emphasis-markers t)
|
||||||
(org-log-into-drawer t)
|
(org-log-into-drawer t)
|
||||||
(org-log-done 'time)
|
(org-log-done 'time)
|
||||||
(org-agenda-span 'day)
|
|
||||||
(org-todo-keywords
|
(org-todo-keywords
|
||||||
'((sequence "TODO(t)" "NEXT(n)" "PROG(p)" "INTR(i)" "WAIT(w)" "SOMEDAY(s)" "|" "DONE(d)" "CANCELLED(c)")))
|
'((sequence "TODO(t)" "NEXT(n)" "PROG(p)" "WAIT(w)" "SOMEDAY(s)" "|" "DONE(d)" "CANCELLED(c)")))
|
||||||
(org-capture-templates
|
(org-capture-templates
|
||||||
`(("i" "Inbox" entry (file+headline "todo.org" "Inbox")
|
`(("i" "Inbox" entry (file+headline "todo.org" "Inbox")
|
||||||
"* TODO %?")
|
"* TODO %?")
|
||||||
@@ -410,180 +495,43 @@
|
|||||||
:init
|
:init
|
||||||
(require 'org-tempo))
|
(require 'org-tempo))
|
||||||
|
|
||||||
(use-package denote
|
(use-package org-roam
|
||||||
:ensure t
|
|
||||||
:hook
|
|
||||||
((dired-mode . denote-dired-mode)
|
|
||||||
(text-mode . denote-fontify-links-mode))
|
|
||||||
:bind
|
|
||||||
(("C-c n n" . denote)
|
|
||||||
("C-c n r" . denote-rename-file)
|
|
||||||
("C-c n l" . denote-link)
|
|
||||||
("C-c n b" . denote-backlinks)
|
|
||||||
("C-c n d" . denote-dired))
|
|
||||||
:config
|
|
||||||
(setq denote-directory (expand-file-name "~/org/note"))
|
|
||||||
(denote-rename-buffer-mode 1))
|
|
||||||
|
|
||||||
(use-package consult-denote
|
|
||||||
:ensure t
|
|
||||||
:bind
|
|
||||||
(("C-c n f" . consult-denote-find)
|
|
||||||
("C-c n g" . consult-denote-grep))
|
|
||||||
:config
|
|
||||||
(consult-denote-mode 1))
|
|
||||||
|
|
||||||
(use-package denote-journal
|
|
||||||
:ensure t
|
|
||||||
:commands (denote-journal-new-entry
|
|
||||||
denote-journal-new-or-existing-entry
|
|
||||||
denote-journal-link-or-create-entry )
|
|
||||||
:hook (calendar-mode . denote-journal-calendar-mode)
|
|
||||||
:config
|
|
||||||
(setq denote-journal-directory
|
|
||||||
(expand-file-name "journal" denote-directory))
|
|
||||||
(setq denote-journal-keyword "journal")
|
|
||||||
(setq denote-journal-title-format 'day-date-month-year))
|
|
||||||
|
|
||||||
(use-package org-superstar
|
|
||||||
:ensure t
|
|
||||||
:hook
|
|
||||||
(org-mode . org-superstar-mode))
|
|
||||||
|
|
||||||
(use-package org-super-agenda
|
|
||||||
:ensure t
|
:ensure t
|
||||||
:custom
|
:custom
|
||||||
(org-super-agenda-groups
|
(org-roam-directory "~/org")
|
||||||
'(
|
:bind (("C-c n l" . org-roam-buffer-toggle)
|
||||||
(:name "Today"
|
("C-c n f" . org-roam-node-find)
|
||||||
:time-grid t
|
("C-c n i" . org-roam-node-insert))
|
||||||
:date today
|
|
||||||
:todo "TODAY"
|
|
||||||
:scheduled today
|
|
||||||
:order 1)
|
|
||||||
(:name "Next Items"
|
|
||||||
:todo "NEXT"
|
|
||||||
:order 2)
|
|
||||||
(:name "Due Today"
|
|
||||||
:deadline today
|
|
||||||
:order 3)
|
|
||||||
(:name "Due Soon"
|
|
||||||
:deadline future
|
|
||||||
:order 4)
|
|
||||||
(:name "Overdue"
|
|
||||||
:deadline past
|
|
||||||
:order 5)
|
|
||||||
(:name "Scheduled Soon"
|
|
||||||
:scheduled future
|
|
||||||
:order 6)
|
|
||||||
(:name "Waiting"
|
|
||||||
:todo "WAIT"
|
|
||||||
:order 7)
|
|
||||||
(:habit t
|
|
||||||
:order 8)
|
|
||||||
(:name "Project"
|
|
||||||
:category "Project"
|
|
||||||
:order 9)
|
|
||||||
)))
|
|
||||||
|
|
||||||
;; KEYBINDS ---------
|
|
||||||
|
|
||||||
(use-package which-key
|
|
||||||
:ensure nil
|
|
||||||
:config
|
:config
|
||||||
(which-key-mode))
|
(org-roam-setup))
|
||||||
|
|
||||||
(use-package general
|
(use-package mu4e
|
||||||
:ensure t
|
|
||||||
:config
|
:config
|
||||||
(general-evil-setup t)
|
(setq mu4e-get-mail-command (concat (executable-find "mbsync") " -a"))
|
||||||
|
(setq mu4e-update-interval 300)
|
||||||
|
(setq mu4e-change-filenames-when-moving t)
|
||||||
|
(setq mu4e-attachment-dir "~/Downloads")
|
||||||
|
|
||||||
(general-define-key
|
;;smtp
|
||||||
:states 'normal
|
(setq send-mail-function 'sendmail-send-it)
|
||||||
"] d" '(flycheck-next-error :wk "Goto next error")
|
(setq sendmail-program (executable-find "msmtp"))
|
||||||
"[ d" '(flycheck-previous-error :wk "Goto prev error")
|
(setq message-sendmail-envelop-from 'header)
|
||||||
"] c" '(diff-hl-next-hunk :wk "Goto next hunk")
|
|
||||||
"g r" '(lsp-find-references :wk "Goto references")
|
|
||||||
"K" '(evil-lookup :wk "Describe"))
|
|
||||||
|
|
||||||
(general-create-definer my-leader-def
|
;; contexts
|
||||||
:states '(normal insert visual motion emacs)
|
(setq mu4e-contexts
|
||||||
:keymaps 'override
|
`(,(make-mu4e-context
|
||||||
:prefix "SPC"
|
:name "personal"
|
||||||
:global-prefix "C-SPC")
|
:enter-func
|
||||||
|
(lambda () (mu4e-message "Opening personal"))
|
||||||
(my-leader-def
|
:leave-func
|
||||||
"f" '(:ignore t :wk "Find")
|
(lambda () (mu4e-message "Closing personal"))
|
||||||
"f c" '((lambda () (interactive) (find-file "~/.config/emacs/init.el")) :wk "Edit emacs config")
|
:match-func
|
||||||
"f r" '(consult-recent-file :wk "Recent files")
|
(lambda (msg)
|
||||||
"f f" '(consult-find :wk "Find Files")
|
(when msg
|
||||||
"f g" '(consult-ripgrep :wk "Ripgrep search in files")
|
(string-match-p "^/personal" (mu4e-message-field msg :maildir))))
|
||||||
"f l" '(consult-line :wk "Find line")
|
:vars '((user-mail-address . "me@michaelthomson.dev" )
|
||||||
"f i" '(consult-imenu :wk "Imenu buffer locations"))
|
(user-full-name . "Michael Thomson")
|
||||||
|
(mu4e-drafts-folder . "/personal/Drafts")
|
||||||
(my-leader-def
|
(mu4e-refile-folder . "/personal/Archive")
|
||||||
"c" '(:ignore t :wk "Code")
|
(mu4e-sent-folder . "/personal/Sent")
|
||||||
"c a" '(lsp-execute-code-action :wk "Code actions"))
|
(mu4e-trash-folder . "/personal/Trash"))))))
|
||||||
|
|
||||||
(my-leader-def
|
|
||||||
"h" '(:ignore t :wk "Help")
|
|
||||||
"h v" '(describe-variable :wk "Describe variable")
|
|
||||||
"h f" '(describe-function :wk "Describe function")
|
|
||||||
"h k" '(describe-key :wk "Describe key"))
|
|
||||||
|
|
||||||
(my-leader-def
|
|
||||||
"p" '(:ignore t :wk "Project")
|
|
||||||
"p b" '(consult-project-buffer :wk "Project buffers")
|
|
||||||
"p p" '(project-switch-project :wk "Project switch")
|
|
||||||
"p f" '(project-find-file :wk "Project find file")
|
|
||||||
"p g" '(project-find-regexp :wk "Project grep file")
|
|
||||||
"p k" '(project-kill-buffers :wk "Project kill buffers")
|
|
||||||
"p d" '(project-dired :wk "Project dired"))
|
|
||||||
|
|
||||||
(my-leader-def
|
|
||||||
"x" '(:ignore t :wk "Flymake")
|
|
||||||
"x x" '(consult-flycheck :wk "Show diagnostics"))
|
|
||||||
|
|
||||||
(my-leader-def
|
|
||||||
"g" '(:ignore t :wk "Git")
|
|
||||||
"g g" '(magit-status :wk "Magit status")
|
|
||||||
"g l" '(magit-log-current :wk "Magit log"))
|
|
||||||
|
|
||||||
(my-leader-def
|
|
||||||
"r n" '(lsp-rename :wk "Rename"))
|
|
||||||
|
|
||||||
(my-leader-def
|
|
||||||
"u" '(undo-tree-visualize :wk "Undo-tree")))
|
|
||||||
|
|
||||||
(use-package diff-hl
|
|
||||||
:ensure t
|
|
||||||
:config
|
|
||||||
(global-diff-hl-mode))
|
|
||||||
|
|
||||||
;; EMAIL -----------
|
|
||||||
(use-package notmuch
|
|
||||||
:ensure t
|
|
||||||
:bind (("C-c m" . notmuch-hello))
|
|
||||||
:custom
|
|
||||||
(notmuch-search-oldest-first nil)
|
|
||||||
(notmuch-saved-searches
|
|
||||||
'((:name "inbox" :query "tag:inbox")
|
|
||||||
(:name "unread" :query "tag:unread")
|
|
||||||
(:name "sent" :query "tag:sent")
|
|
||||||
(:name "drafts" :query "tag:draft")))
|
|
||||||
:config
|
|
||||||
(setq sendmail-program "msmtp")
|
|
||||||
(setq notmuch-fcc-dirs nil))
|
|
||||||
|
|
||||||
(use-package ol-notmuch
|
|
||||||
:ensure t
|
|
||||||
:bind
|
|
||||||
("C-c l" . org-store-link))
|
|
||||||
|
|
||||||
;; EPUBS ----------
|
|
||||||
(use-package nov
|
|
||||||
:ensure t
|
|
||||||
:config
|
|
||||||
(add-to-list 'auto-mode-alist '("\\.epub\\'" . nov-mode)))
|
|
||||||
|
|
||||||
(provide 'init)
|
|
||||||
|
|||||||
492
modules/home-manager/emacs/init.org
Normal file
492
modules/home-manager/emacs/init.org
Normal file
@@ -0,0 +1,492 @@
|
|||||||
|
#+PROPERTY: header-args :tangle yes
|
||||||
|
|
||||||
|
* My Emacs Config
|
||||||
|
** Built-in
|
||||||
|
*** Performance
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(setq gc-cons-threshold #x40000000)
|
||||||
|
(setq read-process-output-max (* 1024 1024 4))
|
||||||
|
#+end_src
|
||||||
|
|
||||||
|
*** Emacs
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(use-package emacs
|
||||||
|
:ensure nil
|
||||||
|
:custom ;; Set custom variables to configure Emacs behavior.
|
||||||
|
(auto-save-default nil) ;; Disable automatic saving of buffers.
|
||||||
|
(column-number-mode t) ;; Display the column number in the mode line.
|
||||||
|
(create-lockfiles nil) ;; Prevent the creation of lock files when editing.
|
||||||
|
(delete-by-moving-to-trash t) ;; Move deleted files to the trash instead of permanently deleting them.
|
||||||
|
(delete-selection-mode 1) ;; Enable replacing selected text with typed text.
|
||||||
|
(display-line-numbers-type 'relative) ;; Use relative line numbering in programming modes.
|
||||||
|
(global-auto-revert-non-file-bUffers t) ;; Automatically refresh non-file buffers.
|
||||||
|
(history-length 25) ;; Set the length of the command history.
|
||||||
|
(indent-tabs-mode nil) ;; Disable the use of tabs for indentation (use spaces instead).
|
||||||
|
(inhibit-startup-message t) ;; Disable the startup message when Emacs launches.
|
||||||
|
(initial-scratch-message "") ;; Clear the initial message in the *scratch* buffer.
|
||||||
|
(ispell-dictionary "en_US") ;; Set the default dictionary for spell checking.
|
||||||
|
(make-backup-files nil) ;; Disable creation of backup files.
|
||||||
|
(pixel-scroll-precision-mode t) ;; Enable precise pixel scrolling.
|
||||||
|
(pixel-scroll-precision-use-momentum nil) ;; Disable momentum scrolling for pixel precision.
|
||||||
|
(ring-bell-function 'ignore) ;; Disable the audible bell.
|
||||||
|
(split-width-threshold 300) ;; Prevent automatic window splitting if the window width exceeds 300 pixels.
|
||||||
|
(switch-to-buffer-obey-display-actions t) ;; Make buffer switching respect display actions.
|
||||||
|
(tab-always-indent 'complete) ;; Make the TAB key complete text instead of just indenting.
|
||||||
|
(tab-width 4) ;; Set the tab width to 4 spaces.
|
||||||
|
(treesit-font-lock-level 4) ;; Use advanced font locking for Treesit mode.
|
||||||
|
(truncate-lines t) ;; Enable line truncation to avoid wrapping long lines.
|
||||||
|
(use-dialog-box nil) ;; Disable dialog boxes in favor of minibuffer prompts.
|
||||||
|
(use-short-answers t) ;; Use short answers in prompts for quicker responses (y instead of yes)
|
||||||
|
(warning-minimum-level :emergency) ;; Set the minimum level of warnings to display.
|
||||||
|
|
||||||
|
:hook ;; Add hooks to enable specific features in certain modes.
|
||||||
|
(prog-mode . display-line-numbers-mode) ;; Enable line numbers in programming modes.
|
||||||
|
|
||||||
|
:config
|
||||||
|
(set-face-attribute 'default nil :family "JetBrainsMono Nerd Font" :height 100)
|
||||||
|
(when (eq system-type 'darwin) ;; Check if the system is macOS.
|
||||||
|
(setq mac-command-modifier 'meta) ;; Set the Command key to act as the Meta key.
|
||||||
|
(set-face-attribute 'default nil :family "JetBrainsMono Nerd Font" :height 130))
|
||||||
|
|
||||||
|
;; Save manual customizations to a separate file instead of cluttering `init.el'.
|
||||||
|
(setq custom-file (locate-user-emacs-file "custom-vars.el")) ;; Specify the custom file path.
|
||||||
|
(load custom-file 'noerror 'nomessage) ;; Load the custom file quietly, ignoring errors.
|
||||||
|
|
||||||
|
:init ;; Initialization settings that apply before the package is loaded.
|
||||||
|
(tool-bar-mode -1) ;; Disable the tool bar for a cleaner interface.
|
||||||
|
(menu-bar-mode -1) ;; Disable the menu bar for a more streamlined look.
|
||||||
|
(when scroll-bar-mode
|
||||||
|
(scroll-bar-mode -1)) ;; Disable the scroll bar if it is active.
|
||||||
|
(global-hl-line-mode -1) ;; Disable highlight of the current line
|
||||||
|
(global-auto-revert-mode 1) ;; Enable global auto-revert mode to keep buffers up to date with their corresponding files.
|
||||||
|
(recentf-mode 1) ;; Enable tracking of recently opened files.
|
||||||
|
(savehist-mode 1) ;; Enable saving of command history.
|
||||||
|
(save-place-mode 1) ;; Enable saving the place in files for easier return.
|
||||||
|
(winner-mode 1) ;; Enable winner mode to easily undo window configuration changes.
|
||||||
|
(xterm-mouse-mode 1) ;; Enable mouse support in terminal mode.
|
||||||
|
(file-name-shadow-mode 1) ;; Enable shadowing of filenames for clarity.
|
||||||
|
(modify-coding-system-alist 'file "" 'utf-8))
|
||||||
|
#+end_src
|
||||||
|
|
||||||
|
*** Dired
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(use-package dired
|
||||||
|
:ensure nil ;; This is built-in, no need to fetch it.
|
||||||
|
:custom
|
||||||
|
(dired-listing-switches "-lah --group-directories-first") ;; Display files in a human-readable format and group directories first.
|
||||||
|
(dired-dwim-target t) ;; Enable "do what I mean" for target directories.
|
||||||
|
(dired-kill-when-opening-new-dired-buffer t)) ;; Close the previous buffer when opening a new `dired' instance.
|
||||||
|
#+end_src
|
||||||
|
*** Eldoc
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(use-package eldoc
|
||||||
|
:ensure nil ;; This is built-in, no need to fetch it.
|
||||||
|
:config
|
||||||
|
(setq eldoc-idle-delay 0) ;; Automatically fetch doc help
|
||||||
|
(setq eldoc-echo-area-use-multiline-p nil) ;; We use the "K" floating help instead
|
||||||
|
;; set to t if you want docs on the echo area
|
||||||
|
(setq eldoc-echo-area-display-truncation-message nil)
|
||||||
|
:init
|
||||||
|
(global-eldoc-mode))
|
||||||
|
#+end_src
|
||||||
|
*** Flymake
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(use-package flymake
|
||||||
|
:ensure nil ;; This is built-in, no need to fetch it.
|
||||||
|
:defer t
|
||||||
|
:hook (prog-mode . flymake-mode)
|
||||||
|
:custom
|
||||||
|
(flymake-margin-indicators-string
|
||||||
|
'((error "!»" compilation-error) (warning "»" compilation-warning) (note "»" compilation-info))))
|
||||||
|
#+end_src
|
||||||
|
*** Which-key
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(use-package which-key
|
||||||
|
:ensure nil ;; This is built-in, no need to fetch it.
|
||||||
|
:defer t ;; Defer loading Which-Key until after init.
|
||||||
|
:hook
|
||||||
|
(after-init . which-key-mode)) ;; Enable which-key mode after initialization.
|
||||||
|
#+end_src
|
||||||
|
** Packages
|
||||||
|
*** Vertico
|
||||||
|
- Provides a vertical selection interface for both buffer and minibuffer completions
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(use-package vertico
|
||||||
|
:ensure t
|
||||||
|
:hook
|
||||||
|
(after-init . vertico-mode) ;; Enable vertico after Emacs has initialized.
|
||||||
|
:custom
|
||||||
|
(vertico-count 10) ;; Number of candidates to display in the completion list.
|
||||||
|
(vertico-resize nil) ;; Disable resizing of the vertico minibuffer.
|
||||||
|
(vertico-cycle nil)) ;; Do not cycle through candidates when reaching the end of the list.
|
||||||
|
#+end_src
|
||||||
|
*** Orderless
|
||||||
|
- improved pattern matching on completion, works with vertico
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(use-package orderless
|
||||||
|
:ensure t
|
||||||
|
:defer t ;; Load Orderless on demand.
|
||||||
|
:after vertico ;; Ensure Vertico is loaded before Orderless.
|
||||||
|
:init
|
||||||
|
(setq completion-styles '(orderless basic) ;; Set the completion styles.
|
||||||
|
completion-category-defaults nil ;; Clear default category settings.
|
||||||
|
completion-category-overrides '((file (styles partial-completion))))) ;; Customize file completion styles.
|
||||||
|
|
||||||
|
#+end_src
|
||||||
|
*** Marginalia
|
||||||
|
- adds additional context in completion margins
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(use-package marginalia
|
||||||
|
:ensure t
|
||||||
|
:hook
|
||||||
|
(after-init . marginalia-mode))
|
||||||
|
#+end_src
|
||||||
|
*** Consult
|
||||||
|
- provides completion and narrowing commands for emacs
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(use-package consult
|
||||||
|
:ensure t
|
||||||
|
:defer t
|
||||||
|
:init
|
||||||
|
;; Enhance register preview with thin lines and no mode line.
|
||||||
|
(advice-add #'register-preview :override #'consult-register-window)
|
||||||
|
|
||||||
|
;; Use Consult for xref locations with a preview feature.
|
||||||
|
(setq xref-show-xrefs-function #'consult-xref
|
||||||
|
xref-show-definitions-function #'consult-xref))
|
||||||
|
#+end_src
|
||||||
|
*** Embark
|
||||||
|
- Allows for contextual action menu on any completion candidate
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(use-package embark
|
||||||
|
:ensure t
|
||||||
|
:defer t)
|
||||||
|
#+end_src
|
||||||
|
*** Embark-Consult
|
||||||
|
- Creates a bridge between embark and consult, allowing for consult features like previews in embark
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(use-package embark-consult
|
||||||
|
:ensure t
|
||||||
|
:hook
|
||||||
|
(embark-collect-mode . consult-preview-at-point-mode)) ;; Enable preview in Embark collect mode.
|
||||||
|
#+end_src
|
||||||
|
*** Treesit-auto
|
||||||
|
- Created automatic mode mapping to treesitter modes
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(use-package treesit-auto
|
||||||
|
:ensure t
|
||||||
|
:after emacs
|
||||||
|
:config
|
||||||
|
(treesit-auto-add-to-auto-mode-alist 'all)
|
||||||
|
(global-treesit-auto-mode t))
|
||||||
|
#+end_src
|
||||||
|
*** Corfu
|
||||||
|
- text completion framework for emacs
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(use-package corfu
|
||||||
|
:ensure t
|
||||||
|
:defer t
|
||||||
|
:custom
|
||||||
|
(corfu-auto t) ;; Only completes when hitting TAB
|
||||||
|
(corfu-auto-delay 0) ;; Delay before popup (enable if corfu-auto is t)
|
||||||
|
(corfu-auto-prefix 1) ;; Trigger completion after typing 1 character
|
||||||
|
(corfu-quit-no-match t) ;; Quit popup if no match
|
||||||
|
(corfu-scroll-margin 5) ;; Margin when scrolling completions
|
||||||
|
(corfu-max-width 50) ;; Maximum width of completion popup
|
||||||
|
(corfu-min-width 50) ;; Minimum width of completion popup
|
||||||
|
(corfu-popupinfo-delay 0.5) ;; Delay before showing documentation popup
|
||||||
|
:config
|
||||||
|
(add-to-list 'corfu-margin-formatters #'nerd-icons-corfu-formatter)
|
||||||
|
:init
|
||||||
|
(global-corfu-mode)
|
||||||
|
(corfu-popupinfo-mode t))
|
||||||
|
|
||||||
|
|
||||||
|
(use-package nerd-icons-corfu
|
||||||
|
:ensure t
|
||||||
|
:defer t
|
||||||
|
:after (:all corfu))
|
||||||
|
#+end_src
|
||||||
|
*** LSP
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(use-package lsp-mode
|
||||||
|
:ensure t
|
||||||
|
:defer t
|
||||||
|
:hook (;; Replace XXX-mode with concrete major mode (e.g. python-mode)
|
||||||
|
(lsp-mode . lsp-enable-which-key-integration) ;; Integrate with Which Key
|
||||||
|
((js-mode ;; Enable LSP for JavaScript
|
||||||
|
tsx-ts-mode ;; Enable LSP for TSX
|
||||||
|
typescript-ts-mode ;; Enable LSP for TypeScript
|
||||||
|
css-mode ;; Enable LSP for CSS
|
||||||
|
go-ts-mode ;; Enable LSP for Go
|
||||||
|
js-ts-mode ;; Enable LSP for JavaScript (TS mode)
|
||||||
|
web-mode) . lsp-deferred)) ;; Enable LSP for Web (HTML)
|
||||||
|
:commands lsp
|
||||||
|
:custom
|
||||||
|
(lsp-keymap-prefix "C-c l") ;; Set the prefix for LSP commands.
|
||||||
|
(lsp-inlay-hint-enable nil) ;; Usage of inlay hints.
|
||||||
|
(lsp-completion-provider :none) ;; Disable the default completion provider.
|
||||||
|
(lsp-session-file (locate-user-emacs-file ".lsp-session")) ;; Specify session file location.
|
||||||
|
(lsp-log-io nil) ;; Disable IO logging for speed.
|
||||||
|
(lsp-idle-delay 0.5) ;; Set the delay for LSP to 0 (debouncing).
|
||||||
|
(lsp-keep-workspace-alive nil) ;; Disable keeping the workspace alive.
|
||||||
|
;; Core settings
|
||||||
|
(lsp-enable-xref t) ;; Enable cross-references.
|
||||||
|
(lsp-auto-configure t) ;; Automatically configure LSP.
|
||||||
|
(lsp-enable-links nil) ;; Disable links.
|
||||||
|
(lsp-eldoc-enable-hover t) ;; Enable ElDoc hover.
|
||||||
|
(lsp-enable-file-watchers nil) ;; Disable file watchers.
|
||||||
|
(lsp-enable-folding nil) ;; Disable folding.
|
||||||
|
(lsp-enable-imenu t) ;; Enable Imenu support.
|
||||||
|
(lsp-enable-indentation nil) ;; Disable indentation.
|
||||||
|
(lsp-enable-on-type-formatting nil) ;; Disable on-type formatting.
|
||||||
|
(lsp-enable-suggest-server-download t) ;; Enable server download suggestion.
|
||||||
|
(lsp-enable-symbol-highlighting t) ;; Enable symbol highlighting.
|
||||||
|
(lsp-enable-text-document-color t) ;; Enable text document color.
|
||||||
|
;; Modeline settings
|
||||||
|
(lsp-modeline-code-actions-enable nil) ;; Keep modeline clean.
|
||||||
|
(lsp-modeline-diagnostics-enable nil) ;; Use `flymake' instead.
|
||||||
|
(lsp-modeline-workspace-status-enable t) ;; Display "LSP" in the modeline when enabled.
|
||||||
|
(lsp-signature-doc-lines 1) ;; Limit echo area to one line.
|
||||||
|
(lsp-eldoc-render-all t) ;; Render all ElDoc messages.
|
||||||
|
;; Completion settings
|
||||||
|
(lsp-completion-enable t) ;; Enable completion.
|
||||||
|
(lsp-completion-enable-additional-text-edit t) ;; Enable additional text edits for completions.
|
||||||
|
(lsp-enable-snippet nil) ;; Disable snippets
|
||||||
|
(lsp-completion-show-kind t) ;; Show kind in completions.
|
||||||
|
;; Lens settings
|
||||||
|
(lsp-lens-enable t) ;; Enable lens support.
|
||||||
|
;; Headerline settings
|
||||||
|
(lsp-headerline-breadcrumb-enable-symbol-numbers t) ;; Enable symbol numbers in the headerline.
|
||||||
|
(lsp-headerline-arrow "▶") ;; Set arrow for headerline.
|
||||||
|
(lsp-headerline-breadcrumb-enable-diagnostics nil) ;; Disable diagnostics in headerline.
|
||||||
|
(lsp-headerline-breadcrumb-icons-enable nil) ;; Disable icons in breadcrumb.
|
||||||
|
;; Semantic settings
|
||||||
|
(lsp-semantic-tokens-enable nil)) ;; Disable semantic tokens.
|
||||||
|
#+end_src
|
||||||
|
|
||||||
|
*** Eldoc-box
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(use-package eldoc-box
|
||||||
|
:ensure t
|
||||||
|
:defer t)
|
||||||
|
#+end_src
|
||||||
|
*** Diff-hl
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(use-package diff-hl
|
||||||
|
:defer t
|
||||||
|
:ensure t
|
||||||
|
:hook
|
||||||
|
(find-file . (lambda ()
|
||||||
|
(global-diff-hl-mode) ;; Enable Diff-HL mode for all files.
|
||||||
|
(diff-hl-flydiff-mode) ;; Automatically refresh diffs.
|
||||||
|
(diff-hl-margin-mode))) ;; Show diff indicators in the margin.
|
||||||
|
:custom
|
||||||
|
(diff-hl-side 'left) ;; Set the side for diff indicators.
|
||||||
|
(diff-hl-margin-symbols-alist '((insert . "┃") ;; Customize symbols for each change type.
|
||||||
|
(delete . "-")
|
||||||
|
(change . "┃")
|
||||||
|
(unknown . "┆")
|
||||||
|
(ignored . "i"))))
|
||||||
|
#+end_src
|
||||||
|
*** Magit
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(use-package magit
|
||||||
|
:ensure t
|
||||||
|
:config
|
||||||
|
(setopt magit-format-file-function #'magit-format-file-nerd-icons) ;; Turns on magit nerd-icons
|
||||||
|
:defer t)
|
||||||
|
#+end_src
|
||||||
|
*** Evil
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(use-package evil
|
||||||
|
:ensure t
|
||||||
|
:defer t
|
||||||
|
:hook
|
||||||
|
(after-init . evil-mode)
|
||||||
|
:init
|
||||||
|
(setq evil-want-integration t) ;; Integrate `evil' with other Emacs features (optional as it's true by default).
|
||||||
|
(setq evil-want-keybinding nil) ;; Disable default keybinding to set custom ones.
|
||||||
|
(setq evil-want-C-u-scroll t) ;; Makes C-u scroll
|
||||||
|
(setq evil-want-C-u-delete t) ;; Makes C-u delete on insert mode
|
||||||
|
:config
|
||||||
|
(evil-set-undo-system 'undo-tree) ;; Uses the undo-tree package as the default undo system
|
||||||
|
(evil-set-leader 'normal (kbd "SPC"))
|
||||||
|
(evil-set-leader 'visual (kbd "SPC"))
|
||||||
|
(setq evil-want-fine-undo t))
|
||||||
|
|
||||||
|
|
||||||
|
(use-package evil-collection
|
||||||
|
:defer t
|
||||||
|
:ensure t
|
||||||
|
:custom
|
||||||
|
(evil-collection-want-find-usages-bindings t)
|
||||||
|
:hook
|
||||||
|
(evil-mode . evil-collection-init))
|
||||||
|
|
||||||
|
|
||||||
|
(use-package evil-surround
|
||||||
|
:ensure t
|
||||||
|
:after evil-collection
|
||||||
|
:config
|
||||||
|
(global-evil-surround-mode 1))
|
||||||
|
|
||||||
|
|
||||||
|
(use-package evil-matchit
|
||||||
|
:ensure t
|
||||||
|
:after evil-collection
|
||||||
|
:config
|
||||||
|
(global-evil-matchit-mode 1))
|
||||||
|
#+end_src
|
||||||
|
*** General
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(use-package general
|
||||||
|
:ensure t
|
||||||
|
:after (evil evil-collection)
|
||||||
|
:init
|
||||||
|
(setq general-override-states '(insert
|
||||||
|
emacs
|
||||||
|
hybrid
|
||||||
|
normal
|
||||||
|
visual
|
||||||
|
motion
|
||||||
|
operator
|
||||||
|
replace))
|
||||||
|
:config
|
||||||
|
(general-evil-setup t)
|
||||||
|
(general-define-key
|
||||||
|
:states 'normal
|
||||||
|
"] d" '(flymake-goto-next-error :wk "Goto next error")
|
||||||
|
"[ d" '(flymake-goto-prev-error :wk "Goto prev error")
|
||||||
|
"] c" '(diff-hl-next-hunk :wk "Goto next hunk")
|
||||||
|
"[ c" '(diff-hl-previous-hunk :wk "Goto prev hunk")
|
||||||
|
"g r" '(lsp-find-references :wk "Goto references")
|
||||||
|
"K" '(eldoc-box-help-at-point :wk "Describe"))
|
||||||
|
|
||||||
|
(general-create-definer my-leader-def
|
||||||
|
:states '(normal insert visual motion emacs)
|
||||||
|
:keymaps 'override
|
||||||
|
:prefix "SPC"
|
||||||
|
:global-prefix "C-SPC")
|
||||||
|
|
||||||
|
(my-leader-def
|
||||||
|
"f" '(:ignore t :wk "Find")
|
||||||
|
"f c" '((lambda () (interactive) (find-file "~/.config/emacs/init.el")) :wk "Edit emacs config")
|
||||||
|
"f r" '(consult-recent-file :wk "Recent files")
|
||||||
|
"f f" '(consult-find :wk "Find Files")
|
||||||
|
"f g" '(consult-ripgrep :wk "Ripgrep search in files")
|
||||||
|
"f G" '(consult-git-grep :wk "Ripgrep search in files")
|
||||||
|
"f l" '(consult-line :wk "Find line")
|
||||||
|
"f i" '(consult-imenu :wk "Imenu buffer locations"))
|
||||||
|
|
||||||
|
(my-leader-def
|
||||||
|
"c" '(:ignore t :wk "Code")
|
||||||
|
"c a" '(lsp-execute-code-action :wk "Code actions"))
|
||||||
|
|
||||||
|
(my-leader-def
|
||||||
|
"h" '(:ignore t :wk "Help")
|
||||||
|
"h v" '(describe-variable :wk "Describe variable")
|
||||||
|
"h f" '(describe-function :wk "Describe function")
|
||||||
|
"h k" '(describe-key :wk "Describe key"))
|
||||||
|
|
||||||
|
(my-leader-def
|
||||||
|
"p" '(:ignore t :wk "Project")
|
||||||
|
"p b" '(consult-project-buffer :wk "Project buffers")
|
||||||
|
"p p" '(project-switch-project :wk "Project switch")
|
||||||
|
"p f" '(project-find-file :wk "Project find file")
|
||||||
|
"p g" '(project-find-regexp :wk "Project grep file")
|
||||||
|
"p k" '(project-kill-buffers :wk "Project kill buffers")
|
||||||
|
"p d" '(project-dired :wk "Project dired"))
|
||||||
|
|
||||||
|
(my-leader-def
|
||||||
|
"x" '(:ignore t :wk "Flymake")
|
||||||
|
"x x" '(consult-flymake :wk "Show diagnostics"))
|
||||||
|
|
||||||
|
(my-leader-def
|
||||||
|
"g" '(:ignore t :wk "Git")
|
||||||
|
"g g" '(magit-status :wk "Magit status")
|
||||||
|
"g l" '(magit-log-current :wk "Magit log"))
|
||||||
|
|
||||||
|
(my-leader-def
|
||||||
|
"r n" '(lsp-rename :wk "Rename"))
|
||||||
|
|
||||||
|
(my-leader-def
|
||||||
|
"u" '(undo-tree-visualize :wk "Undo-tree")))
|
||||||
|
#+end_src
|
||||||
|
*** Undo tree
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(use-package undo-tree
|
||||||
|
:defer t
|
||||||
|
:ensure t
|
||||||
|
:hook
|
||||||
|
(after-init . global-undo-tree-mode)
|
||||||
|
:init
|
||||||
|
(setq undo-tree-visualizer-timestamps t
|
||||||
|
undo-tree-visualizer-diff t
|
||||||
|
undo-limit 800000 ;; Limit for undo entries.
|
||||||
|
undo-strong-limit 12000000 ;; Strong limit for undo entries.
|
||||||
|
undo-outer-limit 120000000) ;; Outer limit for undo entries.
|
||||||
|
:config
|
||||||
|
(setq undo-tree-history-directory-alist '(("." . "~/.emacs.d/.cache/undo"))))
|
||||||
|
#+end_src
|
||||||
|
*** Dotenv mode
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(use-package dotenv-mode
|
||||||
|
:defer t
|
||||||
|
:ensure t)
|
||||||
|
#+end_src
|
||||||
|
*** Doom Modeline
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(use-package doom-modeline
|
||||||
|
:ensure t
|
||||||
|
:defer t
|
||||||
|
:custom
|
||||||
|
(doom-modeline-buffer-file-name-style 'buffer-name) ;; Set the buffer file name style to just the buffer name (without path).
|
||||||
|
(doom-modeline-project-detection 'project) ;; Enable project detection for displaying the project name.
|
||||||
|
(doom-modeline-buffer-name t) ;; Show the buffer name in the mode line.
|
||||||
|
(doom-modeline-vcs-max-length 25) ;; Limit the version control system (VCS) branch name length to 25 characters.
|
||||||
|
:config
|
||||||
|
(setq doom-modeline-icon t) ;; Enable icons in the mode line if nerd fonts are used.
|
||||||
|
:hook
|
||||||
|
(after-init . doom-modeline-mode))
|
||||||
|
#+end_src
|
||||||
|
*** Nerd icons
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(use-package nerd-icons
|
||||||
|
:ensure t
|
||||||
|
:defer t)
|
||||||
|
|
||||||
|
(use-package nerd-icons-dired
|
||||||
|
:ensure t ;; Ensure the package is installed.
|
||||||
|
:defer t ;; Load the package only when needed to improve startup time.
|
||||||
|
:hook
|
||||||
|
(dired-mode . nerd-icons-dired-mode))
|
||||||
|
|
||||||
|
(use-package nerd-icons-completion
|
||||||
|
:ensure t ;; Ensure the package is installed.
|
||||||
|
:after (:all nerd-icons marginalia) ;; Load after `nerd-icons' and `marginalia' to ensure proper integration.
|
||||||
|
:config
|
||||||
|
(nerd-icons-completion-mode) ;; Activate nerd icons for completion interfaces.
|
||||||
|
(add-hook 'marginalia-mode-hook #'nerd-icons-completion-marginalia-setup)) ;; Setup icons in the marginalia mode for enhanced completion display.
|
||||||
|
#+end_src
|
||||||
|
*** Path fixes
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(use-package exec-path-from-shell
|
||||||
|
:ensure t
|
||||||
|
:init
|
||||||
|
(exec-path-from-shell-initialize))
|
||||||
|
|
||||||
|
(use-package envrc
|
||||||
|
:ensure t
|
||||||
|
:init
|
||||||
|
(setq envrc-show-summary-in-minibuffer nil)
|
||||||
|
:hook
|
||||||
|
(after-init . envrc-global-mode))
|
||||||
|
#+end_src
|
||||||
|
*** Theme
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(use-package modus-themes
|
||||||
|
:ensure t
|
||||||
|
:config
|
||||||
|
(load-theme 'modus-operandi t))
|
||||||
|
#+end_src
|
||||||
@@ -5,6 +5,29 @@
|
|||||||
...
|
...
|
||||||
}: {
|
}: {
|
||||||
programs = {
|
programs = {
|
||||||
|
aerc = {
|
||||||
|
enable = true;
|
||||||
|
extraConfig = {
|
||||||
|
ui = {
|
||||||
|
sort = "-r arrival";
|
||||||
|
threading-enabled = true;
|
||||||
|
fuzzy-complete = true;
|
||||||
|
};
|
||||||
|
general = {
|
||||||
|
default-save-path = "~/Downloads";
|
||||||
|
log-file = "~/.aerc.log";
|
||||||
|
unsafe-accounts-conf = true;
|
||||||
|
};
|
||||||
|
compose = {
|
||||||
|
address-book-cmd = "notmuch address \"%s\"";
|
||||||
|
};
|
||||||
|
filters = {
|
||||||
|
"text/plain" = "colorize";
|
||||||
|
"text/calendar" = "calendar";
|
||||||
|
"text/html" = "html | colorize";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
msmtp = {
|
msmtp = {
|
||||||
enable = true;
|
enable = true;
|
||||||
};
|
};
|
||||||
@@ -32,10 +55,11 @@
|
|||||||
email = {
|
email = {
|
||||||
accounts.personal = {
|
accounts.personal = {
|
||||||
primary = true;
|
primary = true;
|
||||||
address = "michael@michaelthomson.dev";
|
address = "me@michaelthomson.dev";
|
||||||
realName = "Michael Thomson";
|
realName = "Michael Thomson";
|
||||||
userName = "michael@michaelthomson.dev";
|
userName = "me@michaelthomson.dev";
|
||||||
passwordCommand = "rbw get --folder email michael@michaelthomson.dev";
|
# passwordCommand = "rbw get --folder email me@michaelthomson.dev";
|
||||||
|
passwordCommand = "cat ~/auth/email";
|
||||||
mbsync = {
|
mbsync = {
|
||||||
enable = true;
|
enable = true;
|
||||||
create = "both";
|
create = "both";
|
||||||
@@ -61,6 +85,12 @@
|
|||||||
notmuch = {
|
notmuch = {
|
||||||
enable = true;
|
enable = true;
|
||||||
};
|
};
|
||||||
|
aerc = {
|
||||||
|
enable = true;
|
||||||
|
# extraAccounts = {
|
||||||
|
# source = "maildir://~/Maildir/work";
|
||||||
|
# };
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -11,9 +11,13 @@
|
|||||||
git = {
|
git = {
|
||||||
enable = true;
|
enable = true;
|
||||||
settings = {
|
settings = {
|
||||||
|
gpg = {
|
||||||
|
format = "ssh";
|
||||||
|
};
|
||||||
user = {
|
user = {
|
||||||
name = "Michael Thomson";
|
name = "Michael Thomson";
|
||||||
email = "michael@michaelthomson.dev";
|
email = "me@michaelthomson.dev";
|
||||||
|
signingkey = "~/.ssh/id_rsa.pub";
|
||||||
};
|
};
|
||||||
column = {
|
column = {
|
||||||
ui = "auto";
|
ui = "auto";
|
||||||
|
|||||||
@@ -11,6 +11,9 @@
|
|||||||
kompose
|
kompose
|
||||||
kubernetes-helm
|
kubernetes-helm
|
||||||
envsubst
|
envsubst
|
||||||
|
age
|
||||||
|
sops
|
||||||
|
kustomize
|
||||||
];
|
];
|
||||||
|
|
||||||
programs = {
|
programs = {
|
||||||
|
|||||||
@@ -51,6 +51,8 @@ in {
|
|||||||
];
|
];
|
||||||
notes = with pkgs; [
|
notes = with pkgs; [
|
||||||
zk
|
zk
|
||||||
|
tinymist
|
||||||
|
typst
|
||||||
];
|
];
|
||||||
lua = with pkgs; [
|
lua = with pkgs; [
|
||||||
lua-language-server
|
lua-language-server
|
||||||
@@ -74,6 +76,7 @@ in {
|
|||||||
vscode-langservers-extracted
|
vscode-langservers-extracted
|
||||||
stylelint-lsp
|
stylelint-lsp
|
||||||
tailwindcss-language-server
|
tailwindcss-language-server
|
||||||
|
vscode-css-languageserver
|
||||||
];
|
];
|
||||||
yaml = with pkgs; [
|
yaml = with pkgs; [
|
||||||
yaml-language-server
|
yaml-language-server
|
||||||
@@ -102,6 +105,7 @@ in {
|
|||||||
(nvim-treesitter.withPlugins (
|
(nvim-treesitter.withPlugins (
|
||||||
plugins:
|
plugins:
|
||||||
nvim-treesitter.allGrammars ++ [kulala-grammer]
|
nvim-treesitter.allGrammars ++ [kulala-grammer]
|
||||||
|
|
||||||
))
|
))
|
||||||
snacks-nvim
|
snacks-nvim
|
||||||
gruvbox-nvim
|
gruvbox-nvim
|
||||||
@@ -122,7 +126,7 @@ in {
|
|||||||
optionalPlugins = {
|
optionalPlugins = {
|
||||||
notes = with pkgs.vimPlugins; [
|
notes = with pkgs.vimPlugins; [
|
||||||
zk-nvim
|
zk-nvim
|
||||||
render-markdown-nvim
|
typst-preview-nvim
|
||||||
];
|
];
|
||||||
go = with pkgs.vimPlugins; [
|
go = with pkgs.vimPlugins; [
|
||||||
nvim-dap-go
|
nvim-dap-go
|
||||||
@@ -219,7 +223,7 @@ in {
|
|||||||
};
|
};
|
||||||
# anything else to pass and grab in lua with `nixCats.extra`
|
# anything else to pass and grab in lua with `nixCats.extra`
|
||||||
extra = {
|
extra = {
|
||||||
nixdExtras.nixpkgs = ''import ${pkgs.path} {}'';
|
nixdExtras.nixpkgs = ''import <nixpkgs> { }'';
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -206,70 +206,50 @@ require('lze').load {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"nvim-treesitter",
|
"nvim-treesitter",
|
||||||
enabled = nixCats('general') or false,
|
lazy = false,
|
||||||
event = "DeferredUIEnter",
|
after = function(plugin)
|
||||||
load = function (name)
|
---@param buf integer
|
||||||
vim.cmd.packadd(name)
|
---@param language string
|
||||||
vim.cmd.packadd("nvim-treesitter-textobjects")
|
local function treesitter_try_attach(buf, language)
|
||||||
end,
|
-- check if parser exists and load it
|
||||||
after = function (plugin)
|
if not vim.treesitter.language.add(language) then
|
||||||
require('nvim-treesitter.configs').setup {
|
return
|
||||||
highlight = { enable = true, },
|
end
|
||||||
indent = { enable = false, },
|
-- enables syntax highlighting and other treesitter features
|
||||||
incremental_selection = {
|
vim.treesitter.start(buf, language)
|
||||||
enable = true,
|
|
||||||
keymaps = {
|
-- enables treesitter based folds
|
||||||
init_selection = '<c-space>',
|
vim.wo.foldexpr = "v:lua.vim.treesitter.foldexpr()"
|
||||||
node_incremental = '<c-space>',
|
|
||||||
scope_incremental = '<c-s>',
|
-- enables treesitter based indentation
|
||||||
node_decremental = '<M-space>',
|
vim.bo.indentexpr = "v:lua.require'nvim-treesitter'.indentexpr()"
|
||||||
},
|
end
|
||||||
},
|
|
||||||
textobjects = {
|
local available_parsers = require("nvim-treesitter").get_available()
|
||||||
select = {
|
vim.api.nvim_create_autocmd("FileType", {
|
||||||
enable = true,
|
callback = function(args)
|
||||||
lookahead = true, -- Automatically jump forward to textobj, similar to targets.vim
|
local buf, filetype = args.buf, args.match
|
||||||
keymaps = {
|
local language = vim.treesitter.language.get_lang(filetype)
|
||||||
-- You can use the capture groups defined in textobjects.scm
|
if not language then
|
||||||
['aa'] = '@parameter.outer',
|
return
|
||||||
['ia'] = '@parameter.inner',
|
end
|
||||||
['af'] = '@function.outer',
|
|
||||||
['if'] = '@function.inner',
|
local installed_parsers = require("nvim-treesitter").get_installed("parsers")
|
||||||
['ac'] = '@class.outer',
|
|
||||||
['ic'] = '@class.inner',
|
if vim.tbl_contains(installed_parsers, language) then
|
||||||
},
|
-- enable the parser if it is installed
|
||||||
},
|
treesitter_try_attach(buf, language)
|
||||||
move = {
|
elseif vim.tbl_contains(available_parsers, language) then
|
||||||
enable = true,
|
-- if a parser is available in `nvim-treesitter` enable it after ensuring it is installed
|
||||||
set_jumps = true, -- whether to set jumps in the jumplist
|
require("nvim-treesitter").install(language):await(function()
|
||||||
goto_next_start = {
|
treesitter_try_attach(buf, language)
|
||||||
[']m'] = '@function.outer',
|
end)
|
||||||
[']]'] = '@class.outer',
|
else
|
||||||
},
|
-- try to enable treesitter features in case the parser exists but is not available from `nvim-treesitter`
|
||||||
goto_next_end = {
|
treesitter_try_attach(buf, language)
|
||||||
[']M'] = '@function.outer',
|
end
|
||||||
[']['] = '@class.outer',
|
end,
|
||||||
},
|
})
|
||||||
goto_previous_start = {
|
|
||||||
['[m'] = '@function.outer',
|
|
||||||
['[['] = '@class.outer',
|
|
||||||
},
|
|
||||||
goto_previous_end = {
|
|
||||||
['[M'] = '@function.outer',
|
|
||||||
['[]'] = '@class.outer',
|
|
||||||
},
|
|
||||||
},
|
|
||||||
swap = {
|
|
||||||
enable = true,
|
|
||||||
swap_next = {
|
|
||||||
['<leader>a'] = '@parameter.inner',
|
|
||||||
},
|
|
||||||
swap_previous = {
|
|
||||||
['<leader>A'] = '@parameter.inner',
|
|
||||||
},
|
|
||||||
},
|
|
||||||
},
|
|
||||||
}
|
|
||||||
end,
|
end,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -598,6 +578,24 @@ require('lze').load {
|
|||||||
})
|
})
|
||||||
end
|
end
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"obsidian.nvim",
|
||||||
|
enabled = nixCats('notes') or false,
|
||||||
|
ft = {"md"},
|
||||||
|
after = function ()
|
||||||
|
require("obsidian").setup({
|
||||||
|
workspaces = {
|
||||||
|
{
|
||||||
|
name = "everything",
|
||||||
|
path = "~/vaults/everything"
|
||||||
|
},
|
||||||
|
},
|
||||||
|
daily_notes = {
|
||||||
|
folder = "journal"
|
||||||
|
},
|
||||||
|
})
|
||||||
|
end
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"zk-nvim",
|
"zk-nvim",
|
||||||
enabled = nixCats('notes') or false,
|
enabled = nixCats('notes') or false,
|
||||||
@@ -612,10 +610,15 @@ require('lze').load {
|
|||||||
-- Create a new note after asking for its title.
|
-- Create a new note after asking for its title.
|
||||||
vim.api.nvim_set_keymap("n", "<leader>zn", "<Cmd>ZkNew { title = vim.fn.input('Title: ') }<CR>", opts)
|
vim.api.nvim_set_keymap("n", "<leader>zn", "<Cmd>ZkNew { title = vim.fn.input('Title: ') }<CR>", opts)
|
||||||
|
|
||||||
|
-- Create note from selection
|
||||||
|
vim.api.nvim_set_keymap("v", "<leader>znt", ":'<,'>ZkNewFromTitleSelection<CR>", opts)
|
||||||
|
|
||||||
-- Open notes.
|
-- Open notes.
|
||||||
vim.api.nvim_set_keymap("n", "<leader>zf", "<Cmd>ZkNotes { sort = { 'modified' } }<CR>", opts)
|
vim.api.nvim_set_keymap("n", "<leader>zf", "<Cmd>ZkNotes { sort = { 'modified' } }<CR>", opts)
|
||||||
-- Open notes associated with the selected tags.
|
-- Open notes associated with the selected tags.
|
||||||
vim.api.nvim_set_keymap("n", "<leader>zt", "<Cmd>ZkTags<CR>", opts)
|
vim.api.nvim_set_keymap("n", "<leader>zt", "<Cmd>ZkTags<CR>", opts)
|
||||||
|
-- show links in note
|
||||||
|
vim.api.nvim_set_keymap("n", "<leader>zl", "<Cmd>ZkLinks<CR>", opts)
|
||||||
|
|
||||||
-- Search for the notes matching a given query.
|
-- Search for the notes matching a given query.
|
||||||
vim.api.nvim_set_keymap("n", "<leader>zg", "<Cmd>ZkNotes { sort = { 'modified' }, match = { vim.fn.input('Search: ') } }<CR>", opts)
|
vim.api.nvim_set_keymap("n", "<leader>zg", "<Cmd>ZkNotes { sort = { 'modified' }, match = { vim.fn.input('Search: ') } }<CR>", opts)
|
||||||
@@ -624,11 +627,10 @@ require('lze').load {
|
|||||||
end
|
end
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"render-markdown.nvim",
|
"typst-preview.nvim",
|
||||||
enabled = nixCats('notes') or false,
|
enabled = nixCats('notes') or false,
|
||||||
ft = "markdown",
|
|
||||||
after = function ()
|
after = function ()
|
||||||
require('render-markdown').setup({})
|
require('typst-preview').setup({})
|
||||||
end
|
end
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -751,6 +753,11 @@ require('lze').load {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"tailwindcss",
|
"tailwindcss",
|
||||||
|
enabled = false,
|
||||||
|
lsp = {},
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"cssls",
|
||||||
enabled = nixCats('typescript') or false,
|
enabled = nixCats('typescript') or false,
|
||||||
lsp = {},
|
lsp = {},
|
||||||
},
|
},
|
||||||
@@ -783,6 +790,11 @@ require('lze').load {
|
|||||||
-- filetypes = { "go", "gomod", "gowork", "gotmpl" },
|
-- filetypes = { "go", "gomod", "gowork", "gotmpl" },
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"tinymist",
|
||||||
|
enabled = nixCats("notes") or false,
|
||||||
|
lsp = {},
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"nixd",
|
"nixd",
|
||||||
enabled = nixCats('nix') or false,
|
enabled = nixCats('nix') or false,
|
||||||
@@ -793,16 +805,6 @@ require('lze').load {
|
|||||||
nixpkgs = {
|
nixpkgs = {
|
||||||
expr = nixCats.extra("nixdExtras.nixpkgs") or [[import <nixpkgs> {}]],
|
expr = nixCats.extra("nixdExtras.nixpkgs") or [[import <nixpkgs> {}]],
|
||||||
},
|
},
|
||||||
options = {
|
|
||||||
nixos = {
|
|
||||||
-- nixdExtras.nixos_options = ''(builtins.getFlake "path:${builtins.toString inputs.self.outPath}").nixosConfigurations.configname.options''
|
|
||||||
expr = nixCats.extra("nixdExtras.nixos_options")
|
|
||||||
},
|
|
||||||
["home-manager"] = {
|
|
||||||
-- nixdExtras.home_manager_options = ''(builtins.getFlake "path:${builtins.toString inputs.self.outPath}").homeConfigurations.configname.options''
|
|
||||||
expr = nixCats.extra("nixdExtras.home_manager_options")
|
|
||||||
}
|
|
||||||
},
|
|
||||||
formatting = {
|
formatting = {
|
||||||
command = { "alejandra" }
|
command = { "alejandra" }
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user