Update kakoune config

work
mat ess 2022-07-20 22:19:32 -04:00
parent 847a29ba5e
commit 6cfc8b3e4a
4 changed files with 65 additions and 8 deletions

View File

@ -89,6 +89,22 @@
"type": "github" "type": "github"
} }
}, },
"luar-src": {
"flake": false,
"locked": {
"lastModified": 1644781788,
"narHash": "sha256-vHn/V3sfzaxaxF8OpA5jPEuPstOVwOiQrogdSGtT6X4=",
"owner": "gustavo-hms",
"repo": "luar",
"rev": "2f430316f8fc4d35db6c93165e2e77dc9f3d0450",
"type": "github"
},
"original": {
"owner": "gustavo-hms",
"repo": "luar",
"type": "github"
}
},
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1656782578, "lastModified": 1656782578,
@ -144,6 +160,7 @@
"flake-compat": "flake-compat", "flake-compat": "flake-compat",
"flake-utils": "flake-utils", "flake-utils": "flake-utils",
"home-manager": "home-manager", "home-manager": "home-manager",
"luar-src": "luar-src",
"nixpkgs": "nixpkgs", "nixpkgs": "nixpkgs",
"nixpkgs-master": "nixpkgs-master", "nixpkgs-master": "nixpkgs-master",
"nixpkgs-unstable": "nixpkgs-unstable" "nixpkgs-unstable": "nixpkgs-unstable"

View File

@ -14,29 +14,48 @@
home-manager.inputs.nixpkgs.follows = "nixpkgs-unstable"; home-manager.inputs.nixpkgs.follows = "nixpkgs-unstable";
# Other sources # Other sources
flake-compat = { url = github:edolstra/flake-compat; flake = false; };
flake-utils.url = github:numtide/flake-utils; flake-utils.url = github:numtide/flake-utils;
flake-compat = {
url = github:edolstra/flake-compat;
flake = false;
};
dark-mode-notify-src = { dark-mode-notify-src = {
url = github:bouk/dark-mode-notify; url = github:bouk/dark-mode-notify;
flake = false; flake = false;
}; };
luar-src = {
url = github:gustavo-hms/luar;
flake = false;
};
}; };
outputs = { self, darwin, nixpkgs, home-manager, flake-utils, ... }@inputs: outputs = { self, darwin, nixpkgs, home-manager, flake-utils, ... }@inputs:
let let
inherit (darwin.lib) darwinSystem; inherit (darwin.lib) darwinSystem;
inherit (inputs.nixpkgs-unstable.lib) attrValues makeOverridable optional optionalAttrs singleton; inherit (inputs.nixpkgs-unstable.lib)
attrValues
genAttrs
makeOverridable
optional
optionalAttrs
singleton;
# Configuration for `nixpkgs` # Configuration for `nixpkgs`
nixpkgsConfig = { nixpkgsConfig = {
config = { allowUnfree = true; }; config = { allowUnfree = true; };
overlays = attrValues self.overlays ++ singleton ( overlays = attrValues self.overlays ++ singleton (
final: prev: final: prev:
{ let
dark-mode-notify = final.callPackage ./pkgs/dark-mode-notify.nix { inherit (inputs) dark-mode-notify-src; }; buildPkg = name:
} // optionalAttrs final.callPackage
(./. + "/pkgs/${name}.nix")
{ "${name}-src" = inputs."${name}-src"; };
pkgs = [ "dark-mode-notify" "luar" ];
in
genAttrs pkgs buildPkg // optionalAttrs
(prev.stdenv.system == "aarch64-darwin") (prev.stdenv.system == "aarch64-darwin")
{ {
# Sub in x86 version of packages that don't build on Apple Silicon yet # Sub in x86 version of packages that don't build on Apple Silicon yet

View File

@ -1,6 +1,27 @@
{ ... }: { { pkgs, ... }: {
programs.kakoune = { programs.kakoune = {
enable = true; enable = true;
config = { }; config = {
numberLines = {
enable = true;
highlightCursor = true;
relative = true;
};
ui = {
enableMouse = true;
};
};
plugins = with pkgs.kakounePlugins; [
active-window-kak
auto-pairs-kak
fzf-kak
kak-lsp
kakboard
kakoune-state-save
kakoune-vertical-selection
# needs luar
pkgs.luar
tabs-kak
];
}; };
} }

View File

@ -2,10 +2,10 @@
, lib , lib
, xcodeenv , xcodeenv
, dark-mode-notify-src , dark-mode-notify-src
, sdkVersion ? "13.4.1"
, ... , ...
}: }:
let let
sdkVersion = "13.4.1";
xcode = xcodeenv.composeXcodeWrapper { xcode = xcodeenv.composeXcodeWrapper {
version = sdkVersion; version = sdkVersion;
xcodeBaseDir = "/Applications/Xcode.app"; xcodeBaseDir = "/Applications/Xcode.app";