mirror of
https://github.com/FAUSheppy/skillbird
synced 2026-01-21 22:07:38 +01:00
[git fast commit] 02. Feb 2019 - 21:23:47
This commit is contained in:
@@ -3,6 +3,7 @@ import sys
|
||||
import NetworkParser
|
||||
import FileReader
|
||||
import argparse
|
||||
import StorrageBackend
|
||||
|
||||
parser = argparse.ArgumentParser(description='Insurgency rating python backend server')
|
||||
parser.add_argument('files', metavar='FILE', type=str, nargs='+',\
|
||||
@@ -15,14 +16,18 @@ parser.add_argument('--start-at-end','-se',dest='start_at_end', action='store_co
|
||||
parser.add_argument('--no-follow','-nf',dest='nofollow', action='store_const',\
|
||||
const=True, default=False, \
|
||||
help="wait for changes on the files (does not imply start-at-end)")
|
||||
parser.add_argument('--one-thread', dest='one-thread', action='store_const',\
|
||||
parser.add_argument('--one-thread', dest='oneThread', action='store_const',\
|
||||
const=True, default=False, \
|
||||
help="run everything in main thread (implies no-follow)")
|
||||
if __name__ == "__main__":
|
||||
args = parser.parse_args()
|
||||
FileReader.readfiles( args.files ,\
|
||||
args.start_at_end,\
|
||||
args.nofollow )
|
||||
start_at_end=args.start_at_end,\
|
||||
nofollow=args.nofollow,
|
||||
oneThread=args.oneThread)
|
||||
if args.oneThread:
|
||||
for l in StorrageBackend.dumpRatings().split("\n"):
|
||||
print(l)
|
||||
if not args.parse_only:
|
||||
Query.listen()
|
||||
else:
|
||||
|
||||
Reference in New Issue
Block a user