mirror of
https://gitlab.com/upRootNutrition/dotfiles.git
synced 2025-06-15 09:35:12 -05:00
62 lines
1.2 KiB
Nix
Executable file
62 lines
1.2 KiB
Nix
Executable file
{
|
|
flake,
|
|
lib,
|
|
pkgs,
|
|
...
|
|
}:
|
|
let
|
|
matchHelper = trigger: replace: {
|
|
trigger = trigger;
|
|
replace = replace;
|
|
};
|
|
configPath = ./config;
|
|
|
|
configs = {
|
|
url = { inherit flake matchHelper; };
|
|
logic = { inherit matchHelper; };
|
|
debate = { inherit matchHelper; };
|
|
characters = { inherit matchHelper; };
|
|
academic = { inherit matchHelper; };
|
|
numbers = { inherit matchHelper; };
|
|
email = { inherit flake matchHelper; };
|
|
};
|
|
|
|
baseMatches = {
|
|
matches = lib.concatMap (name: import (configPath + "/${name}.nix") configs.${name}) (
|
|
builtins.attrNames configs
|
|
);
|
|
};
|
|
in
|
|
{
|
|
services.espanso = {
|
|
enable = true;
|
|
configs = {
|
|
default = {
|
|
pre_paste_delay = 0;
|
|
show_notifications = false;
|
|
};
|
|
};
|
|
package = pkgs.espanso-wayland;
|
|
matches = {
|
|
base = baseMatches;
|
|
global_vars = {
|
|
global_vars = [
|
|
{
|
|
name = "currentdate";
|
|
type = "date";
|
|
params = {
|
|
format = "%d/%m/%Y";
|
|
};
|
|
}
|
|
{
|
|
name = "currenttime";
|
|
type = "date";
|
|
params = {
|
|
format = "%R";
|
|
};
|
|
}
|
|
];
|
|
};
|
|
};
|
|
};
|
|
}
|