If this plugin helps you, I'd really appreciate your support. You can buy me a coffee here.
A plugin that allows you to import calendar events from GCal, iCloud, Outlook and web based subscriptions in the iCal format. This appends all of the events scheduled for the current day to that days daily note page.
Important! Version 2.0 requires Logseq to be at version 0.6.0 in order to work properly with a GUI. You can still configure settings manually.
- Three ways to import events
- Use the command pallet via
mod+shift+p
and select a specific calendar to import - Use the keyboard shortcut you defined in the settings to import that specific calendar
- Click the icon in the toolbar to import all calendars to daily note page
- Use the command pallet via
- Import events from past days
- When you are on either a non journal page, the home page or the current daily note, Logseq will import the current days events to the current days daily note
- When you are in a journal page for a different day, that dates events will be added to that dates daily note page (How cool!)
- Get the ics link from each calendar provider using the below steps
- In Logseq, navigate to the entry in the plugins list for "Logseq Calendar Plugins
- Click the gear and then "Open Settings"
- Make sure you are at least on version 0.6.0 of logseq
- Open plugin settings by clicking the edit settings button
- Set templates, timeformat,
disabled
is required and is defined by logseq itself, you don't need to do anything heretemplate
is the text that will go on the parent block(more on the syntax below)- Underneath the block titled the calendar name, you will see blocks in this format
templateLine2
is a block indented aftertemplate
accounts
are defined by just entering the iCAL and your desired title for the calendar. You can have up to three calendars. The first is mandatory but the others can be left blank to not be included while calling the fetch method. If you don't want a calendar to show up, leave either the title or the URL blanktimeFormat
can be 12 or 24. The choice is regarding whether you want 24 hours time(19:00) or 12 hour time. (7:00 pm)
Breaking Change to the logseq calendars plugin. It now uses the new beautiful native settings GUI in logseq released in version 0.6.0
You will have to insert all calendars again. You should probably also delete the existing settings file and start fresh. Release also requires logseq version 0.6.0 to be installed to access the GUI.
If you want to use it with an older version of logseq, change your settings file to follow this format:
{
"template": "{Start} - {End}: {Title}",
"templateLine2": "{Description} at {Location}",
"calendar1Name": "Google Calendar",
"calendar1URL": "https://calendar.google.com/calendar/ical/rao6fvrrsq6mdorf9n30fs6mk4%40group.calendar.google.com/private-18ccd424400ef24c5d343ec93b289590/basic.ics",
"calendar2Name": "",
"calendar2URL": "",
"calendar3Name": "",
"calendar3URL": "",
"disabled": false,
"timeFormat": "12 hour time"
}
- In the website, go to your calendar
- Go to the settings for the specific calendar you want
- Get your secret address
- This is the link you need
- Make calendar public
- Right click the calendar again and click share publish link.
- This should bring you to an email with a link in the body.
- The link will be in the format webcal://p54-caldav.icloud.com/published/2/xjshdkljshvkjsldhsdkhsdkj
- Remove the
webcal://
from the beginning - Take the link as
p54-caldav.icloud.com/published/2/xjshdkljshvkjsldhsdkhsdkj
- This is the link you need
- Go to the calendar on the side bar, hit the three dots and click share. When prompted enter another one of your email addresses.
- Give them permission to view all details
- Open the email you would've received.
- At the bottom of the email, there will be a response in this form
- Copy the link that the text
this URL
points to. - This is the link you need
- to set custom templates, you can use the following placeholders
{Description}
{Title}
{Start}
{End}
{Date}
{Location}
{RawLocation}
- Templates are the format by which the events are inserted
- You can define templates in settings
{Location}
will collapse URLs (e.g. for videoconferencing) into short clickable links by default (e.g. "https://videocall.example.com/j/123456789?pwd=abcdefghijklmnopqrstuvwxyz or Room 101" will be rendered as "videocall.example.com/... or Room 101"), while RawLocation will preserve the original text.- Difference between
template
andtemplateline2
- Calendar icons created by Freepik - Flaticon
- Credits to @hkgnp for his logseq-dateutil library
- Credits to https://github.com/jens-maus/node-ical