Skip to content

Instantly share code, notes, and snippets.

@viatcheslavmogilevsky
Last active February 9, 2026 18:42
Show Gist options
  • Select an option

  • Save viatcheslavmogilevsky/fc4524d27d536282de3a6634281fcbef to your computer and use it in GitHub Desktop.

Select an option

Save viatcheslavmogilevsky/fc4524d27d536282de3a6634281fcbef to your computer and use it in GitHub Desktop.

Gmail filters

Filter calendar invites/updates

  • Query: from:(-me) {filename:vcs filename:ics} has:attachment
  • Do this: Skip Inbox, Apply label "Calendar", Never send it to Spam, Never mark it as important, Categorize as Primary
  • XML entry (from export):
	<entry>
		<category term='filter'></category>
		<title>Mail Filter</title>
		<id>tag:mail.google.com,2008:filter:z123456*7890</id>
		<updated>2026-02-09T18:34:11Z</updated>
		<content></content>
		<apps:property name='hasTheWord' value='from:(-me) {filename:vcs filename:ics}'/>
		<apps:property name='hasAttachment' value='true'/>
		<apps:property name='label' value='Calendar'/>
		<apps:property name='shouldArchive' value='true'/>
		<apps:property name='shouldNeverSpam' value='true'/>
		<apps:property name='shouldNeverMarkAsImportant' value='true'/>
		<apps:property name='smartLabelToApply' value='^smartlabel_personal'/>
		<apps:property name='sizeOperator' value='s_sl'/>
		<apps:property name='sizeUnit' value='s_smb'/>
	</entry>

To be continued

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment