-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathbot.py
39 lines (29 loc) · 1013 Bytes
/
bot.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
from FaucetCollector import FaucetCollector
import time
import pyfiglet
from colorama import init, Fore
import argparse
import pathlib
init(autoreset=True)
def FaucetCollector_run():
parser = argparse.ArgumentParser(description="Auto crypto claimer")
parser.add_argument("path", type=str, help="File path to text file")
args = parser.parse_args()
crypto_faucets_file = pathlib.Path(args.path)
if crypto_faucets_file.suffix != ".txt":
raise SystemExit(
f"Unsupported file type: {crypto_faucets_file.suffix}\nSupported file type: .txt"
)
bot = FaucetCollector()
try:
bot.collect_crypto_faucets(crypto_faucets_file)
bot.start_collecting_crypto()
except Exception as e:
bot.error_handler(e)
bot.quit()
except KeyboardInterrupt:
bot.quit()
if __name__ == "__main__":
result = pyfiglet.figlet_format("Faucet Collector")
print(Fore.LIGHTGREEN_EX + result + Fore.RESET)
FaucetCollector_run()