From 4371a8a72dcaec6872db4e43536c3a088219f725 Mon Sep 17 00:00:00 2001 From: Colin Powell Date: Tue, 19 Nov 2024 11:56:27 -0500 Subject: [PATCH] [bin] Updating nyt download script --- bin/.bin/nyt | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/bin/.bin/nyt b/bin/.bin/nyt index 59b18fd..37cc375 100755 --- a/bin/.bin/nyt +++ b/bin/.bin/nyt @@ -1,5 +1,5 @@ #!/bin/bash -BASEDIR="/media/photos/nyt" +BASEDIR="/media/photos/misc/nytimes" DATE=$(date +"%Y-%m-%d") TMPFILE=/tmp/nyt.pdf OUTFILE=$BASEDIR/$DATE.jpg @@ -11,6 +11,7 @@ else curl -o /tmp/nyt.pdf -L https://static01.nyt.com/images/$DATEPATH/nytfrontpage/scan.pdf convert -density 150 -quality 75 $TMPFILE $OUTFILE ln -sf $OUTFILE /var/lib/weewx/www/today.jpg - curl -H "X-Title: NYT headlines today" -d "https://wx.lab.unbl.ink/today.jpg" https://ntfy.unbl.ink/news + ln -sf $OUTFILE $BASEDIR/today.jpg + curl -H "X-Title: NYT headlines today" -d "https://files.lab.unbl.ink/nytimes/today.jpg" https://ntfy.unbl.ink/news rm $TMPFILE fi