There’s that famous scene at the end of Raiders of the Lost Ark where the Ark of the Covenant gets packed into a wooden crate and wheeled into a government warehouse. The camera pulls back, and all you can see are rows and rows of nearly identical boxes. Decades later, when Indiana Jones returns to that warehouse in Kingdom of the Crystal Skull, finding the right crate is still an adventure. If you’ve ever gone looking for an email you know you saw on Tuesday, you know the feeling.
I think of inbox zero as a goal we get to visit–for some people it’s Venice and for others…it’s Atlantis. But, it should be a place we can all get to, and not a legendary dream. Regardless, email organization–not even inbox zero–is one of those peak experiences Maslow wrote about, it’s a place we reach for a brief moment when we’re operating at our best. We see that glorious image of “no new mail,” take a breath, and then somebody hits Reply All.
Fortunately, Gmail gives us a few ways to navigate the warehouse without having our hearts ripped out in the Temple of Doom. Labels help us find messages again after we archive them. Inbox tabs give promotions and updates a place of their own. Google Tasks gives us somewhere to put the work an email creates. And when we find ourselves doing the same sorting job every week, Gemini can help us write a script. That’s just a set of instructions. We describe the job, Gemini drafts the instructions, and Google Apps Script runs them. If we can just follow the steps–like following Sean Connery’s journal in The Last Crusade–we can find ourselves with the Holy Grail.
Give Gemini a map
A script is a set of instructions. Gemini can help you write those instructions, and Google Apps Script can run them.The part that takes a little thought is the part you already know best. When a particular email comes in, what do you usually do with it and where do you want it to go? If you spend a little bit of time talking to Gemini, you can find yourself with the kind of treasure that is so perfect, it belongs in a museum.
Here’s how to turn your answer into an automation of your own.
- Pick one chore you’re tired of doing by hand. Maybe you look for the office bulletin every Monday, or you spend Friday afternoon gathering messages about next week’s events. Pick something small enough that you can finish this sentence: I’ll know this worked when I can open Gmail and see ____.
- Explain the job the way you’d explain it to a colleague. Try this with Gemini: “Every Friday, the office sends me a message with ‘Weekly Bulletin’ in the subject. I’d like Gmail to give it a Bulletins label and leave it in my inbox. What else do you need to know before you write the script?” Use your own example, and be specific about the action. A label helps you find a message again. Archiving takes it out of the inbox and keeps it in All Mail. Sending it to Trash is a decision worth spelling out.
- Give the plan a practice question. I’m a teacher. Of course there’s a comprehension check. Ask, “What would happen to the office bulletin? What would happen to a parent’s email that mentions the bulletin?” If Gemini says both would get labeled, you’ve caught a loose rule while it’s still easy to fix. Once the answers make sense, ask it to write the script, include a preview mode, and walk you through the setup.
- Try a small batch and look at the results. Open Google Apps Script, choose New project, paste in the script, and follow the preview directions Gemini gave you. Ask for a preview that shows which messages matched and what would happen to them. A report that says “five matches” is mildly reassuring. Seeing which five tells you whether your instructions worked. When the preview looks right, apply the rule to that same small group and check the results in Gmail.
- Decide when you want the help. You can run the script yourself whenever you need it. If you’d like it to run every morning or once a week, ask Gemini to walk you through setting up a time-driven trigger. That’s Google’s term for putting the job on a schedule. You can also ask the script to send you a short summary of what it labeled, archived, or moved to Trash.
What this looks like on a school morning
Personally, I like to begin the day with three things in my inbox: the emails I snoozed away until today, a short summary of what was moved by my script, and a Google Tasks list of what needs my attention. One of my first orders of business is to scan that summary, especially anything that went to Trash. Scripts aren’t perfect, so if something went to trash that I need, I can see it and move it back right away. Then I can get to the work itself. If a family’s email needs a thoughtful response and I have morning duty, I’ll snooze it until my schedule is open. If I need to do something before I reply, that action belongs on my task list. “Check the assignment and call home” is a much more useful reminder than opening the same email for the fourth time and hoping it jogs my memory.
During report card season, I’ll take that small kindness wherever I can get it because when it comes to getting my communication right, I’ll cheat very big to get my emails in order. For your first attempt, think of the email you went digging for this week and start there.
With any luck, the next time somebody asks what time the buses leave, you can just tell them without have to shoot the swordsman in Cairo.