aboutsummaryrefslogtreecommitdiff
path: root/libexec/recit-yesterday
blob: ad6e804dae667d85a9864cf81524a4115543fcfc (plain)
1
2
3
4
5
6
7
8
9
10
11
#!/usr/bin/env bash
# Usage: recit yesterday

# shellcheck source=/dev/null
source lib/loader

recfile=$(load_recit)

fmt_date=$(perl -e "use POSIX qw(strftime); print strftime('%Y-%m-%d', localtime(time - 86400)), qq(\n);")

recsel -e "(Time >> '$fmt_date 00:00:00' && Time << '$fmt_date 23:59:59') || Time == '$fmt_date'" -t Entry "${recfile}"