# -- coding: utf-8 --
import urllib
import csv
from datetime import datetime, timedelta
import os.path


def emojiTranslate(confidence):
		print "Confidence is " + str(confidence)
		if confidence is "1":
				return " 😵"
		if confidence is "3":
				return " 🙀"
		if confidence is "5":
				return " 😐"
		if confidence is "7":
				return " 🙂"
		if confidence is "10":
				return " 💯"
		return "❓"


if os.path.isfile('check_in.csv'):
	with open('check_in.csv') as csvfile:
		print "Inspecting check_in.csv"
		mondayNotes = open("sundayreminder.txt", 'w')
		reader = csv.DictReader(csvfile)
		mondayNotes.writelines("New Goals + Last Week's Priorities:\n")
		mondayNotes.writelines("==================\n")
		mondayNotes.writelines("\n")

		for row in reader:
#			d = timedelta(row['datetime'],datetime.date.today())
#			if d(days)<5:
			if True:
				print "working on the update from " + row["user"]
				mondayNotes.writelines("\n\n" + row["user"] + "\n")
				mondayNotes.writelines("==================\n")
				mondayNotes.writelines("Quarterly Goals\n")
				mondayNotes.writelines("_______________\n")
				mondayNotes.writelines(row["Quarterly Goal #1"])
				mondayNotes.writelines(row["Quarterly Goal #2"])
				mondayNotes.writelines(row["Quarterly Goal #3"])

				mondayNotes.writelines("\n\nLast Week's Tasks" + "\n")
				mondayNotes.writelines("_______________" + "\n")
				task = 1
				try:
					while row["What's this week's prioritized task #" + str(task) + "?"] != "":
						mondayNotes.writelines("* " + row["What's this week's prioritized task #" + str(task) + "?"])
						task += 1
				except:
					print "no more tasks"
#		misc = ["Upcoming in next four weeks", "Department FYSA", "user"]
#		misc = ["user"]
#		for section in misc:
#			mondayNotes.writelines(section + ":\n")
#			mondayNotes.writelines("==================\n")
#			for row in reader:
#				print "Investigating a row"
#				mondayNotes.writelines(row[section] + "__—" + row["user"] + "__\n")
		print "All done, saving file."
		mondayNotes.close()
else:
	print "The check_in.csv is missing."

@@ -525,16 +525,17 @@
 (%22sunday
+_
 reminder
@@ -546,16 +546,16 @@
 %22, 'w')%0A
-
 %09%09reader
@@ -611,11 +611,485 @@
 es(%22
-New
+Attached are last week%E2%80%99s updates for reference for those who used the form; if you didn%E2%80%99t, please forward me along last week%E2%80%99s updates when you get a chance along with this week%E2%80%99s so I can make sure they eventually get added in.%5Cn%5Cn%22)%0A%09%09mondayNotes.writelines(%22Check in submission here: https://www.muckrock.com/assignment/monday-check-in-25/ %5Cn%22)%0A%09%09mondayNotes.writelines(%22Or copy and paste Google Form%5C: http://bit.ly/MuckRockStatus %5Cn%5Cn%22)%0A%09%09mondayNotes.writelines(%22Quarterly
  Goa
@@ -1174,40 +1174,8 @@
 n%22)%0A
-%09%09mondayNotes.writelines(%22%5Cn%22)%0A%0A
 %09%09fo
@@ -1554,32 +1554,41 @@
 otes.writelines(
+%22%5Cn * %22+ 
 row%5B%22Quarterly G
@@ -1616,32 +1616,41 @@
 otes.writelines(
+%22%5Cn * %22+ 
 row%5B%22Quarterly G
@@ -1682,24 +1682,33 @@
 .writelines(
+%22%5Cn * %22+ 
 row%5B%22Quarter
@@ -1937,16 +1937,16 @@
  != %22%22:%0A
-
 %09%09%09%09%09%09mo
@@ -1967,16 +1967,18 @@
 elines(%22
+%5Cn
 * %22 + ro

Update sundayreminder.py