mirror of
https://git.pumpin.online/funkpower/typikon.git
synced 2026-10-22 18:57:13 +00:00
print it as a table, or without the glyphs
--format takes text, json, csv, tsv or ics. --json and --ics stay as shorthand, because the widgets already call them. csv and tsv are RFC 4180 quoted, one header row, one row per day, with commemorations joined by a semicolon: a cell that is itself a table is worse than a cell you have to split. --list-fields prints the twenty columns, --fields picks a subset in the order you name them, and a column that does not exist is caught before anything is printed rather than silently emitting an empty cell. --no-emoji drops the glyphs from every format, including the emoji field in the JSON, and collapses the column in the text output rather than leaving a hole where a glyph used to be.
This commit is contained in:
@@ -120,11 +120,19 @@ spiritual father can.
|
||||
## Output
|
||||
|
||||
```console
|
||||
$ typikon --json --days 7 # for a bar, a widget, a script
|
||||
$ typikon --ics --days 365 > orthodox.ics
|
||||
$ typikon --year 2027 # a year's key dates, to check against yours
|
||||
$ typikon --days 7 # for a person
|
||||
$ typikon --format json --days 7 # for a bar, a widget, a script
|
||||
$ typikon --format csv --days 365 # for a spreadsheet
|
||||
$ typikon --format tsv --fields date,fast,title
|
||||
$ typikon --format ics --days 365 > orthodox.ics
|
||||
$ typikon --year 2027 # a year's key dates, to check against yours
|
||||
```
|
||||
|
||||
`--no-emoji` drops the glyphs from every format, for a terminal or a bar
|
||||
without them. `--list-fields` prints the columns `csv` and `tsv` can take, and
|
||||
`--fields` picks a subset in the order you name them. `--json` and `--ics`
|
||||
still work as shorthand.
|
||||
|
||||
The JSON shape is flat and stable. Front ends are the thing most likely to be
|
||||
written by someone else, and a schema that shifts underneath them is a bad
|
||||
neighbour.
|
||||
|
||||
Reference in New Issue
Block a user