aboutsummaryrefslogtreecommitdiffhomepage
path: root/threadcat-del.sh
blob: c1087baeecb1ff79fa9ef36ee4804d23fedf2646 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/bin/bash

BOARD_NAME=$1
THREAD_NAME=$2

if [ -z "${THREAD_NAME}" ]; then
    THREAD_NAME=$BOARD_NAME
else
    THREAD_NAME=$BOARD_NAME/$THREAD_NAME
fi

if [ ! -z "${THREAD_NAME}" ]; then
    ssh $THREADCAT_USER "rm /opt/threadcat/$THREAD_NAME"
else
    echo You did not provide a thread name.
    echo USAGE: "threadcat del [BOARD] THREAD"
fi