[feat] Add newsboat config

This commit is contained in:
uttarayan21
2024-03-17 04:02:03 +05:30
parent e0dffb350d
commit 8849c51765
5 changed files with 60 additions and 2 deletions

View File

@@ -6,12 +6,14 @@
./nvim.nix
./goread.nix
./tuifeed.nix
./newsboat.nix
] ++ lib.optionals device.isLinux [ ../linux ];
home.packages = with pkgs;
[
tuifeed
newsboat
russ
picat
spotdl
davis

50
common/newsboat.nix Normal file
View File

@@ -0,0 +1,50 @@
{ pkgs, ... }: {
programs.newsboat = {
enable = false;
urls = [
{
title = "r/rust";
url = "https://www.reddit.com/r/rust/.rss";
tags = [ "rust" ];
}
{
title = "the square planet";
url = "https://thesquareplanet.com/feed.xml";
tags = [ "rust" ];
}
{
title = "Jon Gjengset's YouTube";
url =
"https://www.youtube.com/feeds/videos.xml?channel_id=UC_iD0xppBwwsrM9DegC5cQQ";
tags = [ "rust" "youtube" ];
}
];
extraConfig =
let
dracula = builtins.fetchurl {
url = "https://raw.githubusercontent.com/dracula/newsboat/main/newsboat";
sha256 = "sha256:08b00ilc5zk5fkzqqd6aghcpya3d00s9kvv65b8c50rg7ikm88xr";
};
in
''
include ${dracula}
unbind-key g
bind-key g home
unbind-key G
bind-key G end
unbind-key h
unbind-key j
unbind-key k
unbind-key l
bind-key h quit
bind-key j down
bind-key k up
bind-key l open
'';
browser = "${pkgs.handlr-xdg}/bin/xdg-open";
maxItems = 50;
autoReload = true;
};
}

View File

@@ -44,6 +44,7 @@
},
'';
};
clangd.enable = true;
lua-language-server.enable = true;
jsonls.enable = true;
html.enable = true;

View File

@@ -1,7 +1,7 @@
{ ... }: {
imports = [ ../modules/tuifeed.nix ];
programs.tuifeed = {
enable = true;
enable = false;
config = {
sources = {
"r/rust" = "https://www.reddit.com/r/rust/.rss";

View File

@@ -54,4 +54,9 @@ in
rev = "v1.0";
sha256 = "sha256-vfwfBE3iqIN1cGoItSssR7h0z6tuJAhNarkziGFlNBw";
};
newsboat = mkCatppuccin {
item = "newsboat";
rev = "main";
sha256 = "sha256-czvR3bVZ0NfBmuu0JixalS7B1vf1uEGSTSUVVTclKxI";
};
}