Add watchfeeds and news command
This commit is contained in:
parent
9f0bb04cb8
commit
d2968d8007
|
@ -65,7 +65,8 @@ in
|
||||||
Browser = fork "firefox";
|
Browser = fork "firefox";
|
||||||
"Private Browser" = fork "firefox --private-window";
|
"Private Browser" = fork "firefox --private-window";
|
||||||
Chromium = fork "chromium";
|
Chromium = fork "chromium";
|
||||||
Watchfeeds = "newsboat -r";
|
Watchfeeds = "watchfeeds";
|
||||||
|
News = "news";
|
||||||
Games = {
|
Games = {
|
||||||
Steam = fork "steam";
|
Steam = fork "steam";
|
||||||
Minecraft = fork "minecraft-launcher";
|
Minecraft = fork "minecraft-launcher";
|
||||||
|
|
|
@ -15,17 +15,11 @@ let
|
||||||
</rss>
|
</rss>
|
||||||
EOF
|
EOF
|
||||||
'';
|
'';
|
||||||
in
|
watchfeedsConfig = ''
|
||||||
{
|
datetime-format "%Y-%m-%d"
|
||||||
home = {
|
cleanup-on-quit no
|
||||||
file = {
|
'';
|
||||||
"newsboat-config" = {
|
watchfeeds = [
|
||||||
target = ".newsboat/config";
|
|
||||||
text = "datetime-format \"%Y-%m-%d\"";
|
|
||||||
};
|
|
||||||
"newsboat-urls" = {
|
|
||||||
target = ".newsboat/urls";
|
|
||||||
text = lib.concatStringsSep "\n" [
|
|
||||||
# Haskell
|
# Haskell
|
||||||
"https://www.youtube.com/feeds/videos.xml?channel_id=UCI1Z201n-8OelkSg0DVOsng" # Tweag
|
"https://www.youtube.com/feeds/videos.xml?channel_id=UCI1Z201n-8OelkSg0DVOsng" # Tweag
|
||||||
"https://www.youtube.com/feeds/videos.xml?channel_id=UCxVE_2I_fsOe3Mgn_QlXqbQ" # Nomeata
|
"https://www.youtube.com/feeds/videos.xml?channel_id=UCxVE_2I_fsOe3Mgn_QlXqbQ" # Nomeata
|
||||||
|
@ -40,9 +34,20 @@ in
|
||||||
"https://www.youtube.com/feeds/videos.xml?channel_id=UCpXBGqwsBkpvcYjsJBQ7LEQ" # Critical Role
|
"https://www.youtube.com/feeds/videos.xml?channel_id=UCpXBGqwsBkpvcYjsJBQ7LEQ" # Critical Role
|
||||||
"exec:${serien}"
|
"exec:${serien}"
|
||||||
];
|
];
|
||||||
|
newsConfig = ''
|
||||||
|
${watchfeedsConfig}
|
||||||
|
urls-source "ocnews"
|
||||||
|
ocnews-url "https://cloud.maralorn.de"
|
||||||
|
ocnews-login "maralorn"
|
||||||
|
ocnews-password "${(pkgs.privateValue { adminpass =""; } "nextcloud-admin").adminpass}"
|
||||||
|
'';
|
||||||
|
in
|
||||||
|
{
|
||||||
|
xdg.configFile."newsboat/urls".text = lib.concatStringsSep "\n" watchfeeds;
|
||||||
|
home = {
|
||||||
|
packages = builtins.attrValues {
|
||||||
|
news = pkgs.writeShellScriptBin "news" "${pkgs.newsboat}/bin/newsboat -r -C ${builtins.toFile "news-config" newsConfig}";
|
||||||
|
watchfeeds = pkgs.writeShellScriptBin "watchfeeds" "${pkgs.newsboat}/bin/newsboat -r -C ${builtins.toFile "watchfeeds-config" watchfeedsConfig}";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
packages = builtins.attrValues rec { inherit (pkgs) newsboat; };
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -20,9 +20,9 @@ let
|
||||||
".local/share/khal"
|
".local/share/khal"
|
||||||
".local/share/mpd"
|
".local/share/mpd"
|
||||||
".local/share/waydroid"
|
".local/share/waydroid"
|
||||||
|
".local/share/newsboat"
|
||||||
".mozilla/firefox/maralorn-default"
|
".mozilla/firefox/maralorn-default"
|
||||||
".minecraft"
|
".minecraft"
|
||||||
".newsboat"
|
|
||||||
".ssh"
|
".ssh"
|
||||||
".task"
|
".task"
|
||||||
".vdirsyncer"
|
".vdirsyncer"
|
||||||
|
|
Loading…
Reference in a new issue