That is to overcome warnings from shellcheck
In .clusterfuzzlite/build.sh line 8:
hash=($(sha256sum "$file"))
^------------------^ SC2207 (warning): Prefer mapfile or read -a to split command output (or quote to avoid splitting).
In .clusterfuzzlite/build.sh line 9:
cp "$file" "/tmp/oxigraph_$1/$hash"
^---^ SC2128 (warning): Expanding an array without an index only gives the first element.
although original code is making a cute use of an array, if we are to follow
shellcheck and use mapfile or read -a - and then use explicit index -- makes it
just too cumbersome. IMHO explicit awk would be easier to read etc.
e.g. if one command fails or undefined variable is used.
In turn it would allow to address such codeshell warnings like
In bench/bsbm_graphdb.sh line 7:
cd bsbm-tools
^-----------^ SC2164 (warning): Use 'cd ... || exit' or 'cd ... || return' in case cd fails.
Did you mean:
cd bsbm-tools || exit
but note that there are uses left like
❯ git grep 'cd bsbm-tools || exit'
bench/bsbm_blazegraph.sh:cd bsbm-tools || exit
bench/bsbm_jena.sh:cd bsbm-tools || exit
bench/bsbm_rdf4j.sh:cd bsbm-tools || exit
but may be `|| exit` should be removed and they should exit with error? or the
same should be added to the other 3?
❯ git grep 'cd bsbm-tools$'
bench/bsbm_graphdb.sh:cd bsbm-tools
bench/bsbm_oxigraph.sh:cd bsbm-tools
bench/bsbm_virtuoso.sh:cd bsbm-tools
Uses by default targets of 1GB of RAM and 2 threads.
Data parsing is in most of the case slower than ingestion so no more than 2 threads are used anyway.