aboutsummaryrefslogtreecommitdiffstats
path: root/home/nom.nix
blob: be793b38b521269d2f32de6604765f60bedb7b02 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
{
  config,
  pkgs,
  lib,
  ...
}:

{
  home = {
    packages = [ pkgs.nom ];
    activation.writeNomConfig = lib.hm.dag.entryAfter [ "writeBoundary" ] ''
      mkdir -p $HOME/.config/nom
      cat > $HOME/.config/nom/config.yml <<EOF
      autoread: true
      ordering: desc
      showread: false
      openers:
      - regex: "youtube"
        cmd: "mpv %s"
      - regex: ".*"
        cmd: "${pkgs.firefox}/bin/firefox %s"
      refreshinterval: 5
      filtering:
        defaultIncludeFeedName: true
      backends:
        miniflux:
          host: https://flux.tammi.cc
          api_key: $( ${pkgs.coreutils}/bin/cat ${config.age.secrets.miniflux_api_key.path} )
      EOF
    '';
  };
}