Thomas Frohwein tfrohwein at fastmail.com
Sun Feb 14 03:37:07 GMT 2021
- - - - - - - - - - - - - - - - - - -
On Fri, Feb 12, 2021 at 02:49:08PM +0100, Louis Brauer wrote:
You can use any Gemini browser for that,
i.e. Lagrange:
https://share.getcloudapp.com/yAu6ZN8E
or Amfora interactively:
https://share.getcloudapp.com/z8uP4j54
or pass the paste directly to amfora:
$ amfora "gemini://paste.gemigrep.com/paste?This is another way to do it"
This will instantly create a new paste and give you the URL.[...]
even more low-level approach:
gemigrep.sh:```#!/bin/shecho "gemini://paste.gemigrep.com/$(echo "gemini://paste.gemigrep.com/paste?$1" \ | openssl s_client -quiet -connect paste.gemigrep.com:1965 2
&1 | tail -1 | cut -d / -f 3)"```
Tested on OpenBSD's ksh(1).
Limitations:- can't deal with newlines. You can insert '%0A' in the string to force a newline.- I haven't figured out how to simplify this even more to set an alias... :/