Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Language: Hosts #6389

Closed
DandelionSprout opened this issue Apr 25, 2023 · 1 comment · Fixed by #6391
Closed

Add Language: Hosts #6389

DandelionSprout opened this issue Apr 25, 2023 · 1 comment · Fixed by #6391
Labels
Add Language Good First Issue This is a great opportunity to start contributing to Linguist

Comments

@DandelionSprout
Copy link
Contributor

Language name

Hosts, alternately Hosts file.

URL of example repository

https://github.com/StevenBlack/hosts

URL of syntax highlighting grammar

https://marketplace.visualstudio.com/items?itemName=tommasov.hosts

Most popular extensions

A large supermajority seem to use .txt suffixes. Some uncommon cases use no suffixes at all, primarily lists with long history that were meant to overwrite operating systems' /etc/hosts files.

Detected language

Currently none.

Submitter's notes

In relation to the previously approved and implemented "Adblock Filter Syntax" language, I talked a bit with that syntax's main owners at AdguardTeam/VscodeAdblockSyntax#70, who from what I understood recommended to me https://marketplace.visualstudio.com/items?itemName=tommasov.hosts as the recommended method to add colors to Hosts lists/entries.

"Hosts" files' history stretch back to the late 1980's, and have been used for adblocking since the mid-to-late 1990's ("Peter Lowe's List", "Dan Pollock's Hosts"). It is occasionally used to this day by various tools (uBlock Origin, AdGuard Home, Pi-hole, various smaller tools), although it has never been fully implemented in AdGuard Browser Extension or Adblock Plus.

As with "Adblock Filter Syntax", implementation in GitHub Linguist would rely largely on repos' .gitattritubes specifying filetypes and linguist-detectable. I estimate a low-5-digit amount of GitHub repos using Hosts syntax, some with ≥1,000 stars.

@DandelionSprout DandelionSprout added Add Language Good First Issue This is a great opportunity to start contributing to Linguist labels Apr 25, 2023
@Alhadis
Copy link
Collaborator

Alhadis commented Apr 25, 2023

I forgot I started work on this a while ago (on a branch I never pushed to GitHub). I've remedied that in #6391 (which is still a WIP at this stage, although input's nonetheless welcome).

@github-linguist github-linguist locked as resolved and limited conversation to collaborators Jun 17, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Add Language Good First Issue This is a great opportunity to start contributing to Linguist
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants