This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Original code by Jason: https://gist.github.com/jasonrdsouza/1674794. All the credits to him. This is just my version of it. | |
import email, getpass, imaplib, os | |
detach_dir = os.getcwd() | |
print("Current Working Directory: ", detach_dir) # directory where to save attachments (default: current) | |
user = input("Enter your GMail username:") | |
pwd = getpass.getpass("Enter your password: ") | |
# connecting to the gmail imap server |