2016-04-03 11:07:46 -06:00
|
|
|
#!/usr/bin/env bash
|
|
|
|
#
|
|
|
|
# This script assumes a linux environment
|
|
|
|
|
|
|
|
DES=$1/assets
|
|
|
|
|
2016-04-03 15:45:02 -06:00
|
|
|
printf "*** Packaging assets in $DES... "
|
2016-04-03 11:07:46 -06:00
|
|
|
|
2016-04-03 12:25:56 -06:00
|
|
|
if [ -n "${TRAVIS_TAG}" ]; then
|
2016-04-03 16:06:19 -06:00
|
|
|
pushd .. > /dev/null
|
2018-01-09 15:57:40 -07:00
|
|
|
git clone --depth 1 https://github.com/uBlockOrigin/uAssets.git
|
2016-04-03 16:06:19 -06:00
|
|
|
popd > /dev/null
|
2016-04-03 12:25:56 -06:00
|
|
|
fi
|
|
|
|
|
2016-04-03 11:07:46 -06:00
|
|
|
rm -rf $DES
|
|
|
|
mkdir $DES
|
2017-01-18 11:36:24 -07:00
|
|
|
cp ./assets/assets.json $DES/
|
2016-04-03 11:07:46 -06:00
|
|
|
|
|
|
|
mkdir $DES/thirdparties
|
|
|
|
cp -R ../uAssets/thirdparties/easylist-downloads.adblockplus.org $DES/thirdparties/
|
|
|
|
cp -R ../uAssets/thirdparties/mirror1.malwaredomains.com $DES/thirdparties/
|
|
|
|
cp -R ../uAssets/thirdparties/pgl.yoyo.org $DES/thirdparties/
|
|
|
|
cp -R ../uAssets/thirdparties/publicsuffix.org $DES/thirdparties/
|
|
|
|
cp -R ../uAssets/thirdparties/www.malwaredomainlist.com $DES/thirdparties/
|
|
|
|
|
|
|
|
mkdir $DES/ublock
|
|
|
|
cp -R ../uAssets/filters/* $DES/ublock/
|
2017-12-17 07:42:24 -07:00
|
|
|
# Optional filter lists: do not include in package
|
|
|
|
rm $DES/ublock/annoyances.txt
|
2016-04-03 11:07:46 -06:00
|
|
|
|
2016-04-03 15:45:02 -06:00
|
|
|
echo "done."
|