4766b891ff
Create setup.py Allow Two Factor Authentication Lots of smaller changes
22 lines
531 B
Python
Executable file
22 lines
531 B
Python
Executable file
#!/usr/bin/env python3
|
|
|
|
import configparser, os.path
|
|
|
|
if os.path.isfile("config.cfg"):
|
|
raise IOError("config.cfg already exists. Please remove it before running this script.")
|
|
|
|
config = configparser.RawConfigParser()
|
|
|
|
config.add_section('facebook')
|
|
|
|
user = input("Facebook username (email address): ")
|
|
pwd = input("Facebook password: ")
|
|
|
|
config.set('facebook', 'user', user)
|
|
config.set('facebook', 'pass', pwd)
|
|
|
|
with open('config.cfg', 'wt') as cfg:
|
|
config.write(cfg)
|
|
|
|
print("We're all done. You can now use Pokemon. Have fun!")
|