File tree Expand file tree Collapse file tree 1 file changed +6
-5
lines changed Expand file tree Collapse file tree 1 file changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -576,14 +576,15 @@ $G/dlangspec.verbatim.txt : $G/dlangspec-consolidated.d $(DMD) verbatim.ddoc
576
576
# Fetch the latest article from the official D blog
577
577
# ###############################################################################
578
578
579
- $G/dblog_latest.ddoc :
579
+ $G/dblog_latest.html :
580
580
@echo " Receiving the latest DBlog article. Disable with DIFFABLE=1"
581
- curl -s --fail --retry 3 --retry-delay 5 http://blog.dlang.org > $(TMP ) /blog.html
582
- @[ $? -eq 0 ] || (echo " Curl couldn't connect to the DBlog." ; exit 1)
583
- cat $(TMP ) /blog.html | grep -m1 ' entry-title' | \
581
+ curl -s --fail --retry 3 --retry-delay 5 http://blog.dlang.org -o $@
582
+
583
+ $G/dblog_latest.ddoc : $G/dblog_latest.html
584
+ cat $< | grep -m1 ' entry-title' | \
584
585
sed -E ' s/^.*<a href="(.+)" rel="bookmark">([^<]+)<\/a>.*<time.*datetime="[^"]+">([^<]*)<\/time><time class="updated".*Author *<\/span><a [^>]+>([^<]+)<\/a>.*/DBLOG_LATEST_TITLE=\2|DBLOG_LATEST_LINK=\1|DBLOG_LATEST_DATE=\3|DBLOG_LATEST_AUTHOR=\4/' | \
585
586
tr ' |' ' \n' > $@
586
- cat $( TMP ) /blog.html | grep -m2 ' entry-title' | tail -n1 | \
587
+ cat $< | grep -m2 ' entry-title' | tail -n1 | \
587
588
sed -E ' s/^.*<a href="(.+)" rel="bookmark">([^<]+)<\/a>.*<time.*datetime="[^"]+">([^<]*)<\/time><time class="updated".*Author *<\/span><a [^>]+>([^<]+)<\/a>.*/DBLOG_LATEST_TITLE2=\2|DBLOG_LATEST_LINK2=\1|DBLOG_LATEST_DATE2=\3|DBLOG_LATEST_AUTHOR2=\4/' | \
588
589
tr ' |' ' \n' > $(basename $@ ) 2.ddoc
589
590
rm $(TMP ) /blog.html
You can’t perform that action at this time.
0 commit comments