config/modules/kak/kakoune.nix

71 lines
1.2 KiB
Nix
Raw Normal View History

2022-05-15 23:32:21 +02:00
# Preconfigured kakoune editor.
{
# Feature flags
2022-06-22 16:51:02 +02:00
clipboard ? false,
2022-05-15 23:32:21 +02:00
typescript ? false,
haskell ? false,
2022-06-22 16:51:02 +02:00
clojure ? false,
2022-05-15 23:32:21 +02:00
python ? false,
rust ? false,
nix ? true,
# Allow extra plugins to be defined
# outside of the package
extraPlugins ? [],
2022-06-22 16:53:20 +02:00
# Plugins
kak-crosshairs,
2022-05-16 17:44:49 +02:00
2022-05-15 23:32:21 +02:00
# Color theme
theme,
# Build context
pkgs,
lib
}:
let kakrc = (import ./kakrc.nix {
2022-06-22 16:53:20 +02:00
inherit clipboard
typescript
haskell
clojure
python
rust
nix
theme
pkgs
lib;
});
2022-05-15 23:32:21 +02:00
colors = (import ./colors.nix {
2022-06-22 16:53:20 +02:00
inherit theme
pkgs
lib;
2022-05-15 23:32:21 +02:00
});
kak-lsp = (import ./kak-lsp.nix {
2022-06-22 16:53:20 +02:00
inherit typescript
haskell
clojure
python
rust
nix
pkgs
lib;
2022-05-15 23:32:21 +02:00
});
in (pkgs.kakoune.override {
plugins = [
# Configuration
kak-lsp
colors
kakrc
# Plugins
2022-05-16 17:44:49 +02:00
kak-crosshairs
2022-05-15 23:32:21 +02:00
] ++ extraPlugins;
})