dotfiles/.local/bin/mccmd

13 lines
255 B
Text
Raw Normal View History

2021-02-04 17:44:55 +01:00
#!/bin/bash
cat | while read line
do
if [[ "$line" =~ ^/ ]]
then
2022-08-20 20:23:03 +02:00
echo "mine $line" > /run/minecraft-server.stdin
2021-02-04 17:44:55 +01:00
else
2022-08-20 20:23:03 +02:00
echo "mine say $line" > /run/minecraft-server.stdin
# echo "mine dynmap sendtoweb $line" > /run/minecraft-server.stdin
2021-02-04 17:44:55 +01:00
fi
done