-
-
Save Lechindianer/9953299 to your computer and use it in GitHub Desktop.
Eventcmd for mcabber
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
echo "$1 $2 $3 $4" >> ~/test.mcabber.log | |
EVENT_TYPE=$1 | |
EVENT_SUBTYPE=$2 | |
JID=$3 | |
FILE=$4 | |
TITLE="mcabber" | |
#ICON="$HOME/.mcabber/images/chat.png" | |
TIMEOUT=10000 | |
function new_message_in() { | |
# notify-send -i $ICON -t $TIMEOUT "$TITLE" "New message from ${JID}." | |
notify-send -t $TIMEOUT "$TITLE" "New message from ${JID}." | |
} | |
if [[ $EVENT_TYPE == "MSG" ]] && [[ $EVENT_SUBTYPE == "IN" ]] | |
then | |
new_message_in | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
mcabberrc:
set events_command = ~/.mcabber/eventcmd
set events_ignore_active_window = 1
set eventcmd_use_nickname = 1