Take a list like the one you mentioned in your first post. Say it has the domain in it:
Pi-hole will ingest that into Gravity and that entry will block the exact domain
example.com. Using this new feature Pi-hole would also write that to a new list in ABP format as:
and this list could be used by an ABP installation. But that new entry doesn't mean the same thing. That new entry will block
example.com and all subdomains of
example.com, which is not what the original list intended.
So maybe instead, Pi-hole writes it to an ABP list as:
But that new entry only blocks that root domain, not paths following that domain, so is largely useless for blocking in web browsing.
In otherwords, Pi-hole inteprets ABP entries of that first form as wildcard domains to block. But taking an exact domain from a hosts list and writing that back out as an ABP entry means Pi-hole has to make a decision as to what you want that exact domain entry to represent in your ABP list.
Is it a wildcard domain, which will catch all subdomains, which is not what the original exact domain entry was for, or is it an exact address entry which is largely usless for web usage, which is where ABP is going to be running? Or is it some other syntax supported by ABP?
That's what I meant about second-guessing – at the DNS level the exact domain entry simply means "make this domain unavailable at the network level". Pi-hole doesn't care about access protocols like HTTP or URL pathnames. But ABP does care about those things, hence the richer syntax in ABP lists. There may be an ABP syntax which results in the same effect in the browser as if the whole domain, but not subdomains, were blocked.
If you do want to do this, a bash script can be written which will read each host list. For each line which is a domain, it is written to a new file with the required syntax added around it to make it into the kind of ABP operation you're looking for. This could be automated and run using
cron, with the resulting lists pushed somewhere like Dropbox or a private web page for your family and business users to add to their ABP lists. Pi-hole updates the lists every weekend so running this on Sunday evening would have it ready for the coming working week.
What else would it be running against anyway other than a hosts file? If it's an ABP file then use it directly in ABP as is.