shr-txt.sh

This commit is contained in:
dece 2022-07-05 22:34:07 +02:00
parent cb3433e93c
commit 911b60b792
2 changed files with 6 additions and 2 deletions

6
shr-txt.sh Executable file
View file

@ -0,0 +1,6 @@
#!/bin/bash
# Share a text file to shrlok.
cat <(printf '{"type":"txt"}\0') "$1" \
| socat - UNIX-CONNECT:/run/shrlok/shr.sock \
| sed 's|/var/www/files|https://files.dece.space|' \
; echo

View file

@ -1,2 +0,0 @@
#!/usr/bin/env python3