#slack #calendar #today #status #automatically #update #google-calendar

app sorry-im-off-today

Automatically update your Slack status if your Google Calendar says that you are off today

4 stable releases

1.0.3 Jun 8, 2022
1.0.2 Feb 28, 2020
1.0.1 Apr 13, 2019
1.0.0 Jan 17, 2019

#2066 in Command line utilities

MIT license

15KB
197 lines

Sorry I'm Off Today

LICENSE pipeline status Crates.io Version Get help on Codementor

Automatically update your Slack status if your Google Calendar says that you are off today.

⚠️ Main repository is here: https://gitlab.com/dsferruzza/sorry-im-off-today ⚠️

How to use

  • compile or install the project
  • just run the sorry-im-off-today executable

Your Google calendar will be fetched, parsed and searched for events beginning by Absent or Congés. If such an event exists today, your Slack status will be updated.

Configuration

Configuration is done using environment variables:

Name Default Value Description
CALENDAR_URL The private URL of a Google calendar. For example: https://calendar.google.com/calendar/ical/xxxxx%40gmail.com/private-xxxxx/basic.ics.
SLACK_API_TOKEN A Slack access token. You need to create an app with the users.profile:read and users.profile:write scopes and add it to your Slack workspace. The OAuth token required here starts with xoxp.

Run automatically

Configure a Cron or a Systemd timer to run it every day (early in the morning) !

License

MIT License Copyright (c) 2019 David Sferruzza

Dependencies

~8–14MB
~282K SLoC