Clearly I haven’t blogged for a while – this was evident by the fact I had a wordpress upgrade waiting to be done, and no less than 8 plugin upgrades!

Now normally, I don’t mind being all long winded about plugin upgrades, because it’s usually just one or 2. Now because I’m picky and awkward, the WP auto-upgrade for plugins doesn’t seem to work on my server. Instead of fixing that, I simply wrote a bash script. The contents of which are:

  1. #!/bin/bash
  2.  
  3. if [ $# == 2 ]; then
  4.                 new=$2
  5. else
  6.                 new=$1
  7. fi
  8.  
  9. if [ -d $1 ]; then
  10.                 rm -rf ./$1
  11. fi
  12.  
  13. wget http://downloads.wordpress.org/plugin/$new.zip
  14. unzip ./*.zip
  15. rm ./*.zip

Not sure if anybody wants to use that – I’m sure it could be improved, but it satisfied 2 of my needs. I now have an easier way to update (and install, I guess) plugins, and a lesser desire to code things. I now have to think of my next blog topic so I can get back on track!

Sorry, the comment form is closed at this time.

   
© 2012 Joe Blog's Suffusion theme by Sayontan Sinha