mirror of
https://github.com/SukkaW/Surge.git
synced 2026-01-29 01:51:52 +08:00
Manually adding Bright Data domains
This commit is contained in:
17
Build/_get-lum-apex-domains.ts
Normal file
17
Build/_get-lum-apex-domains.ts
Normal file
@@ -0,0 +1,17 @@
|
||||
import { fetchRemoteTextByLine } from './lib/fetch-text-by-line';
|
||||
import tldts from 'tldts';
|
||||
|
||||
(async () => {
|
||||
const lines = await Array.fromAsync(await fetchRemoteTextByLine('https://raw.githubusercontent.com/durablenapkin/block/master/luminati.txt', true));
|
||||
|
||||
const set = new Set<string>();
|
||||
|
||||
lines.forEach((line) => {
|
||||
const apexDomain = tldts.getDomain(line.slice(8));
|
||||
if (apexDomain) {
|
||||
set.add(apexDomain);
|
||||
}
|
||||
});
|
||||
|
||||
console.log(Array.from(set).map(line => '.' + line).join('\n'));
|
||||
})();
|
||||
@@ -9,7 +9,6 @@ export const HOSTS: HostsSource[] = [
|
||||
['https://raw.githubusercontent.com/crazy-max/WindowsSpyBlocker/master/data/hosts/spy.txt', null, true, TTL.TWO_WEEKS()],
|
||||
['https://raw.githubusercontent.com/jerryn70/GoodbyeAds/master/Extension/GoodbyeAds-Xiaomi-Extension.txt', null, false, TTL.ONE_WEEK()],
|
||||
['https://raw.githubusercontent.com/jerryn70/GoodbyeAds/master/Extension/GoodbyeAds-Huawei-AdBlock.txt', null, false, TTL.ONE_WEEK()],
|
||||
['https://raw.githubusercontent.com/durablenapkin/block/master/luminati.txt', null, true, TTL.THREE_HOURS()],
|
||||
['https://raw.githubusercontent.com/durablenapkin/block/master/tvstream.txt', null, true, TTL.THREE_HOURS()]
|
||||
];
|
||||
|
||||
|
||||
Reference in New Issue
Block a user