summaryrefslogtreecommitdiff
path: root/awk/index_positions.awk
diff options
context:
space:
mode:
authorLeon Rische <leon.rische@me.com>2020-04-29 23:42:18 +0200
committerLeon Rische <leon.rische@me.com>2020-05-01 14:13:20 +0200
commitba0307070ccccdd195a96af9214b69340beecb1d (patch)
tree9b4e64f67f45b71275a5a71ec5b15824ae9d2072 /awk/index_positions.awk
parent7fd070d98a0425fa9f74fa6fd70074a1dd1fabde (diff)
Filter due cards in position indexer
Diffstat (limited to 'awk/index_positions.awk')
-rw-r--r--awk/index_positions.awk6
1 files changed, 5 insertions, 1 deletions
diff --git a/awk/index_positions.awk b/awk/index_positions.awk
index 36e9cbe..e409f52 100644
--- a/awk/index_positions.awk
+++ b/awk/index_positions.awk
@@ -1,5 +1,6 @@
BEGIN {
FS="|";
+ now = strftime("%FT%TZ", systime(), 1);
fc_tag = ":" or_default(fc_tag, "fc") ":";
suspended_tag = ":" or_default(suspended_tag, "suspended") ":";
@@ -64,6 +65,9 @@ in_data && /^\|.*\|$/ {
box = trim($4);
interval = trim($5);
due = trim_surrounding($6);
- print FILENAME "\t" id "\t" type "\t" suspended "\t" position "\t" ease "\t" box "\t" interval "\t" due;
+
+ if (!(filter_due == "1") || (due < now && suspended == "0")) {
+ print FILENAME "\t" id "\t" type "\t" suspended "\t" position "\t" ease "\t" box "\t" interval "\t" due "\t" inherited_tags "\t" local_tags;
+ }
}
}