1
0
mirror of https://github.com/gorhill/uBlock.git synced 2024-11-09 20:32:39 +01:00
uBlock/tools/make-assets.sh

36 lines
1.0 KiB
Bash
Raw Normal View History

#!/usr/bin/env bash
#
# This script assumes a linux environment
DES=$1/assets
2016-04-03 23:45:02 +02:00
printf "*** Packaging assets in $DES... "
2016-04-03 20:25:56 +02:00
if [ -n "${TRAVIS_TAG}" ]; then
pushd .. > /dev/null
2018-01-09 23:57:40 +01:00
git clone --depth 1 https://github.com/uBlockOrigin/uAssets.git
popd > /dev/null
2016-04-03 20:25:56 +02:00
fi
rm -rf $DES
mkdir $DES
cp ./assets/assets.json $DES/
if [ -f ./tmp/requests.json.gz ]; then
gunzip -c ./tmp/requests.json.gz > $DES/requests.json
fi
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/
# Optional filter lists: do not include in package
rm $DES/ublock/annoyances.txt
2016-04-03 23:45:02 +02:00
echo "done."