lfos / calcurse

A text-based calendar and scheduling application
https://calcurse.org
BSD 2-Clause "Simplified" License
963 stars 95 forks source link

[Feature request] Read from stdin without import #458

Open avidseeker opened 1 year ago

avidseeker commented 1 year ago

Many smartphone journaling apps add a calendar view to journal entries.

It would be nice if calcurse can read from stdin and visualize the input "on-the-fly" without having to import.

For example, if journal.md contains:

# 2023-04-25: Created hello world app
bla bla bla
# 2023-01-10: Wrote lorem ipsum
lorem ipsum
...

If this feature is implemented, then one can run:

sed -n "s/^#//p" journal.md | calcurse -

to make calcurse view journal summaries in any view the user likes (weekly, monthly, etc). Of course this has many other possibilities like visualizing habits from csv file or visualizing git commits, etc...

And with simple text stream manipulation, the input can be modified to be exactly the format calcurse expects it to be.

As a current workaround, it's possible to import events to specified data and apts files, different than the main calendar.

avidseeker commented 2 weeks ago

A limited workaround using zsh:

$ calcurse -c =(echo "07/01/2024 [1] Today is the day")

For the same reason mentioned here in https://github.com/lfos/calcurse/issues/484, <(echo) and calcurse -c /dev/stdin don't work.