2020-05-04 23:01:31 +02:00
|
|
|
# from ics
|
2020-03-21 02:50:13 +01:00
|
|
|
|
|
|
|
Parse text as `.ics` and create table.
|
|
|
|
|
2020-05-04 23:01:31 +02:00
|
|
|
Syntax: `from ics`
|
2020-03-21 02:50:13 +01:00
|
|
|
|
|
|
|
## Examples
|
|
|
|
|
|
|
|
Suppose calendar.txt is a text file that is formatted like a `.ics` (iCal) file:
|
|
|
|
|
|
|
|
```shell
|
|
|
|
> open calendar.txt
|
|
|
|
BEGIN:VCALENDAR
|
|
|
|
BEGIN:VEVENT
|
|
|
|
DTSTART:20171007T200000Z
|
|
|
|
DTEND:20171007T233000Z
|
|
|
|
DTSTAMP:20200319T182138Z
|
|
|
|
SUMMARY:Basketball Game
|
|
|
|
UID:4l80f6dcovnriq38g57g07btid@google.com
|
|
|
|
...
|
|
|
|
```
|
|
|
|
|
2020-05-04 23:01:31 +02:00
|
|
|
Pass the output of the `open` command to `from ics` to get a correctly formatted table:
|
2020-03-21 02:50:13 +01:00
|
|
|
|
|
|
|
```shell
|
2020-05-04 23:01:31 +02:00
|
|
|
> open calendar.txt | from ics
|
2020-03-21 02:50:13 +01:00
|
|
|
───┬────────────────┬──────────────────┬────────────────┬────────────────┬────────────────┬────────────────┬────────────────
|
2020-05-04 23:01:31 +02:00
|
|
|
# │ properties │ events │ alarms │ to-Dos │ journals │ free-busys │ timezones
|
2020-03-21 02:50:13 +01:00
|
|
|
───┼────────────────┼──────────────────┼────────────────┼────────────────┼────────────────┼────────────────┼────────────────
|
|
|
|
0 │ [table 0 rows] │ [table 1 row] │ [table 0 rows] │ [table 0 rows] │ [table 0 rows] │ [table 0 rows] │ [table 0 rows]
|
|
|
|
───┴────────────────┴──────────────────┴────────────────┴────────────────┴────────────────┴────────────────┴────────────────
|
|
|
|
```
|
|
|
|
|
|
|
|
```shell
|
2020-05-04 23:01:31 +02:00
|
|
|
> open calendar.txt | from ics | get events | get properties | where name == "SUMMARY"
|
2020-03-21 02:50:13 +01:00
|
|
|
─────┬─────────┬───────────────────────────────────────┬────────
|
2020-05-04 23:01:31 +02:00
|
|
|
# │ name │ value │ params
|
2020-03-21 02:50:13 +01:00
|
|
|
─────┼─────────┼───────────────────────────────────────┼────────
|
|
|
|
0 │ SUMMARY │ Basketball Game │
|
2020-05-04 23:01:31 +02:00
|
|
|
```
|