brave / brave/adblock-rust

Support pre-processing directives and add env_brave

Open
#234 1 comment 2 reactions 0 assignees View on GitHub
Dominant language
Rust
Stars
2.8k
Forks
250
Avg merge
1d 16h
Merged PRs (30d)
6

Description

I don't know if pre-processing directives are supported or not, https://github.com/brave-experiments/ad-block/issues/114 is archived without any notion. In particular, [if-condition](https://github.com/gorhill/uBlock/wiki/Static-filter-syntax#if-condition) to speficy Brave Shield (`env_brave` or something) will be useful to list maintainer. Sure, Brave has its own unbreak list, but if a Brave-specific issue like https://github.com/brave/adblock-lists/issues/614 can be fixed in upstream lists by specifying Brave, this will save time of both Brave list maintainer (@ryanbr ) and me (or whoever filter author who mind Brave). Moreover, it will encourage more people to create and maintain lists for Brave. I believe if you can implement this, Adguard (@ameshkov) and uBlock Origin (@gorhill ) can add the same directive whose value will be `false` on them (this is completely different from https://github.com/uBlockOrigin/uBlock-issues/issues/1213).

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reading the linked uBlock Origin static-filter syntax documentation and the archived Brave issue to establish how preprocessing directives are expected to work. Define what support for the if-condition and an env_brave value should mean, then verify that Brave-specific filtering can be expressed upstream without affecting other engines.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
backend
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.