42 lines
692 B
Python
42 lines
692 B
Python
from __future__ import annotations
|
|
|
|
import argparse
|
|
from pathlib import Path
|
|
|
|
from .client import CrackLabClient
|
|
|
|
|
|
def main() -> int:
|
|
parser = argparse.ArgumentParser(
|
|
description="WiFi GPS Mapper CrackLab client"
|
|
)
|
|
|
|
parser.add_argument(
|
|
"--once",
|
|
action="store_true",
|
|
help="Import and process jobs once, then exit.",
|
|
)
|
|
|
|
args = parser.parse_args()
|
|
|
|
script_dir = Path(
|
|
__file__
|
|
).resolve().parent
|
|
|
|
client = CrackLabClient(
|
|
script_dir
|
|
)
|
|
|
|
if args.once:
|
|
client.run_once()
|
|
return 0
|
|
|
|
client.run_forever()
|
|
return 0
|
|
|
|
|
|
if __name__ == "__main__":
|
|
raise SystemExit(
|
|
main()
|
|
)
|