ce53df1a89
This reverts commit 6dc3a96a30
.
59 lines
1.4 KiB
Nix
59 lines
1.4 KiB
Nix
{ config, pkgs, lib, ... }:
|
|
let
|
|
inherit (pkgs.uservars) key dmenu editor theme accent;
|
|
inherit (theme) color;
|
|
in
|
|
{
|
|
config = {
|
|
programs.kakoune = {
|
|
enable = true;
|
|
extraConfig =
|
|
lib.concatStringsSep "\n"
|
|
(map (lib.readFile) ([
|
|
./filetypes.kak
|
|
./hooks.kak
|
|
./indent.kak
|
|
./keys.kak
|
|
./plug.kak
|
|
./usermode.kak
|
|
./git-mode.kak
|
|
] ++ lib.optional (dmenu == "rofi") ./rofi-commands.kak)) + ''
|
|
|
|
set global scrolloff 10,20
|
|
set global autoreload yes
|
|
set global startup_info_version 20200901
|
|
|
|
'' + (import ./colors.nix {
|
|
inherit pkgs lib color accent;
|
|
});
|
|
};
|
|
home.file = { ".config/kak-lsp/kak-lsp.toml".source = ./kak-lsp.toml; };
|
|
home.packages = with pkgs; [
|
|
kakoune
|
|
terminal
|
|
ranger
|
|
bmenu
|
|
kak-lsp
|
|
kak-pager
|
|
kak-man-pager
|
|
|
|
aspell
|
|
aspellDicts.en
|
|
aspellDicts.pt_BR
|
|
];
|
|
home.activation = {
|
|
update_kakoune = lib.hm.dag.entryAfter [ "writeBoundary" ] ''
|
|
$DRY_RUN_CMD kak -clear &&
|
|
$DRY_RUN_CMD kak -l | xargs -r -n1 kak -e "config-source;quit" -ui dummy -c ||
|
|
$DRY_RUN_CMD true
|
|
'';
|
|
};
|
|
home.sessionVariables = lib.mkIf (editor == "kakoune") {
|
|
EDITOR = "kak";
|
|
# Some plugins(kak_ansi) like to compile stuff
|
|
CC = "cc";
|
|
};
|
|
};
|
|
}
|
|
|