fix(zathura): use absolute path for matugen config and ensure file exists
- Updated 'extraConfig' to use an absolute path for the 'zathura-matugen' include, fixing path resolution issues. - Added a home activation script to create an empty 'zathura-matugen' file if it doesn't exist, preventing zathura from crashing on fresh installs before matugen has run.
This commit is contained in:
@@ -1,4 +1,4 @@
|
|||||||
{ pkgs, ... }:
|
{ pkgs, config, lib, ... }:
|
||||||
{
|
{
|
||||||
programs.zathura = {
|
programs.zathura = {
|
||||||
enable = true;
|
enable = true;
|
||||||
@@ -12,9 +12,15 @@
|
|||||||
zoom-min = 10;
|
zoom-min = 10;
|
||||||
recolor = true;
|
recolor = true;
|
||||||
};
|
};
|
||||||
extraConfig = "include zathura-matugen";
|
extraConfig = "include ${config.home.homeDirectory}/.config/zathura/zathura-matugen";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
home.activation.createZathuraMatugen = lib.hm.dag.entryAfter ["writeBoundary"] ''
|
||||||
|
if [ ! -f "${config.home.homeDirectory}/.config/zathura/zathura-matugen" ]; then
|
||||||
|
touch "${config.home.homeDirectory}/.config/zathura/zathura-matugen"
|
||||||
|
fi
|
||||||
|
'';
|
||||||
|
|
||||||
xdg.mimeApps = {
|
xdg.mimeApps = {
|
||||||
enable = true;
|
enable = true;
|
||||||
defaultApplications = {
|
defaultApplications = {
|
||||||
|
|||||||
Reference in New Issue
Block a user