From 7c4657c41c603307a7d6cf1293294f34eceea24f Mon Sep 17 00:00:00 2001 From: tslil clingman <> Date: Tue, 5 Oct 2021 22:08:38 -0400 Subject: Ready for CGI tak on Gemini! Probably bugs & security holes O.o --- ct1986 | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100755 ct1986 (limited to 'ct1986') diff --git a/ct1986 b/ct1986 new file mode 100755 index 0000000..047999b --- /dev/null +++ b/ct1986 @@ -0,0 +1,17 @@ +#!/bin/bash +META="text/gemini; charset=utf-8" + +if [ -n "${QUERY_STRING}" ]; then + new_ptn="${PATH_INFO//\//}${QUERY_STRING}." + printf '20 %s\r\n' "$META" + printf '```\n' + while [ "$(pgrep geminict | wc -l)" > "10" ]; do + sleep 0.25s; + done + geminict "$new_ptn" + printf '```\n' + echo 'Please be patient, ct1986 is a slow bot and no more than 10 instances are allowed concurrently on the server.' + printf "=> gemini://l-3.space/ct1986/$new_ptn/ Enter next move" +else + printf "10 Enter starting move:\r\n" +fi; -- cgit v1.3.1