mirror of
https://github.com/kmein/niveum
synced 2026-03-19 19:41:08 +01:00
feat: stable htmlq
This commit is contained in:
@@ -1,7 +1,4 @@
|
|||||||
{ lib, pkgs, ... }:
|
{ lib, pkgs, ... }:
|
||||||
let
|
|
||||||
nixpkgs-unstable = import <nixpkgs-unstable> {};
|
|
||||||
in
|
|
||||||
{
|
{
|
||||||
systemd.services.lb-subscription = {
|
systemd.services.lb-subscription = {
|
||||||
enable = true;
|
enable = true;
|
||||||
@@ -15,10 +12,10 @@ in
|
|||||||
first_year=2019
|
first_year=2019
|
||||||
for year in $(${pkgs.coreutils}/bin/seq "$first_year" "$(date +%Y)"); do
|
for year in $(${pkgs.coreutils}/bin/seq "$first_year" "$(date +%Y)"); do
|
||||||
${pkgs.curl}/bin/curl -sSL "https://www.literarische-blaetter.de/jahrgang-$year/" \
|
${pkgs.curl}/bin/curl -sSL "https://www.literarische-blaetter.de/jahrgang-$year/" \
|
||||||
| ${nixpkgs-unstable.htmlq}/bin/htmlq --attribute href 'ul.slides a' \
|
| ${pkgs.htmlq}/bin/htmlq --attribute href 'ul.slides a' \
|
||||||
| while read -r month; do
|
| while read -r month; do
|
||||||
${pkgs.curl}/bin/curl -sSL "$month" \
|
${pkgs.curl}/bin/curl -sSL "$month" \
|
||||||
| ${nixpkgs-unstable.htmlq}/bin/htmlq --attribute src iframe \
|
| ${pkgs.htmlq}/bin/htmlq --attribute src iframe \
|
||||||
| ${pkgs.gnused}/bin/sed 's/.*?pdf=//;s/?wp-hosted.*//'
|
| ${pkgs.gnused}/bin/sed 's/.*?pdf=//;s/?wp-hosted.*//'
|
||||||
done
|
done
|
||||||
done | ${pkgs.findutils}/bin/xargs ${pkgs.wget}/bin/wget --no-clobber
|
done | ${pkgs.findutils}/bin/xargs ${pkgs.wget}/bin/wget --no-clobber
|
||||||
|
|||||||
@@ -93,7 +93,7 @@ in {
|
|||||||
python3Packages.jsonschema # json validation
|
python3Packages.jsonschema # json validation
|
||||||
jq # json toolkit
|
jq # json toolkit
|
||||||
pup # html toolkit
|
pup # html toolkit
|
||||||
nixpkgs-unstable.htmlq
|
htmlq
|
||||||
xsv # csv toolkit
|
xsv # csv toolkit
|
||||||
xmlstarlet # xml toolkit
|
xmlstarlet # xml toolkit
|
||||||
manpages
|
manpages
|
||||||
|
|||||||
Reference in New Issue
Block a user