summaryrefslogtreecommitdiff
path: root/scripts/anki.sh
diff options
context:
space:
mode:
authorEnricoGuccii <partyka.003@proton.me>2026-05-03 02:10:07 +0200
committerEnricoGuccii <partyka.003@proton.me>2026-05-03 02:10:07 +0200
commit5ad0cc56f3dbc5a14484cb5547472349bb99a889 (patch)
treec151ae36b454b8f9b54a79243e91a755239f00c3 /scripts/anki.sh
parent70f575a4f8d8adfd0d3abecc6554bdb628166ebd (diff)
add: scripts
Diffstat (limited to 'scripts/anki.sh')
-rwxr-xr-xscripts/anki.sh25
1 files changed, 25 insertions, 0 deletions
diff --git a/scripts/anki.sh b/scripts/anki.sh
new file mode 100755
index 0000000..f592b6c
--- /dev/null
+++ b/scripts/anki.sh
@@ -0,0 +1,25 @@
+#!/bin/bash
+
+NEW=$(curl -s http://127.0.0.1:8765 -H "Content-Type: application/json" -d '{
+ "action":"findCards",
+ "version":6,
+ "params":{
+ "query":"is:new"
+ }
+}')
+
+DUE=$(curl -s http://127.0.0.1:8765 -H "Content-Type: application/json" -d '{
+ "action": "findCards",
+ "version": 6,
+ "params": {
+ "query": "is:due"
+ }
+}')
+
+DONE=$(curl -s http://127.0.0.1:8765 -H "Content-Type: application/json" -d '{
+ "action": "getNumCardsReviewedToday",
+ "version": 6
+}')
+
+
+echo "new:$(echo $NEW | jq '.result | length') due:$(echo $DUE | jq '.result | length') done:$(echo $DONE | jq '.result')"