forked from expo/troggle
cleaning options list
This commit is contained in:
parent
edbe793c68
commit
819eca5dea
@ -346,26 +346,27 @@ class JobQueue():
|
|||||||
def usage():
|
def usage():
|
||||||
print("""Usage is 'python databaseReset.py <command> [runlabel]'
|
print("""Usage is 'python databaseReset.py <command> [runlabel]'
|
||||||
where command is:
|
where command is:
|
||||||
|
test - testing... imports people and prints profile. Deletes nothing.
|
||||||
|
profile - print the profile from previous runs. Import nothing.
|
||||||
|
|
||||||
reset - normal usage: clear database and reread everything from files - time-consuming
|
reset - normal usage: clear database and reread everything from files - time-consuming
|
||||||
caves - read in the caves
|
caves - read in the caves
|
||||||
logbooks - read in the logbooks
|
logbooks - read in the logbooks
|
||||||
people - read in the people from folk.csv
|
people - read in the people from folk.csv
|
||||||
QMs - read in the QM csv files (older caves only)
|
QMs - read in the QM csv files (older caves only)
|
||||||
reinit - clear database (delete everything) and make empty tables. Import nothing.
|
|
||||||
scans - the survey scans in all the wallets
|
scans - the survey scans in all the wallets
|
||||||
survex - read in the survex files - all the survex blocks but not the x/y/z positions
|
survex - read in the survex files - all the survex blocks but not the x/y/z positions
|
||||||
survexpos - just the x/y/z Pos out of the survex files
|
survexpos - just the x/y/z Pos out of the survex files
|
||||||
|
survexall - both survex and survexpos
|
||||||
|
|
||||||
tunnel - read in the Tunnel files - which scans the survey scans too
|
tunnel - read in the Tunnel files - which scans the survey scans too
|
||||||
profile - print the profile from previous runs. Import nothing.
|
drawings - Tunnel, QMs, scans
|
||||||
|
|
||||||
resetend - (archaic?)
|
reinit - clear database (delete everything) and make empty tables. Import nothing.
|
||||||
writecaves - *disabled* (archaic?)
|
|
||||||
autologbooks - read in autologbooks (what are these?)
|
|
||||||
dumplogbooks - write out autologbooks (not working?)
|
|
||||||
syncuser - needed after reloading database from SQL backup
|
syncuser - needed after reloading database from SQL backup
|
||||||
surveyimgs - read in scans by expo, must run after "people". Not used.
|
autologbooks - Not used. read in autologbooks (what are these?)
|
||||||
test - testing...
|
dumplogbooks - Not used. write out autologbooks (not working?)
|
||||||
|
surveyimgs - Not used. read in scans by-expo, must run after "people".
|
||||||
|
|
||||||
and [runlabel] is an optional string identifying this run of the script
|
and [runlabel] is an optional string identifying this run of the script
|
||||||
in the stored profiling data 'import-profile.json'
|
in the stored profiling data 'import-profile.json'
|
||||||
@ -392,11 +393,8 @@ if __name__ == "__main__":
|
|||||||
usage()
|
usage()
|
||||||
exit()
|
exit()
|
||||||
elif "test" in sys.argv:
|
elif "test" in sys.argv:
|
||||||
jq.enq("reinit",reinit_db)
|
|
||||||
jq.enq("dirsredirect",dirsredirect)
|
|
||||||
jq.enq("caves",import_caves)
|
jq.enq("caves",import_caves)
|
||||||
jq.enq("people",import_people)
|
jq.enq("people",import_people)
|
||||||
jq.enq("scans",import_surveyscans)
|
|
||||||
elif "caves" in sys.argv:
|
elif "caves" in sys.argv:
|
||||||
jq.enq("caves",import_caves)
|
jq.enq("caves",import_caves)
|
||||||
elif "logbooks" in sys.argv:
|
elif "logbooks" in sys.argv:
|
||||||
@ -422,25 +420,28 @@ if __name__ == "__main__":
|
|||||||
jq.enq("scans",import_surveyscans)
|
jq.enq("scans",import_surveyscans)
|
||||||
elif "survex" in sys.argv:
|
elif "survex" in sys.argv:
|
||||||
jq.enq("survexblks",import_survexblks)
|
jq.enq("survexblks",import_survexblks)
|
||||||
jq.enq("survexpos",import_survexpos)
|
|
||||||
elif "survexpos" in sys.argv:
|
elif "survexpos" in sys.argv:
|
||||||
jq.enq("survexpos",import_survexpos)
|
jq.enq("survexpos",import_survexpos)
|
||||||
elif "surveyimgs" in sys.argv:
|
|
||||||
jq.enq("surveyimgs",import_surveyimgs)
|
|
||||||
elif "tunnel" in sys.argv:
|
elif "tunnel" in sys.argv:
|
||||||
jq.enq("tunnel",import_tunnelfiles)
|
jq.enq("tunnel",import_tunnelfiles)
|
||||||
elif "help" in sys.argv:
|
elif "survexall" in sys.argv:
|
||||||
usage()
|
jq.enq("survexblks",import_survexblks)
|
||||||
elif "resetend" in sys.argv:
|
jq.enq("survexpos",import_survexpos)
|
||||||
|
elif "drawings" in sys.argv:
|
||||||
jq.enq("QMs",import_QMs)
|
jq.enq("QMs",import_QMs)
|
||||||
|
jq.enq("scans",import_surveyscans)
|
||||||
jq.enq("tunnel",import_tunnelfiles)
|
jq.enq("tunnel",import_tunnelfiles)
|
||||||
jq.enq("surveyimgs",import_surveyimgs)
|
elif "surveyimgs" in sys.argv:
|
||||||
|
jq.enq("surveyimgs",import_surveyimgs) # imports into tables which are never read
|
||||||
elif "autologbooks" in sys.argv: # untested in 2020
|
elif "autologbooks" in sys.argv: # untested in 2020
|
||||||
import_auto_logbooks()
|
import_auto_logbooks()
|
||||||
elif "dumplogbooks" in sys.argv: # untested in 2020
|
elif "dumplogbooks" in sys.argv: # untested in 2020
|
||||||
dumplogbooks()
|
dumplogbooks()
|
||||||
elif "profile" in sys.argv:
|
elif "profile" in sys.argv:
|
||||||
jq.showprofile()
|
jq.showprofile()
|
||||||
|
elif "help" in sys.argv:
|
||||||
|
usage()
|
||||||
|
exit()
|
||||||
else:
|
else:
|
||||||
usage()
|
usage()
|
||||||
print("%s not recognised as a command." % sys.argv[1])
|
print("%s not recognised as a command." % sys.argv[1])
|
||||||
|
Loading…
x
Reference in New Issue
Block a user