From 5a9da62ded70cfb05309aebcb1c1ee09d17948c5 Mon Sep 17 00:00:00 2001 From: lonkaars Date: Thu, 1 Apr 2021 12:47:12 +0200 Subject: added scripts for post meta json things --- scripts/posts | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100755 scripts/posts (limited to 'scripts/posts') diff --git a/scripts/posts b/scripts/posts new file mode 100755 index 0000000..12900e1 --- /dev/null +++ b/scripts/posts @@ -0,0 +1,16 @@ +#!/bin/sh + +postsmeta=$( find ../posts \ + -name "*.md" \ + -type f \ + -exec ./postinfo {} \; |\ + jq -s '.') + +jq -n \ + --argjson valid_tags "$(./tags)" \ + --argjson posts "$postsmeta" \ +'{ + "valid_tags": $valid_tags, + "posts": $posts +}' + -- cgit v1.2.3