dotfiles/.local/bin/mccmd

13 lines
238 B
Text
Raw Normal View History

2021-02-04 17:44:55 +01:00
#!/bin/bash
cat | while read line
do
if [[ "$line" =~ ^/ ]]
then
2021-10-21 18:27:25 +02:00
echo "$line" > /run/minecraft-server.sock
2021-02-04 17:44:55 +01:00
else
2021-10-21 18:27:25 +02:00
echo "say $line" > /run/minecraft-server.sock
2021-02-04 17:44:55 +01:00
# echo "dynmap sendtoweb $line" > /run/minecraft-server.stdin
fi
done