Project

General

Profile

1 5414 aaronmk
#!/bin/sh
2
# Test-scrubs the test taxonomic names
3
4
selfDir="$(dirname -- "$0")"
5
selfDirName="$(basename -- "$selfDir")"
6
7
cd "$selfDir/../.."
8
9 5423 aaronmk
# Import names
10 5414 aaronmk
make inputs/.TNRS/reinstall # asks user for confirmation
11
make schemas/public/reinstall # asks user for confirmation
12
make inputs/"$selfDirName"/import log=
13 5422 aaronmk
for iter in match_input_names parse_accepted_names; do
14 5414 aaronmk
    make inputs/.TNRS/tnrs/tnrs-remake log=
15
    yes|make schemas/public/reinstall
16
    make inputs/.TNRS/cleanup
17
    make inputs/.TNRS/import log=
18
    make inputs/"$selfDirName"/import log=
19
done
20 5423 aaronmk
21
# Export results
22
# Don't overwrite TNRS.backup, which contains the full TNRS cache
23
make backups/TNRS.sql-remake
24
mv -f backups/TNRS.sql "$selfDir/_scrub"
25
make backups/public.sql-remake
26
mv -f backups/public.sql "$selfDir/_scrub"