Add cmd/datdump/main.go (#3213)

* Feat: add a new datdump tool

* Refactor: address code review comments

* Refactor: remove export all from main program

use datdump instead

* Refactor: allow spaces in exportlists

e.g. `--exportlists="lista, listb"`

* all: cleanup

* apply review suggestion

---------

Co-authored-by: database64128 <free122448@hotmail.com>
This commit is contained in:
MkQtS
2026-01-24 23:11:35 +08:00
committed by GitHub
parent 8e62b9b541
commit 5c38f34456
5 changed files with 303 additions and 116 deletions

View File

@@ -36,7 +36,8 @@ jobs:
- name: Build dlc.dat and plain lists
run: |
cd code || exit 1
go run ./ --outputdir=../ --exportlists=_all_,category-ads-all,tld-cn,cn,tld-\!cn,geolocation-\!cn,apple,icloud
go run ./ --outputdir=../ --exportlists=category-ads-all,tld-cn,cn,tld-\!cn,geolocation-\!cn,apple,icloud
go run ./cmd/datdump/main.go --inputdata=../dlc.dat --outputdir=../ --exportlists=_all_
cd ../ && rm -rf code
- name: Generate dlc.dat sha256 hash