Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save iaindooley/5e7a9c89370b71181b2dd3e4e0015bee to your computer and use it in GitHub Desktop.
Save iaindooley/5e7a9c89370b71181b2dd3e4e0015bee to your computer and use it in GitHub Desktop.
Download all attachments
function downloadAllFiles(notification)
{
var card = new Notification(notification).addedLabel("Download").card();
var folder = DriveApp.createFolder(card.id());
card.attachments().each(function(att)
{
var file = Trellinator.downloadFileToGoogleDrive(att.link());
folder.addFile(file);
});
card.attachLink({name: "All Attachments",link: folder.getUrl()});
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment