krlvm / PowerTunnel-AdBlock

AdBlock plugin for PowerTunnel
GNU General Public License v3.0
20 stars 4 forks source link

Option for adding custom host file/link #2

Closed quyleanh closed 2 years ago

quyleanh commented 2 years ago

Currently there is only StevenBlack/hosts integrated. Is there any plan for option which user can add their custom block host file/link?

I'm using with PowerTunnel now and happy with this function.

Thank you for your consideration.

krlvm commented 2 years ago

Hello,

I'll happily add a new filter source if you have a link to a regularly updated raw file in a format similar to this: https://raw.githubusercontent.com/StevenBlack/hosts/master/hosts

I could use EasyList, but PowerTunnel does not have access to packets content, while EasyList is designed to be used in a browser.

Thank you!

UPD: Misread, you want to use your own local list, did you tried Firewall plugin?

quyleanh commented 2 years ago

No, you understand correctly.

I would like to add this host file from bigdargon/hostsVN project, which is updated regularly.

As instruction, we can use the following link: https://raw.githubusercontent.com/bigdargon/hostsVN/master/hosts

Thank you and look forward to your update.

Update: when I said add option for custom block host file/link, I mean the option within this app to add bigdargon/hostsVN link.

krlvm commented 2 years ago

Multi-mirror support is not ready yet, but I've made small changes to f5844cb34c85de86d4380bbba704b42620cfea44, to load filters also from the link above, does it work for you? AdBlock-vn.zip

quyleanh commented 2 years ago

Could you please check. There is error. I can't connect to internet if I enable this plugins. I have removed the old one and install one in your comment.

krlvm commented 2 years ago

This should be related to the changed format of the cache, please, install the new plugin again and set "Filters update period" in AdBlock settings to "On start", then start PowerTunnel. If it does work, you can change the option from "On start" to any value you want (I prefer 3 days).

quyleanh commented 2 years ago

Thank you. It works now. But the host file link is still StevenBlack/hosts. I will wait for fully implement.

krlvm commented 2 years ago

Make sure you've installed the version I sent, it loads hosts from both sources, just checked

quyleanh commented 2 years ago

Just checked and it does load from both source. Thank you very much.

krlvm commented 2 years ago

Hosts plugin supports it and ships with PowerTunnel for Android v2.4 and higher.