annotate bin/hdr.sh @ 143:ddff993994be

too clever by half, keys won't work in parallel for e.g. media types
author Henry S. Thompson <ht@inf.ed.ac.uk>
date Wed, 20 Oct 2021 15:47:55 +0000
parents 9a1de2c4ffe3
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
14
9a1de2c4ffe3 modelled on plinks
Henry S. Thompson <ht@inf.ed.ac.uk>
parents:
diff changeset
1 #!/usr/bin/bash
9a1de2c4ffe3 modelled on plinks
Henry S. Thompson <ht@inf.ed.ac.uk>
parents:
diff changeset
2 echo $(date) $(hostname)
9a1de2c4ffe3 modelled on plinks
Henry S. Thompson <ht@inf.ed.ac.uk>
parents:
diff changeset
3 h=$(hostname)
9a1de2c4ffe3 modelled on plinks
Henry S. Thompson <ht@inf.ed.ac.uk>
parents:
diff changeset
4 hn=${h##*n}
9a1de2c4ffe3 modelled on plinks
Henry S. Thompson <ht@inf.ed.ac.uk>
parents:
diff changeset
5 if [ $hn -eq 0 ]
9a1de2c4ffe3 modelled on plinks
Henry S. Thompson <ht@inf.ed.ac.uk>
parents:
diff changeset
6 then seq --format="%03.0f" $1 $2
9a1de2c4ffe3 modelled on plinks
Henry S. Thompson <ht@inf.ed.ac.uk>
parents:
diff changeset
7 else seq --format="%03.0f" $3 $4
9a1de2c4ffe3 modelled on plinks
Henry S. Thompson <ht@inf.ed.ac.uk>
parents:
diff changeset
8 fi |\
9a1de2c4ffe3 modelled on plinks
Henry S. Thompson <ht@inf.ed.ac.uk>
parents:
diff changeset
9 parallel --will-cite -j 48 -N 1 bin/doHdr.sh ${hn} '{#}' '{}'
9a1de2c4ffe3 modelled on plinks
Henry S. Thompson <ht@inf.ed.ac.uk>
parents:
diff changeset
10 echo $(date) $(hostname) $?