by ginko · 4y ago · 0 comments
$ mcal
June 2022
w| Mo Tu We Th Fr Sa Su
22| 1 2 3 4 5
23| 6 7 8 9 10 11 12
24| 13 14 15 16 17 18 19
25| 20 21 22 23 24 25 26
26| 27 28 29 30
July 2022
w| Mo Tu We Th Fr Sa Su
26| 1 2 3
27| 4 5 6 7 8 9 10
28| 11 12 13 14 15 16 17
29| 18 19 20 21 22 23 24
30| 25 26 27 28 29 30 31
August 2022
w| Mo Tu We Th Fr Sa Su
31| 1 2 3 4 5 6 7
32| 8 9 10 11 12 13 14
33| 15 16 17 18 19 20 21
34| 22 23 24 25 26 27 28
35| 29 30 31
[1] https://pastebin.com/BNWynUZT cal -3
May 2022 June 2022 July 2022
Su Mo Tu We Th Fr Sa Su Mo Tu We Th Fr Sa Su Mo Tu We Th Fr Sa
1 2 3 4 5 6 7 1 2 3 4 1 2
8 9 10 11 12 13 14 5 6 7 8 9 10 11 3 4 5 6 7 8 9
15 16 17 18 19 20 21 12 13 14 15 16 17 18 10 11 12 13 14 15 16
22 23 24 25 26 27 28 19 20 21 22 23 24 25 17 18 19 20 21 22 23
29 30 31 26 27 28 29 30 24 25 26 27 28 29 30
31This worked:
$ ncal -b -M -A2
June 2022 July 2022 August 2022
Mo Tu We Th Fr Sa Su Mo Tu We Th Fr Sa Su Mo Tu We Th Fr Sa Su
1 2 3 4 5 1 2 3 1 2 3 4 5 6 7
6 7 8 9 10 11 12 4 5 6 7 8 9 10 8 9 10 11 12 13 14
13 14 15 16 17 18 19 11 12 13 14 15 16 17 15 16 17 18 19 20 21
20 21 22 23 24 25 26 18 19 20 21 22 23 24 22 23 24 25 26 27 28
27 28 29 30 25 26 27 28 29 30 31 29 30 31 cal -w -n3
If you must have vertical: cal -w today; cal -w '+1 month'; cal -w '+2 month'
Output: June 2022
Mo Tu We Th Fr Sa Su
22 1 2 3 4 5
23 6 7 8 9 10 11 12
24 13 14 15 16 17 18 19
25 20 21 22 23 24 25 26
26 27 28 29 30
July 2022
Mo Tu We Th Fr Sa Su
26 1 2 3
27 4 5 6 7 8 9 10
28 11 12 13 14 15 16 17
29 18 19 20 21 22 23 24
30 25 26 27 28 29 30 31
August 2022
Mo Tu We Th Fr Sa Su
31 1 2 3 4 5 6 7
32 8 9 10 11 12 13 14
33 15 16 17 18 19 20 21
34 22 23 24 25 26 27 28
35 29 30 31 $ LANG=C cal -3
May 2022 June 2022 July 2022
Su Mo Tu We Th Fr Sa Su Mo Tu We Th Fr Sa Su Mo Tu We Th Fr Sa
1 2 3 4 5 6 7 1 2 3 4 1 2
8 9 10 11 12 13 14 5 6 7 8 9 10 11 3 4 5 6 7 8 9
15 16 17 18 19 20 21 12 13 14 15 16 17 18 10 11 12 13 14 15 16
22 23 24 25 26 27 28 19 20 21 22 23 24 25 17 18 19 20 21 22 23
29 30 31 26 27 28 29 30 24 25 26 27 28 29 30
31 $ cat ~/.vdirsyncer/config
[general]
status_path = "~/.vdirsyncer/status/"
# Contacts
[storage contacts_personal_local]
type = "filesystem"
path = "~/.vdirsyncer/contacts/"
fileext = ".vcf"
[storage contacts_personal_remote]
type = "carddav"
url = "https://example.com/remote.php/carddav/"
username = "bloodninja"
password = "hunter2"
[pair contacts_personal]
a = "contacts_personal_local"
b = "contacts_personal_remote"
collections = ["from a", "from b"]
conflict_resolution = "b wins"
# Calendars
[storage calendar_personal_local]
type = "filesystem"
path = "~/.vdirsyncer/calendars/"
fileext = ".ics"
[storage calendar_personal_remote]
type = "caldav"
url = "https://example.com/remote.php/caldav/"
username = "bloodninja"
password = "hunter2"
[pair calendars_personal]
a = "calendar_personal_local"
b = "calendar_personal_remote"
collections = ["from a", "from b"]
conflict_resolution = "b wins"
metadata = ["color"]
Then I set up khal to read from the directory that vdirsync stores data in, and display three months with events and use the ISO-8601 date format: $ cat ~/.config/khal/config
[calendars]
[[personal]]
path = ~/.vdirsyncer/calendars/*
type = discover
[default]
default_calendar = personal
highlight_event_days = True
timedelta = 45d
[locale]
firstweekday = 6
timeformat = %H:%M
dateformat = %Y-%m-%d
longdateformat = %Y-%m-%d
datetimeformat = %Y-%m-%d %H:%M
longdatetimeformat = %Y-%m-%d %H:%M
default_timezone = Asia/Jerusalem
unicode_symbols = False
[highlight_days]
color = light green
method = fg
If you have any questions or suggestions I'll be watching this thread.