update
This commit is contained in:
parent
be89c2a2e0
commit
27699896bf
11 changed files with 467 additions and 167 deletions
71
modules/home/apps/tools/emacs/default.nix
Normal file
71
modules/home/apps/tools/emacs/default.nix
Normal file
|
|
@ -0,0 +1,71 @@
|
|||
{
|
||||
lib,
|
||||
inputs,
|
||||
config,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
with lib;
|
||||
with lib.custom; let
|
||||
cfg = config.apps.tools.emacs;
|
||||
emacs = with pkgs;
|
||||
(emacsPackagesFor
|
||||
emacs30-pgtk)
|
||||
.emacsWithPackages (epkgs:
|
||||
with epkgs; [
|
||||
treesit-grammars.with-all-grammars
|
||||
vterm
|
||||
mu4e
|
||||
]);
|
||||
in {
|
||||
options.apps.tools.emacs = {
|
||||
enable = mkBoolOpt false "Enable Emacs";
|
||||
# doom = rec {
|
||||
# enable = mkBoolOpt false;
|
||||
# forgeUrl = mkOpt types.str "https://github.com";
|
||||
# repoUrl = mkOpt types.str "${forgeUrl}/doomemacs/doomemacs";
|
||||
# configRepoUrl = mkOpt types.str "${forgeUrl}/hlissner/.doom.d";
|
||||
# };
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
nixpkgs.overlays = [
|
||||
inputs.emacs-overlay.overlays.default
|
||||
];
|
||||
|
||||
home.packages = with pkgs; [
|
||||
## Emacs itself
|
||||
binutils # native-comp needs 'as', provided by this
|
||||
emacs # HEAD + native-comp
|
||||
|
||||
## Doom dependencies
|
||||
git
|
||||
ripgrep
|
||||
gnutls # for TLS connectivity
|
||||
|
||||
## Optional dependencies
|
||||
fd # faster projectile indexing
|
||||
imagemagick # for image-dired
|
||||
pinentry-emacs
|
||||
zstd # for undo-fu-session/undo-tree compression
|
||||
|
||||
## Module dependencies
|
||||
# :email mu4e
|
||||
mu
|
||||
isync
|
||||
# :checkers spell
|
||||
(aspellWithDicts (ds: with ds; [en en-computers en-science]))
|
||||
# :tools editorconfig
|
||||
editorconfig-core-c # per-project style config
|
||||
# :tools lookup & :lang org +roam
|
||||
sqlite
|
||||
# :lang latex & :lang org (latex previews)
|
||||
texlive.combined.scheme-medium
|
||||
# :lang beancount
|
||||
beancount
|
||||
fava
|
||||
# :lang nix
|
||||
age
|
||||
];
|
||||
};
|
||||
}
|
||||
|
|
@ -25,43 +25,44 @@ return {
|
|||
},
|
||||
},
|
||||
},
|
||||
-- {
|
||||
-- "saghen/blink.cmp",
|
||||
-- lazy = false, -- lazy loading handled internally
|
||||
-- -- optional: provides snippets for the snippet source
|
||||
-- dependencies = "rafamadriz/friendly-snippets",
|
||||
--
|
||||
-- -- use a release tag to download pre-built binaries
|
||||
-- version = "v0.*",
|
||||
-- -- OR build from source, requires nightly: https://rust-lang.github.io/rustup/concepts/channels.html#working-with-nightly-rust
|
||||
-- -- build = 'cargo build --release',
|
||||
--
|
||||
-- opts = {
|
||||
-- keymap = {
|
||||
-- show = "<C-S-space>",
|
||||
-- accept = "<Enter>",
|
||||
-- select_prev = { "<S-Tab>", "<C-j>" },
|
||||
-- select_next = { "<C-Tab>", "<C-k>" },
|
||||
--
|
||||
-- snippet_forward = "<Tab>",
|
||||
-- snippet_backward = "<C-S-Tab>",
|
||||
-- },
|
||||
--
|
||||
-- highlight = {
|
||||
-- -- sets the fallback highlight groups to nvim-cmp's highlight groups
|
||||
-- -- useful for when your theme doesn't support blink.cmp
|
||||
-- -- will be removed in a future release, assuming themes add support
|
||||
-- use_nvim_cmp_as_default = true,
|
||||
-- },
|
||||
-- -- set to 'mono' for 'Nerd Font Mono' or 'normal' for 'Nerd Font'
|
||||
-- -- adjusts spacing to ensure icons are aligned
|
||||
-- nerd_font_variant = "normal",
|
||||
--
|
||||
-- -- experimental auto-brackets support
|
||||
-- -- accept = { auto_brackets = { enabled = true } }
|
||||
--
|
||||
-- -- experimental signature help support
|
||||
-- -- trigger = { signature_help = { enabled = true } }
|
||||
-- },
|
||||
-- },
|
||||
{ "hrsh7th/nvim-cmp", enabled = false },
|
||||
{
|
||||
"saghen/blink.cmp",
|
||||
lazy = false, -- lazy loading handled internally
|
||||
-- optional: provides snippets for the snippet source
|
||||
dependencies = "rafamadriz/friendly-snippets",
|
||||
|
||||
-- use a release tag to download pre-built binaries
|
||||
version = "v0.*",
|
||||
-- OR build from source, requires nightly: https://rust-lang.github.io/rustup/concepts/channels.html#working-with-nightly-rust
|
||||
-- build = 'cargo build --release',
|
||||
|
||||
opts = {
|
||||
keymap = {
|
||||
show = "<C-S-space>",
|
||||
accept = "<Enter>",
|
||||
select_prev = { "<S-Tab>", "<C-j>" },
|
||||
select_next = { "<C-Tab>", "<C-k>" },
|
||||
|
||||
snippet_forward = "<Tab>",
|
||||
snippet_backward = "<C-S-Tab>",
|
||||
},
|
||||
|
||||
highlight = {
|
||||
-- sets the fallback highlight groups to nvim-cmp's highlight groups
|
||||
-- useful for when your theme doesn't support blink.cmp
|
||||
-- will be removed in a future release, assuming themes add support
|
||||
use_nvim_cmp_as_default = true,
|
||||
},
|
||||
-- set to 'mono' for 'Nerd Font Mono' or 'normal' for 'Nerd Font'
|
||||
-- adjusts spacing to ensure icons are aligned
|
||||
nerd_font_variant = "normal",
|
||||
|
||||
-- experimental auto-brackets support
|
||||
-- accept = { auto_brackets = { enabled = true } }
|
||||
|
||||
-- experimental signature help support
|
||||
-- trigger = { signature_help = { enabled = true } }
|
||||
},
|
||||
},
|
||||
}
|
||||
|
|
|
|||
|
|
@ -40,13 +40,12 @@ in {
|
|||
|
||||
config = mkIf cfg.enable {
|
||||
home.packages = [
|
||||
pkgs-unstable.xwayland
|
||||
pkgs.xwayland
|
||||
];
|
||||
|
||||
wayland.windowManager.hyprland = {
|
||||
enable = true;
|
||||
xwayland.enable = true;
|
||||
package = inputs.hyprland.packages.${pkgs.system}.hyprland;
|
||||
|
||||
systemd = {
|
||||
enable = true;
|
||||
|
|
@ -171,6 +170,10 @@ in {
|
|||
force_zero_scaling = true;
|
||||
};
|
||||
|
||||
cursor = {
|
||||
no_hardware_cursors = true;
|
||||
};
|
||||
|
||||
monitor = ["DP-1,2560x1440@240,0x0,1,bitdepth,10" "HDMI-A-1,disable" "DP-2,disable"];
|
||||
|
||||
layerrule = [
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue