summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuke Bratch <luke@bratch.co.uk>2023-02-02 11:40:45 +0000
committerLuke Bratch <luke@bratch.co.uk>2023-02-02 11:40:45 +0000
commit1a715e928bf0c3fbfcef329f955e598477f7e8ad (patch)
tree5012c12b974121c3fb306fb9f951910e98a7f3cc
parenta84ed1a96c6df7f103fde765c023c6f459d4a2f4 (diff)
Remove stray \ before / to please grep-3.8.
-rwxr-xr-xtitle.bash2
1 files changed, 1 insertions, 1 deletions
diff --git a/title.bash b/title.bash
index 36ee3f6..5736e0a 100755
--- a/title.bash
+++ b/title.bash
@@ -96,7 +96,7 @@ else
xmllint --xpath 'string(/meta/@content)' <(grep -Em1 '<.*meta.*property.*og:title' /tmp/$TIME.body) 2> /dev/null
# None found, look for HTML <title>
if [ "$?" -ne 0 ] ; then
- cat /tmp/$TIME.body | tr '\n' ' ' | tr '\r' ' ' | grep -oiE '<title[^>]*>([^<]+)<\/title>' | head -1 | sed -r 's/<title[^>]*//I; s/^>//I; s/<\/title>$//I' | php -r 'while(($line=fgets(STDIN)) !== FALSE) echo html_entity_decode($line, ENT_QUOTES|ENT_HTML401);'
+ cat /tmp/$TIME.body | tr '\n' ' ' | tr '\r' ' ' | grep -oiE '<title[^>]*>([^<]+)</title>' | head -1 | sed -r 's/<title[^>]*//I; s/^>//I; s/<\/title>$//I' | php -r 'while(($line=fgets(STDIN)) !== FALSE) echo html_entity_decode($line, ENT_QUOTES|ENT_HTML401);'
fi
fi
rm /tmp/$TIME.header /tmp/$TIME.body