Comments (3)
Hi @mehedeetalha!
I'm not sure what you mean. Whenever you execute adblock
, it will check for updates in the blocklist and update it if necessary. If you start seeing ads again, just run sudo adblock
; if after that you still see ads, identify the domain that serves them and send a request to Dan Pollock at [email protected] 🙂
Please let me know if that answers your need.
from adblock.
Can we add multiple ads list host like GoodByeAds, AdAway, etc ?
I did this I do not know if it is the correct approach cuz I don't know how to do loop in bash
block() {
local tmpfile="$DOWNLOADED.part"
#Mash
local tmpfile1="$DOWNLOADED.part"
local tmpfile2="$DOWNLOADED.part"
local tmpfile3="$DOWNLOADED.part"
local tmpfile4="$DOWNLOADED.part"
local tmpfile5="$DOWNLOADED.part"
local tmpfile6="$DOWNLOADED.part"
local tmpfile7="$DOWNLOADED.part"
local tmpfile8="$DOWNLOADED.part"
#./Mash
sudo curl $SOURCE --show-error -\# --output "$tmpfile" && # -# is "show progress as a bar instead of full metrics"
sudo rm -f "$DOWNLOADED" && # -f allows to be silent if the file does not exist
sudo mv "$tmpfile" "$DOWNLOADED" &&
sudo cat "$ORIGINAL" | sudo tee "$TARGET" > /dev/null &&
sudo cat "$DOWNLOADED" | sudo tee -a "$TARGET" > /dev/null && # append to file rather than overwrite it
sleep 3
#Mash
sudo curl 'https://raw.githubusercontent.com/Zalexanninev15/NoADS_RU/main/ads_list_extended.txt' --show-error -\# --output "$tmpfile1" && # -# is "show progress as a bar instead of full metrics"
#sudo rm -f "$DOWNLOADED" && # -f allows to be silent if the file does not exist
sudo mv "$tmpfile1" "$DOWNLOADED" &&
#sudo cat "$ORIGINAL" | sudo tee "$TARGET" > /dev/null &&
sudo cat "$DOWNLOADED" | sudo tee -a "$TARGET" > /dev/null && # append to file rather than overwrite it
#./Mash
sleep 3
#Mash
sudo curl 'https://raw.githubusercontent.com/jerryn70/GoodbyeAds/master/Hosts/GoodbyeAds.txt' --show-error -\# --output "$tmpfile2" && # -# is "show progress as a bar instead of full metrics"
#sudo rm -f "$DOWNLOADED" && # -f allows to be silent if the file does not exist
sudo mv "$tmpfile2" "$DOWNLOADED" &&
#sudo cat "$ORIGINAL" | sudo tee "$TARGET" > /dev/null &&
sudo cat "$DOWNLOADED" | sudo tee -a "$TARGET" > /dev/null && # append to file rather than overwrite it
#./Mash
sleep 3
#Mash
sudo curl 'https://raw.githubusercontent.com/StevenBlack/hosts/master/alternates/fakenews-gambling/hosts' --show-error -\# --output "$tmpfile3" && # -# is "show progress as a bar instead of full metrics"
#sudo rm -f "$DOWNLOADED" && # -f allows to be silent if the file does not exist
sudo mv "$tmpfile3" "$DOWNLOADED" &&
#sudo cat "$ORIGINAL" | sudo tee "$TARGET" > /dev/null &&
sudo cat "$DOWNLOADED" | sudo tee -a "$TARGET" > /dev/null && # append to file rather than overwrite it
#./Mash
sleep 3
#Mash
sudo curl 'https://pgl.yoyo.org/adservers/serverlist.php?showintro=0;hostformat=hosts' --show-error -\# --output "$tmpfile4" && # -# is "show progress as a bar instead of full metrics"
#sudo rm -f "$DOWNLOADED" && # -f allows to be silent if the file does not exist
sudo mv "$tmpfile4" "$DOWNLOADED" &&
#sudo cat "$ORIGINAL" | sudo tee "$TARGET" > /dev/null &&
sudo cat "$DOWNLOADED" | sudo tee -a "$TARGET" > /dev/null && # append to file rather than overwrite it
#./Mash
sleep 3
#Mash
sudo curl 'https://adaway.org/hosts.txt' --show-error -\# --output "$tmpfile5" && # -# is "show progress as a bar instead of full metrics"
#sudo rm -f "$DOWNLOADED" && # -f allows to be silent if the file does not exist
sudo mv "$tmpfile5" "$DOWNLOADED" &&
#sudo cat "$ORIGINAL" | sudo tee "$TARGET" > /dev/null &&
sudo cat "$DOWNLOADED" | sudo tee -a "$TARGET" > /dev/null && # append to file rather than overwrite it
#./Mash
echo 'Hosts file updated'
}
from adblock.
This issue should have been closed.
The comment above is a separate topic that should be open in its own, separate issue. Quick reply to @kuwaitbinary: no, at this stage this script does not support multiple sources. In my experience, the accuracy in blocking of the current file is completely satisfactory. I am thus not certain what would be the gain in adding more lists.
If you find that the results are unsatisfactory, please open another issue providing a few examples of domains that are not blocked with the current source and that would be blocked properly by including other sources 🙂
from adblock.
Related Issues (11)
- Support Debian
- Explain actions that will be done before calling `sudo` HOT 1
- Consider using dnsmasq HOT 1
- Support Windows HOT 1
- Mention complementary browser blocking HOT 4
- Add the ability to install it via homebrew HOT 8
- Add options to activate some commented entries from hosts zero HOT 1
- Merge hosts from other lists? HOT 4
- Retire software? HOT 3
- Support customized list? HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from adblock.