Skip to content

Instantly share code, notes, and snippets.

@shreyansb
shreyansb / smtpexample.py
Created January 16, 2012 19:28
sample code to send a gmail using python
#!/usr/bin/python
import smtplib
from email.MIMEMultipart import MIMEMultipart
from email.MIMEBase import MIMEBase
from email.MIMEText import MIMEText
from email import Encoders
import os
gmail_user = "[email protected]"