mirror of
https://github.com/gorhill/uMatrix.git
synced 2024-06-24 17:10:24 +12:00
tools to update assets
This commit is contained in:
parent
4eff02241f
commit
94321937ab
13
tools/commit-assets.sh
Executable file
13
tools/commit-assets.sh
Executable file
|
@ -0,0 +1,13 @@
|
||||||
|
#!/bin/bash
|
||||||
|
#
|
||||||
|
# This script assumes a linux environment
|
||||||
|
|
||||||
|
echo "*** µMatrix: git adding changed assets..."
|
||||||
|
git add --update --ignore-removal --ignore-errors assets
|
||||||
|
echo "*** µMatrix: git committing assets..."
|
||||||
|
git commit -m 'update of third-party assets'
|
||||||
|
echo "*** µMatrix: git pushing assets to remote master..."
|
||||||
|
git push origin master
|
||||||
|
|
||||||
|
echo "*** µMatrix: git done."
|
||||||
|
|
|
@ -7,5 +7,6 @@ echo "*** µMatrix(Chromium): Copying files"
|
||||||
mkdir -p ./dist/chromium
|
mkdir -p ./dist/chromium
|
||||||
cp -R ./src/* ./dist/chromium/
|
cp -R ./src/* ./dist/chromium/
|
||||||
cp -R ./tools/_locales ./dist/chromium/
|
cp -R ./tools/_locales ./dist/chromium/
|
||||||
|
cp -R ./assets ./dist/chromium/
|
||||||
cp ./meta/chromium/* ./dist/chromium/
|
cp ./meta/chromium/* ./dist/chromium/
|
||||||
echo "*** µMatrix(Chromium): Package done."
|
echo "*** µMatrix(Chromium): Package done."
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
|
|
||||||
TEMPFILE=/tmp/umatrix-asset
|
TEMPFILE=/tmp/umatrix-asset
|
||||||
|
|
||||||
echo "*** HTTP Switchboard: updating remote assets..."
|
echo "*** µMatrix: updating remote assets..."
|
||||||
|
|
||||||
THIRDPARTY_REMOTEURLS=(
|
THIRDPARTY_REMOTEURLS=(
|
||||||
'http://mirror1.malwaredomains.com/files/immortal_domains.txt'
|
'http://mirror1.malwaredomains.com/files/immortal_domains.txt'
|
||||||
|
@ -18,14 +18,14 @@ THIRDPARTY_REMOTEURLS=(
|
||||||
)
|
)
|
||||||
|
|
||||||
THIRDPARTY_LOCALURLS=(
|
THIRDPARTY_LOCALURLS=(
|
||||||
'thirdparties/mirror1.malwaredomains.com/files/immortal_domains.txt'
|
'assets/thirdparties/mirror1.malwaredomains.com/files/immortal_domains.txt'
|
||||||
'thirdparties/mirror1.malwaredomains.com/files/justdomains'
|
'assets/thirdparties/mirror1.malwaredomains.com/files/justdomains'
|
||||||
'thirdparties/pgl.yoyo.org/as/serverlist'
|
'assets/thirdparties/pgl.yoyo.org/as/serverlist'
|
||||||
'thirdparties/www.malwaredomainlist.com/hostslist/hosts.txt'
|
'assets/thirdparties/www.malwaredomainlist.com/hostslist/hosts.txt'
|
||||||
'thirdparties/hosts-file.net/ad-servers'
|
'assets/thirdparties/hosts-file.net/ad-servers'
|
||||||
'thirdparties/someonewhocares.org/hosts/hosts'
|
'assets/thirdparties/someonewhocares.org/hosts/hosts'
|
||||||
'thirdparties/winhelp2002.mvps.org/hosts.txt'
|
'assets/thirdparties/winhelp2002.mvps.org/hosts.txt'
|
||||||
'thirdparties/publicsuffix.org/list/effective_tld_names.dat'
|
'assets/thirdparties/publicsuffix.org/list/effective_tld_names.dat'
|
||||||
)
|
)
|
||||||
|
|
||||||
ENTRY_INDEX=0
|
ENTRY_INDEX=0
|
||||||
|
|
|
@ -2,14 +2,12 @@
|
||||||
#
|
#
|
||||||
# This script assumes a linux environment
|
# This script assumes a linux environment
|
||||||
|
|
||||||
echo "*** HTTP Switchboard: generating checksums.txt file..."
|
echo "*** µMatrix: generating checksums.txt file..."
|
||||||
pushd ..
|
|
||||||
truncate -s 0 assets/checksums.txt
|
truncate -s 0 assets/checksums.txt
|
||||||
LIST="$(find assets/httpsb assets/thirdparties -type f)"
|
LIST="$(find assets/umatrix assets/thirdparties -type f)"
|
||||||
for ENTRY in $LIST; do
|
for ENTRY in $LIST; do
|
||||||
echo `md5sum $ENTRY` >> assets/checksums.txt
|
echo `md5sum $ENTRY` >> assets/checksums.txt
|
||||||
done
|
done
|
||||||
popd
|
|
||||||
|
|
||||||
echo "*** HTTP Switchboard: checksums updated."
|
echo "*** µMatrix: checksums updated."
|
||||||
|
|
||||||
|
|
|
@ -1,13 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
#
|
|
||||||
# This script assumes a linux environment
|
|
||||||
|
|
||||||
echo "*** HTTP Switchboard: git adding changed assets..."
|
|
||||||
git add --update --ignore-removal --ignore-errors ./*
|
|
||||||
echo "*** HTTP Switchboard: git committing assets..."
|
|
||||||
git commit -m 'update of third-party assets'
|
|
||||||
echo "*** HTTP Switchboard: git pushing assets to remote master..."
|
|
||||||
git push origin master
|
|
||||||
|
|
||||||
echo "*** HTTP Switchboard: git done."
|
|
||||||
|
|
Loading…
Reference in a new issue