From c69ad5d243f73247094df74dc58a148fdb3ac1f0 Mon Sep 17 00:00:00 2001 From: Fabrice Laporte Date: Wed, 19 Nov 2014 23:33:06 +0100 Subject: [PATCH] print google sources url when releasing a beets version, run the script before running test_lyrics.py, and copy/paste the sources listed on stdout as a bulk add on Google CSE so beets engine is up-to-date. --- test/lyrics_download_samples.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/lyrics_download_samples.py b/test/lyrics_download_samples.py index 80e18fbfa..754d2a2b5 100644 --- a/test/lyrics_download_samples.py +++ b/test/lyrics_download_samples.py @@ -43,12 +43,12 @@ def main(argv=None): argv = sys.argv for s in test_lyrics.GOOGLE_SOURCES + test_lyrics.DEFAULT_SOURCES: + print 'Fetching sample from %s' % s['url'] url = s['url'] + s['path'] fn = test_lyrics.url_to_filename(url) if not os.path.isfile(fn): html = requests.get(url).text with safe_open_w(fn) as f: - print 'Writing %s' % fn f.write(html.encode('utf8')) if __name__ == "__main__":