GoFuckYourself.com - Adult Webmaster Forum

GoFuckYourself.com - Adult Webmaster Forum (https://gfy.com/index.php)
-   Fucking Around & Business Discussion (https://gfy.com/forumdisplay.php?f=26)
-   -   Useful Blog Script I Made (https://gfy.com/showthread.php?t=792490)

minusonebit 12-15-2007 06:33 PM

Useful Blog Script I Made
 
I finally got tired of copying the update files of the All in One SEO Pack for Wordpress to each and every installation. So I made this little script to do it for me. Figured I'd share in case anyone else is tired of fucking with such things. You could customize this to roll out in mass any plugins really. You just have to setup your paths and make blocks for each site you want to update, then its as simple as uploading ONE copy and rolling it out.

Released without warranty or support of any kind... use at your own risk.

Code:

#!/usr/local/bin/bash

clear
echo " "
echo "Wordpress All in One SEO Pack Update Server-Wide Rollout Tool"
echo " "
echo "Copyleft 2007 by minusonebit. Only a couple of rights reserved. You may do what you want with this script - except sell it or remove this copyleft notice. If you remove this notice, you understand and agree that your ass belongs to me. Released without support or warranty of any kind. Use at your own risk."
echo " "
echo "This script updates The All in One SEO Pack on ALL wordpress installations on this server. To run, put the new version of all_in_one_seo_pack.php in '/path/to/source/file/' and let 'er rip!"
echo " "
echo "Strike ENTER to RUN, Ctrl-C to ABORT"; read
echo " "
echo "Updating Site 1..."
cp -f /path/to/source/file/all_in_one_seo_pack.php /usr/local/www/domains/domain1.com/htdocs/wp-content/plugins
chown www:www /usr/local/www/domains/domain1.com/htdocs/wp-content/plugins/all_in_one_seo_pack.php
echo "Updating Site 1... done."
echo "Updating Site 2..."
cp -f /path/to/source/file/all_in_one_seo_pack.php /usr/local/www/domains/domain2.com/htdocs/wp-content/plugins
chown www:www /usr/local/www/domains/domain2.com/htdocs/wp-content/plugins/all_in_one_seo_pack.php
echo "Updating Site 2... done."
echo " "
echo "Update Finished. Check for errors above."
echo " "
echo "Exiting the system, goodbye."
echo " "

Eventually, I am gonna write one of these to roll Wordpress updates themselves out. Have fun and remember, you can return the script above for the price you paid minus a 15% restocking fee. :)

GrouchyAdmin 12-15-2007 06:35 PM

A script to copy one file, twice.

God damn you're a bourne demon.

minusonebit 12-15-2007 06:37 PM

Quote:

Originally Posted by GrouchyAdmin (Post 13520184)
A script to copy one file, twice.

God damn you're a bourne demon.

Well, I have like 40 blogs on the server. No point in putting 40 lines in the example. It does save time. I am sure you have something better that you use. So post it and maybe I'll use yours. Otherwise, be quiet. :upsidedow

st0ned 12-15-2007 07:07 PM

Does it steal my epassporte password so that you can post it on your blog? :mad:

GrouchyAdmin 12-15-2007 07:16 PM

Yes, a handful of copy/chown statements makes much more sense than

for n in domain1.com domain2.com domain3.com; do cp file /path/to/$n/htdocs/lolwp/i/steal/passwords/; chown www:www $!/file chmod 664 $!; done

But you should add a few more echo statements and maybe a 'read y' so people can hit enter just to see your badass script give credit before doing it's thing.

teg0 12-15-2007 08:01 PM

nice script. i can see some adjustments that need to be made and some improvements. I might build upon it and post my revisions here.

TTiger 12-15-2007 08:06 PM

i like blog script:-)


All times are GMT -7. The time now is 05:04 PM.

Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2026, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc123