This kit registers AIGX as a language in github/linguist,
so .aigx files get a language label and proper syntax highlighting on GitHub (blobs, diffs, search).
This repo's .gitattributes already does:
*.aigx linguist-language=XML linguist-detectable=falseGitHub renders .aigx with XML highlighting today (AIGX is XML-style) and keeps it out of the
repository language bar. Any repo adopting AIGX can copy that one line. Remove it once AIGX lands in
Linguist proper.
Registering AIGX in Linguist gives it its own label, color, and grammar (tm_scope: source.aigx).
Heads-up on the bar: Linguist's policy is that a new language should be in use across a few hundred repositories before it's merged. Land adoption first; this kit makes the PR mechanical when you're ready.
Steps:
- Fork and clone
github-linguist/linguist. - Add the language — paste
languages.ymlintolib/linguist/languages.yml(alphabetical order). Replace the placeholderlanguage_idwith the value Linguist's tests tell you to use (bundle exec rake testreports collisions; ids are otherwise stable random integers). - Add the grammar — AIGX's canonical grammar lives at
editors/textmate/aigx.tmLanguage.jsonwithscopeName: source.aigx. Register it:(Linguist scans the repo for a grammar whose scope isscript/add-grammar https://github.com/Lolner95/AIGX
source.aigxand vendors it intovendor/grammars+grammars.yml.) - Add samples — copy
sample.aigx(and ideally one or two more real genome files, e.g. fromexamples/sourcing-app/.aigx/) intosamples/AIGX/. - Verify:
bundle exec rake test script/licensed # license metadata for the vendored grammar
- Open the PR against
github-linguist/linguistdescribing AIGX, linking the spec (https://github.com/Lolner95/AIGX/blob/main/standard/AIGX-1.1.md) and adoption.
AIGX is structured markup consumed as configuration/context (not a programming language and not prose),
so it is typed data — the same family as XML, YAML, and JSON — with XML editor modes for highlighting.