[wp-hackers] Getting list of plugins from shell script

Scot Hacker shacker at birdhouse.org
Tue Aug 3 18:05:03 UTC 2010


On Aug 3, 2010, at 5:00 AM, wp-hackers-request at lists.automattic.com  
wrote:

> Message: 3
> Date: Tue, 3 Aug 2010 04:38:14 -0400
> From: Mike Schinkel <mikeschinkel at newclarity.net>
>
> Scot:
>
> Why don't you call a PHP script from the shell?  Problem is that  
> option is serialized and you'll find it easiest to get PHP to  
> unserialize it for you.
>
> Here's a shell script that will do for you:  http://gist.github.com/506055
>

Nice! I know I said in my OP that I was looking for a shell, not a PHP  
solution. Thanks Harish Narayan and Mike for the shell solutions they  
sent off-list -- really creative (if somewhat hairy). But the fact  
that this data is serialized in a single field, and being able to use  
PHP's unserialize() function to get at it, makes for a much cleaner  
solution. So I'm doing that - popping out to a copy of the script above.

Thanks all,
Scot




More information about the wp-hackers mailing list