mirror of
https://github.com/traxys/Nixfiles.git
synced 2026-02-14 19:30:19 +01:00
18 lines
392 B
Nix
18 lines
392 B
Nix
{ lib, config, ... }:
|
|
with lib;
|
|
{
|
|
options = {
|
|
commands = mkOption {
|
|
type = types.attrsOf types.str;
|
|
default = { };
|
|
description = "Extra commands to be created";
|
|
};
|
|
};
|
|
|
|
config.extraConfigVim =
|
|
let
|
|
commands =
|
|
cmds: concatStringsSep "\n" (map (cmd: "command ${cmd} ${getAttr cmd cmds}") (attrNames cmds));
|
|
in
|
|
commands config.commands;
|
|
}
|