ttscoff / Slogger

Social logging script for Day One
757 stars 160 forks source link

Colloquy plugin #362

Open mrjcleaver opened 9 years ago

mrjcleaver commented 9 years ago

It'd be nice to be able to slog Colloquy chats.

mrjcleaver commented 9 years ago

Some time ago I built this:

#! /bin/sh 
cd "$HOME/Documents/Colloquy Transcripts"

CHANNEL=$2
if [ X$CHANNEL = X ]; then
    CHANNEL='*'
fi

IRCUSERNAME=MartinClea
IRCBEFOREME=2
IRCAFTERME=2
DATE=$1
if [ ! -n "$DATE" ]
then 
    DATE=`date "+%d-%m-%y"`
fi

for i in $CHANNEL*$DATE*; 
do 
xsltproc  $HOME/Library/Application\ Support/Colloquy/PlugIns/plaintext.xsl "$i" | sed -e "/^/s//$i /" | grep -A$IRCBEFOREME -B$IRCAFTERME $IRCUSERNAME; 
done | grep -v " » "

Seems it no longer works - I think the folder structure changed - but it's a start.