~ruther/nixos-config

852a5059a5562a63a22325f83a19413eb051b71a — František Boháček 1 year, 6 months ago 9003b5b
feat: ensure ~/screens created
1 files changed, 13 insertions(+), 2 deletions(-)

M modules/services/flameshot.nix
M modules/services/flameshot.nix => modules/services/flameshot.nix +13 -2
@@ 4,13 4,15 @@

{ config, lib, pkgs, user, ... }:

{
let
  screensDir = "/home/${user}/screens";
in {
  services = {                                    # sxhkd shortcut = Printscreen button (Print)
    flameshot = {
      enable = true;
      settings = {
        General = {                               # Settings
          savePath = "/home/${user}/screens";
          savePath = screensDir;
          saveAsFileExtension = ".png";
          uiColor = "#2d0096";
          showHelp = "false";


@@ 19,4 21,13 @@
      };
    };
  };

  home.activations = {
    ensureScreensDirCreated = {
      after = [ "writeBoundary" ];
      data = ''
        mkdir -p ${screensDir}
      '';
    };
  };
}

Do not follow this link