File tree Expand file tree Collapse file tree 2 files changed +4
-1
lines changed
Expand file tree Collapse file tree 2 files changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -35,6 +35,9 @@ def main(args):
3535 with open ("/tmp/packagesite.yaml" , "r" ) as f :
3636 for line in f :
3737 line = json .loads (line )
38+ # Skip lines without repopath or sum
39+ if "repopath" not in line or "sum" not in line :
40+ continue
3841 hash_value = line ["sum" ]
3942 repopath : str = line ["repopath" ] # like All/xxx.pkg
4043 repopath_full = (packagesite_file .parent / repopath ).absolute ()
Original file line number Diff line number Diff line change @@ -61,7 +61,7 @@ channel_sync() {
6161 return 1
6262 fi
6363 fi
64- jq -r ' "\(.sum) \(.repopath)"' $tmpdir /packagesite.yaml | sort -k2 > $meta
64+ jq -r ' select(.repopath != null and .sum != null) | "\(.sum) \(.repopath)"' $tmpdir /packagesite.yaml | sort -k2 > $meta
6565 rm -f $tmpdir /packagesite.yaml
6666 export local_dir=$basedir
6767 if [[ $FBSD_PKG_INDEX_ONLY == false ]]; then
You can’t perform that action at this time.
0 commit comments