mirror of
https://gitlab.com/upRootNutrition/dotfiles.git
synced 2025-06-15 09:35:12 -05:00
feat: cleaned up espanso
This commit is contained in:
parent
0ddf9cd1ce
commit
3d6ee99ecb
9 changed files with 91 additions and 142 deletions
6
modules/home/gui/apps/tools/espanso/config/academic.nix
Executable file
6
modules/home/gui/apps/tools/espanso/config/academic.nix
Executable file
|
@ -0,0 +1,6 @@
|
||||||
|
{ matchHelper, ... }:
|
||||||
|
[
|
||||||
|
(matchHelper ":dag1" "†")
|
||||||
|
(matchHelper ":dag2" "‡")
|
||||||
|
(matchHelper ":glp" "GLP-1RA")
|
||||||
|
]
|
7
modules/home/gui/apps/tools/espanso/config/base.nix
Executable file
7
modules/home/gui/apps/tools/espanso/config/base.nix
Executable file
|
@ -0,0 +1,7 @@
|
||||||
|
{ matchHelper, ... }:
|
||||||
|
[
|
||||||
|
(matchHelper ":up" "↑")
|
||||||
|
(matchHelper ":down" "↓")
|
||||||
|
(matchHelper ":left" "←")
|
||||||
|
(matchHelper ":right" "→")
|
||||||
|
]
|
6
modules/home/gui/apps/tools/espanso/config/characters.nix
Executable file
6
modules/home/gui/apps/tools/espanso/config/characters.nix
Executable file
|
@ -0,0 +1,6 @@
|
||||||
|
{ matchHelper, ... }:
|
||||||
|
[
|
||||||
|
(matchHelper ":delta" "Δ")
|
||||||
|
(matchHelper ":emdash" "—")
|
||||||
|
(matchHelper ":degree" "°")
|
||||||
|
]
|
8
modules/home/gui/apps/tools/espanso/config/debate.nix
Executable file
8
modules/home/gui/apps/tools/espanso/config/debate.nix
Executable file
|
@ -0,0 +1,8 @@
|
||||||
|
{ matchHelper, ... }:
|
||||||
|
[
|
||||||
|
(matchHelper ":ntt" ''
|
||||||
|
World A) Animals farmed for food.
|
||||||
|
World B) Humans farmed for food.
|
||||||
|
|
||||||
|
All else equal, what is true of world A that is untrue of world B, that if made true of world B, would make world B permissible?'')
|
||||||
|
]
|
9
modules/home/gui/apps/tools/espanso/config/email.nix
Executable file
9
modules/home/gui/apps/tools/espanso/config/email.nix
Executable file
|
@ -0,0 +1,9 @@
|
||||||
|
{ flake, matchHelper, ... }:
|
||||||
|
let
|
||||||
|
inherit (flake.config.people) user0;
|
||||||
|
inherit (flake.config.people.users.${user0}) email;
|
||||||
|
in
|
||||||
|
[
|
||||||
|
(matchHelper ":mail0" email.address0)
|
||||||
|
(matchHelper ":mail1" email.address2)
|
||||||
|
]
|
11
modules/home/gui/apps/tools/espanso/config/logic.nix
Executable file
11
modules/home/gui/apps/tools/espanso/config/logic.nix
Executable file
|
@ -0,0 +1,11 @@
|
||||||
|
{ matchHelper, ... }:
|
||||||
|
[
|
||||||
|
(matchHelper ":neg" "¬")
|
||||||
|
(matchHelper ":conj" "∧")
|
||||||
|
(matchHelper ":disj" "∨")
|
||||||
|
(matchHelper ":imp" "→")
|
||||||
|
(matchHelper ":bicon" "↔")
|
||||||
|
(matchHelper ":forall" "∀")
|
||||||
|
(matchHelper ":exist" "∃")
|
||||||
|
(matchHelper ":therefore" "∴")
|
||||||
|
]
|
13
modules/home/gui/apps/tools/espanso/config/superscript.nix
Executable file
13
modules/home/gui/apps/tools/espanso/config/superscript.nix
Executable file
|
@ -0,0 +1,13 @@
|
||||||
|
{ matchHelper, ... }:
|
||||||
|
[
|
||||||
|
(matchHelper ":ss1" "¹")
|
||||||
|
(matchHelper ":ss2" "²")
|
||||||
|
(matchHelper ":ss3" "³")
|
||||||
|
(matchHelper ":ss4" "⁴")
|
||||||
|
(matchHelper ":ss5" "⁵")
|
||||||
|
(matchHelper ":ss6" "⁶")
|
||||||
|
(matchHelper ":ss7" "⁷")
|
||||||
|
(matchHelper ":ss8" "⁸")
|
||||||
|
(matchHelper ":ss9" "⁹")
|
||||||
|
(matchHelper ":ss0" "⁰")
|
||||||
|
]
|
10
modules/home/gui/apps/tools/espanso/config/url.nix
Executable file
10
modules/home/gui/apps/tools/espanso/config/url.nix
Executable file
|
@ -0,0 +1,10 @@
|
||||||
|
{ flake, matchHelper, ... }:
|
||||||
|
let
|
||||||
|
inherit (flake.config.services.instances) forgejo mastodon web;
|
||||||
|
in
|
||||||
|
[
|
||||||
|
(matchHelper ":dotfiles" "https://gitlab.com/upRootNutrition/dotfiles")
|
||||||
|
(matchHelper ":website" "https://${web.domains.url3}")
|
||||||
|
(matchHelper ":forgejo" "https://${forgejo.subdomain}.${web.domains.url3}")
|
||||||
|
(matchHelper ":mastodon" "https://${mastodon.subdomain}.${web.domains.url3}")
|
||||||
|
]
|
|
@ -4,8 +4,26 @@
|
||||||
...
|
...
|
||||||
}:
|
}:
|
||||||
let
|
let
|
||||||
inherit (flake.config.people) user0;
|
|
||||||
inherit (flake.config.people.users.${user0}) email;
|
matchHelper = trigger: replace: {
|
||||||
|
trigger = trigger;
|
||||||
|
replace = replace;
|
||||||
|
};
|
||||||
|
|
||||||
|
configPath = ./config;
|
||||||
|
|
||||||
|
baseMatches = {
|
||||||
|
matches =
|
||||||
|
[ ]
|
||||||
|
++ (import (configPath + /base.nix) { inherit matchHelper; })
|
||||||
|
++ (import (configPath + /url.nix) { inherit flake matchHelper; })
|
||||||
|
++ (import (configPath + /logic.nix) { inherit matchHelper; })
|
||||||
|
++ (import (configPath + /debate.nix) { inherit matchHelper; })
|
||||||
|
++ (import (configPath + /characters.nix) { inherit matchHelper; })
|
||||||
|
++ (import (configPath + /academic.nix) { inherit matchHelper; })
|
||||||
|
++ (import (configPath + /superscript.nix) { inherit matchHelper; })
|
||||||
|
++ (import (configPath + /email.nix) { inherit flake matchHelper; });
|
||||||
|
};
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
services.espanso = {
|
services.espanso = {
|
||||||
|
@ -18,146 +36,7 @@ in
|
||||||
};
|
};
|
||||||
package = pkgs.espanso-wayland;
|
package = pkgs.espanso-wayland;
|
||||||
matches = {
|
matches = {
|
||||||
base = {
|
base = baseMatches;
|
||||||
matches = [
|
|
||||||
{
|
|
||||||
trigger = ":up";
|
|
||||||
replace = "↑";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":down";
|
|
||||||
replace = "↓";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":left";
|
|
||||||
replace = "←";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":right";
|
|
||||||
replace = "→";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":neg";
|
|
||||||
replace = "¬";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":conj";
|
|
||||||
replace = "∧";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":disj";
|
|
||||||
replace = "∨";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":imp";
|
|
||||||
replace = "→";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":bicon";
|
|
||||||
replace = "↔";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":forall";
|
|
||||||
replace = "∀";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":exist";
|
|
||||||
replace = "∃";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":therefore";
|
|
||||||
replace = "∴";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":delta";
|
|
||||||
replace = "Δ";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":emdash";
|
|
||||||
replace = "—";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":dag1";
|
|
||||||
replace = "†";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":dag2";
|
|
||||||
replace = "‡";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":glp";
|
|
||||||
replace = "GLP-1RA";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":degree";
|
|
||||||
replace = "°";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":ss1";
|
|
||||||
replace = "¹";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":ss2";
|
|
||||||
replace = "²";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":ss3";
|
|
||||||
replace = "³";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":ss4";
|
|
||||||
replace = "⁴";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":ss5";
|
|
||||||
replace = "⁵";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":ss6";
|
|
||||||
replace = "⁶";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":ss7";
|
|
||||||
replace = "⁷";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":ss8";
|
|
||||||
replace = "⁸";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":ss9";
|
|
||||||
replace = "⁹";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":ss0";
|
|
||||||
replace = "⁰";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":ntt";
|
|
||||||
replace = ''
|
|
||||||
World A) Animals farmed for food.
|
|
||||||
World B) Humans farmed for food.
|
|
||||||
|
|
||||||
All else equal, what is true of world A that is untrue of world B, that if made true of world B, would make world B permissible?'';
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":dotfiles";
|
|
||||||
replace = "https://gitlab.com/upRootNutrition/dotfiles";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":website";
|
|
||||||
replace = "https://uprootnutrition.com";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":mail0";
|
|
||||||
replace = email.address0;
|
|
||||||
}
|
|
||||||
{
|
|
||||||
trigger = ":mail1";
|
|
||||||
replace = email.address2;
|
|
||||||
}
|
|
||||||
];
|
|
||||||
};
|
|
||||||
global_vars = {
|
global_vars = {
|
||||||
global_vars = [
|
global_vars = [
|
||||||
{
|
{
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue