Move espanso to home-manager
This commit is contained in:
parent
bc155e00c2
commit
a0faf3ccd7
|
@ -6,6 +6,7 @@
|
||||||
"${custom.inputs.self}/home-manager/software/calibre"
|
"${custom.inputs.self}/home-manager/software/calibre"
|
||||||
"${custom.inputs.self}/home-manager/software/czkawka"
|
"${custom.inputs.self}/home-manager/software/czkawka"
|
||||||
"${custom.inputs.self}/home-manager/software/emacs"
|
"${custom.inputs.self}/home-manager/software/emacs"
|
||||||
|
"${custom.inputs.self}/home-manager/software/espanso"
|
||||||
"${custom.inputs.self}/home-manager/software/evince"
|
"${custom.inputs.self}/home-manager/software/evince"
|
||||||
"${custom.inputs.self}/home-manager/software/fzf"
|
"${custom.inputs.self}/home-manager/software/fzf"
|
||||||
"${custom.inputs.self}/home-manager/software/git"
|
"${custom.inputs.self}/home-manager/software/git"
|
||||||
|
|
29
home-manager/software/espanso/default.nix
Normal file
29
home-manager/software/espanso/default.nix
Normal file
|
@ -0,0 +1,29 @@
|
||||||
|
{ ... }:
|
||||||
|
{
|
||||||
|
services.espanso = {
|
||||||
|
enable = true;
|
||||||
|
settings = {
|
||||||
|
matches = [
|
||||||
|
{
|
||||||
|
trigger = "<dd";
|
||||||
|
replace = "{{current_date}}";
|
||||||
|
vars = [{
|
||||||
|
name = "current_date";
|
||||||
|
type = "date";
|
||||||
|
params = { format = "%Y-%m-%d"; };
|
||||||
|
}];
|
||||||
|
}
|
||||||
|
{
|
||||||
|
trigger = "<ds";
|
||||||
|
replace = "{{current_date}}";
|
||||||
|
vars = [{
|
||||||
|
name = "current_date";
|
||||||
|
type = "date";
|
||||||
|
params = { format = "%Y-%m-%d_%H%M%S"; };
|
||||||
|
}];
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
|
@ -5,7 +5,6 @@
|
||||||
(import "${custom.inputs.self}/modules/droidcam" { inherit custom; })
|
(import "${custom.inputs.self}/modules/droidcam" { inherit custom; })
|
||||||
(import "${custom.inputs.self}/modules/email" { inherit custom; })
|
(import "${custom.inputs.self}/modules/email" { inherit custom; })
|
||||||
(import "${custom.inputs.self}/modules/eog" { inherit custom; })
|
(import "${custom.inputs.self}/modules/eog" { inherit custom; })
|
||||||
(import "${custom.inputs.self}/modules/espanso" { inherit custom; })
|
|
||||||
"${custom.inputs.self}/modules/gnome"
|
"${custom.inputs.self}/modules/gnome"
|
||||||
"${custom.inputs.self}/modules/hunspell"
|
"${custom.inputs.self}/modules/hunspell"
|
||||||
(import "${custom.inputs.self}/modules/libimobiledevice" { inherit custom; })
|
(import "${custom.inputs.self}/modules/libimobiledevice" { inherit custom; })
|
||||||
|
|
|
@ -1,28 +0,0 @@
|
||||||
{ custom }: { ... }:
|
|
||||||
{
|
|
||||||
services.espanso.enable = true;
|
|
||||||
home-manager.users.${custom.username} = {
|
|
||||||
xdg.configFile.espanso = {
|
|
||||||
target = "espanso/default.yml";
|
|
||||||
onChange = "systemctl --user restart espanso";
|
|
||||||
text = ''
|
|
||||||
matches:
|
|
||||||
- trigger: "<dd"
|
|
||||||
replace: "{{current_date}}"
|
|
||||||
vars:
|
|
||||||
- name: current_date
|
|
||||||
type: date
|
|
||||||
params:
|
|
||||||
format: "%Y-%m-%d"
|
|
||||||
- trigger: "<ds"
|
|
||||||
replace: "{{current_date}}"
|
|
||||||
vars:
|
|
||||||
- name: current_date
|
|
||||||
type: date
|
|
||||||
params:
|
|
||||||
format: "%Y-%m-%d_%H%M%S"
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user