wordpress/strip.sh
2018-01-17 10:07:14 +01:00

33 lines
509 B
Bash
Executable file

#!/bin/sh
if [ -z "$1" ]; then
echo usage $0 version
exit 1
fi
srce=wordpress-$1.tar.gz
dest=wordpress-$1-strip.tar.xz
if [ ! -f $srce ]; then
echo Download...
wget http://wordpress.org/$srce || exit 1
fi
if [ ! -f $dest ]; then
echo Cleanup...
[ -d wordpress ] && rm -r wordpress
echo Unpack...
tar xf $srce
echo Strip non free file
rm wordpress/wp-includes/js/codemirror/jshint.js
echo Pack...
tar cJf $dest wordpress
echo Cleanup...
rm -r wordpress
echo Done.
fi