How v2fly/domain-list-community works
Domain List Community curates named domain-rule lists and builds them into geosite data for Project V routing. The primary workflow is to read files under data, parse rules and inclusions/affiliations, resolve and normalize lists, then export plain lists and a protobuf .dat file. A separate datdump command reads that .dat format and exports YAML. The README documents these capabilities; excerpts show parts of parsing, resolution, and output assembly, but omit portions of the main orchestration, so some links rely on README evidence.
Main entry points: main.go Rule parser · data Source lists · datdump/main.go Dat YAML exporter · README.md Rule syntax
Components 16
Domain catalog
- Source lists
data - Rule syntax
README.md
List processing
- Rule parser
main.go - Inclusion resolver
main.go - Affiliation handling
main.go - Deduplicate and sort
main.go - Rule constants
internal/dlc/dlc.go
Exports and routing
- Plain list export
main.go - GeoSite encoder
main.go - Dat task assembly
main.go - Geosite dat
- Plain list files
- Dat YAML exporter
cmd/datdump/main.go - YAML exports
Other components
- List maintainer
- Project V routing
Connections 17
- List maintainer → Source lists: edits lists
README.md - Source lists → Rule parser: parsed by
README.md - Rule syntax → Rule parser: defines rules
README.md - Rule parser → Rule constants: uses rule types
main.go - Rule parser → Inclusion resolver: collects inclusions
main.go - Rule parser → Affiliation handling: collects affiliations
README.md - Inclusion resolver → Deduplicate and sort: resolves then normalizes
main.go - Affiliation handling → Deduplicate and sort: contributes rules
README.md - Rule parser → Deduplicate and sort: deduplicates and sorts
README.md - Deduplicate and sort → Plain list export: exports lists
main.go - Deduplicate and sort → GeoSite encoder: encodes rules
README.md - GeoSite encoder → Dat task assembly: assembles sites
main.go - Dat task assembly → Geosite dat: writes dat
main.go - Plain list export → Plain list files: writes lists
main.go - Geosite dat → Dat YAML exporter: loaded and decoded
cmd/datdump/main.go - Dat YAML exporter → YAML exports: exports YAML
cmd/datdump/main.go - Geosite dat → Project V routing: supplies routing rules
README.md