#Python proof-of-concept for importing packagesite.yaml into FreshPorts. The steps are:
1 - From each line of 32500-line yaml file, extract 3 fields creating a csv file
2 - load cvs file into db
Step 2 takes seconds.
I need help / advice with step 1 which takes 3 minutes.
Code and examples are found here:
Combined suggestions from Fosstodon & from bsd.network:
$ time jq -rc '[1, .origin, .name, .version] |
' < ~/tmp/FreeBSD\:12\:amd64/latest/packagesite.yaml > packagesite.csv
$ time ./import-via-copy-packagesite.py
The data get in there fast enough.
Server run by the main developers of the project It is not focused on any particular niche interest - everyone is welcome as long as you follow our code of conduct!