User Tools

Site Tools


programming:python:albumcoverdl

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
programming:python:albumcoverdl [2010/05/11 17:36] crustymonkeyprogramming:python:albumcoverdl [2010/05/11 20:59] (current) crustymonkey
Line 6: Line 6:
 ===== Requirements ===== ===== Requirements =====
 The only requirement to run this script is that you download and install the [[http://pypi.python.org/pypi/python-amazon-product-api/0.2.1|Python Amazon product api]].  That, in turn, requires the [[http://pypi.python.org/pypi/lxml/|Python lxml library]].  If you use the ''easy_install'' method (or have that installed) when you install the amazon product api, it will automatically pull in the ''lxml'' library for you. The only requirement to run this script is that you download and install the [[http://pypi.python.org/pypi/python-amazon-product-api/0.2.1|Python Amazon product api]].  That, in turn, requires the [[http://pypi.python.org/pypi/lxml/|Python lxml library]].  If you use the ''easy_install'' method (or have that installed) when you install the amazon product api, it will automatically pull in the ''lxml'' library for you.
- 
 ===== The Script ===== ===== The Script =====
 The script itself is actually quite simple since all the heavy lifting is done by the Amazon product api library.  Make sure you change the **API_KEY**, and **SECRET_KEY** to whatever your key values are that you obtained from Amazon.  If you do not have a key pair, you can get them for free [[https://www.amazon.com/ap/signin?openid.ns=http://specs.openid.net/auth/2.0&authCookies=1&openid.mode=checkid_setup&openid.identity=http://specs.openid.net/auth/2.0/identifier_select&openid.claimed_id=http://specs.openid.net/auth/2.0/identifier_select&openid.pape.max_auth_age=600&openid.return_to=https://www.amazon.com/gp/aws/ssop/handlers/auth-portal.html%3Fie%3DUTF8%26wreply%3Dhttps%253A%252F%252Faws-portal.amazon.com%252Fgp%252Faws%252Fdeveloper%252Fregistration%252Findex.html%26awsrequestchallenge%3Dfalse%26wtrealm%3Durn%253Aaws%253AawsAccessKeyId%253A1QQFCEAYKJXP0J7S2T02%26wctx%3D%26awsaccountstatuspolicy%3DP1%26wa%3Dwsignin1.0%26awsrequesttfa%3Dtrue&openid.assoc_handle=ssop&openid.pape.preferred_auth_policies=http://schemas.openid.net/pape/policies/2007/06/multi-factor-physical&openid.ns.pape=http://specs.openid.net/extensions/pape/1.0&accountStatusPolicy=P1&siteState=awsMode::signUp::&|here]].  You will also want to set your own **BASEDIRS** to the directories where you have your music.  Once you have that all done, just run the script: ''python getcovers.py'' The script itself is actually quite simple since all the heavy lifting is done by the Amazon product api library.  Make sure you change the **API_KEY**, and **SECRET_KEY** to whatever your key values are that you obtained from Amazon.  If you do not have a key pair, you can get them for free [[https://www.amazon.com/ap/signin?openid.ns=http://specs.openid.net/auth/2.0&authCookies=1&openid.mode=checkid_setup&openid.identity=http://specs.openid.net/auth/2.0/identifier_select&openid.claimed_id=http://specs.openid.net/auth/2.0/identifier_select&openid.pape.max_auth_age=600&openid.return_to=https://www.amazon.com/gp/aws/ssop/handlers/auth-portal.html%3Fie%3DUTF8%26wreply%3Dhttps%253A%252F%252Faws-portal.amazon.com%252Fgp%252Faws%252Fdeveloper%252Fregistration%252Findex.html%26awsrequestchallenge%3Dfalse%26wtrealm%3Durn%253Aaws%253AawsAccessKeyId%253A1QQFCEAYKJXP0J7S2T02%26wctx%3D%26awsaccountstatuspolicy%3DP1%26wa%3Dwsignin1.0%26awsrequesttfa%3Dtrue&openid.assoc_handle=ssop&openid.pape.preferred_auth_policies=http://schemas.openid.net/pape/policies/2007/06/multi-factor-physical&openid.ns.pape=http://specs.openid.net/extensions/pape/1.0&accountStatusPolicy=P1&siteState=awsMode::signUp::&|here]].  You will also want to set your own **BASEDIRS** to the directories where you have your music.  Once you have that all done, just run the script: ''python getcovers.py''
Line 77: Line 76:
 </code> </code>
  
-This is a bit of a quick and dirty 10 minute script.  I will probably add some command-line opts later when I have time, but for now it functions well.+You can also download this script {{:programming:python:getcovers.py.gz|here}}.  This is a bit of a quick and dirty 10 minute script.  I will probably add some command-line opts later when I have time, but for now it functions well.
  
 ===== Problems ===== ===== Problems =====
 If you run into any problems, or you have any questions, please email me at admin@splitstreams.com If you run into any problems, or you have any questions, please email me at admin@splitstreams.com
- 
programming/python/albumcoverdl.txt · Last modified: 2010/05/11 20:59 by crustymonkey