Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save iaindooley/ded683c685d263cc5583afb341ce8e7c to your computer and use it in GitHub Desktop.
Save iaindooley/ded683c685d263cc5583afb341ce8e7c to your computer and use it in GitHub Desktop.
Email me if cards in To Do
function emailMeDailyIfCardsInToDo(board,signature,original_time)
{
var msg = [];
new Board(board).list("To Do").cards().each(function(card)
{
msg.push(card.name());
});
if(msg.length)
{
MailApp.sendEmail("youremail@example.com",
"Stuff to do "+original_time.butlerDefaultDate(),
"Here, here is some stuff to do:\n\n"+msg.join("\n")+"\n\n");
}
ExecutionQueue.push("emailMeDailyIfCardsInToDo",board,signature,original_time.addHours(24));
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment