Code

lyrics: lyrics area regex fix for LyricWikia
authorLazaros Koromilas <lostd@2f30.org>
Thu, 10 Nov 2016 17:04:47 +0000 (18:04 +0100)
committerMax Kellermann <max.kellermann@gmail.com>
Tue, 3 Jan 2017 19:45:34 +0000 (20:45 +0100)
NEWS
lyrics/20-lyricwiki.rb

diff --git a/NEWS b/NEWS
index 982ab440f6ba510355884676b88a7449749851b0..be3090b695c3a25bf508225c78e0218c3e25b273 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -1,5 +1,6 @@
 ncmpc 0.26 - not yet released
 * adapt to lirc 0.9.4
+* lyricswiki: update regex
 
 ncmpc 0.25 - (2016-08-18)
 * implement "%disc%"
index dbb50a3fb6638ec8c1a2d1a9ff5080a8b28779dd..06681a01b6902843f6ed10ed55bdf0a887fc648a 100755 (executable)
@@ -44,7 +44,7 @@ url = $1
 exit(69) if url =~ /action=edit$/
 
 response = open(URI.parse(url)).read
-if not response =~ /<div class='lyricbox'>\s*(.*?)\s*<!--/im
+if not response =~ /<div class='lyricbox'>\s*(.*?)\s*<div class='lyricsbreak'>/im
        $stderr.puts "No <div class='lyricbox'> in lyrics page!\n"
        exit(1)
 end