Carried over from https://github.com/DandelionSprout/adfilt/issues/7#issuecomment-488537971, due to a lack of response from its posters:
I’m to some degree looking for a way to create a script akin to ones that combine different entry categories together into one, like what Frellwit and EasyList are using. That way I could’ve accomplished some things that I can’t do today (unless I had put twice as much workhours into my lists), such as creating list versions that are more suitable for non-uBO adblockers, and including the contents of someone else’s list into any of my lists.
My knowledge of coding languages in general remains questionable, but here’s a mockup of something that’d take the uBO-tailored main version of Dandelion Sprout’s Nordic Filters, and in order create an AdGuard version, an ABP/AdBlock version, and an EasyList-criteria-following ABP-only version:
# Use the uBO Nordic list as the source fetch https://raw.githubusercontent.com/DandelionSprout/adfilt/master/NorwegianList.txt fetch https://raw.githubusercontent.com/DandelionSprout/adfilt/master/uBO%20list%20extensions/NordicExtensionsForUBO%26Nano.txt # Remove $document-related text from entries, as only Nano and uBO supports it replace /\$document/.* with /\$important # Output a version for AdGuard whose sole change is that $document entries have been replaced with $important output https://github.com/DandelionSprout/adfilt/tree/master/NorwegianExperimentalList%20alternate%20versions/NordicFilters-AdGuard.txt # Then take the AdGuard version, and remove entries that are not supported by ABP or AdBlock remove text ",important" remove text "$important" remove text ",redirect=noopjs" exclude entries with ":style|##+js|.*#|:xpath|:matches-css|:matches-css-before" output > https://github.com/DandelionSprout/adfilt/tree/master/NorwegianExperimentalList%20alternate%20versions/NordicFilters-ABPAdBlock.txt # Creating a version solely for ABP, that intends to meet ABP's list inclusion requirements. abp_base='paragraph does not contain "Leftover empty spaces"|paragraph does not contain "Empty divider spaces"|paragraph does not contain "Distracting background"|paragraph does not contain "De-blurrers"|paragraph does not contain "anti-anti-adblocking"' output abp_base > https://github.com/DandelionSprout/adfilt/tree/master/NorwegianExperimentalList%20alternate%20versions/NordicFilters-ABPBaseVersion.txt
How would I have had to rewrite such a script to make it runnable, which file format would be the best to use, and how could I make it autorun from GitHub’s GUI (or alternately from one-ish desktop script)?
Should this turn out to be a success, I have similar ideas in mind for at least 10 of my 54 other lists.