LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Programming (https://www.linuxquestions.org/questions/programming-9/)
-   -   Popular Plugins && SVN (https://www.linuxquestions.org/questions/programming-9/popular-plugins-and-and-svn-4175555559/)

metallica1973 10-07-2015 02:43 PM

Popular Plugins && SVN
 
Forgive me if this question is rather stupid but I am writing some code using Python for a project at work and was wondering if there was a way to download the entire "Popular" plugins directory in a single shot? I currently have to to look at 34 pages:

https://wordpress.org/plugins/browse/popular/
https://wordpress.org/plugins/browse/popular/2
...

and parse data that way but is really inefficient. I see that I can check stuff out via svn

https://wordpress.org/plugins/about/svn/

and I can see all the plugins as a whole via:

https://plugins.svn.wordpress.org/

But is there a better way that I can accomplish my goal?

Thank you in advance!

HMW 10-08-2015 08:43 AM

Hi there!

You don't really say what it is you want to do. But handling urls in Python is fairly straight forward with requests:
http://docs.python-requests.org/en/l...make-a-request

Best regards,
HMW

metallica1973 10-08-2015 09:02 AM

Thank you for the reply. I guess I should clarify what I am asking. I have already written my python code to scrape what I need from the plugins sites and works great but at my job they think that its inefficient to send many HTTP GET requests to the site and would prefer that I obtain all the plugin information another way, then simply searching through the results, parse the data that I need. So I can download all the plugins via SVN:

svn co https://plugins.svn.wordpress.org/

but I would prefer to just download plugins that are considered popular like what you see from the url:

https://wordpress.org/plugins/browse/popular/
etc...

Can I do an svn check of just the popular directory? Ex.

svn co https://popular.plugins.svn.wordpress.org

I know the about url doesnt exist but if it does what is it?

Thank you in advance!

grail 10-08-2015 09:21 AM

Could you not use the list option for svn? I am not overly familiar with the command but might be worth a look.

Habitual 10-08-2015 11:09 AM

If you could just parse the plugin names you are interested in, you could manipulate that into
Code:

svn co https://plugins.svn.wordpress.org/your-plugin-name my-local-dir
Have you read https://wordpress.org/plugins/about/svn/ ?

metallica1973 10-08-2015 12:11 PM

Many thank you's,

the list option is helpful which is essentially the same as clicking the url(grail) :) I didnt see any popular directory of the sort or maybe I missed it. Habitual suggestion is also helpful but ultimately after I did the math would require 1000(total popular plugins) svn co requests in the initial beginning and looking for diffs therefor-after which inst as efficient as just scraping the 34 popular plugin sites for this project. The holy grail of where the popular plugins reside would be best.


All times are GMT -5. The time now is 08:44 AM.