From fc93c1484561da70f16992af8c9f87ac58ead46b Mon Sep 17 00:00:00 2001 From: Michel Oosterhof Date: Sat, 21 Jul 2018 10:14:50 +0000 Subject: [PATCH] code to delete old compiled code --- bin/cowrie | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/bin/cowrie b/bin/cowrie index 3a13f3ff..abcec7b4 100755 --- a/bin/cowrie +++ b/bin/cowrie @@ -162,6 +162,14 @@ fi find_cowrie_directory $0 cd ${COWRIEDIR} export PYTHONPATH=${PYTHONPATH}:${COWRIEDIR}/src + +# This is for the move to src/ on 2018-07-21 +# It deletes old compiled python code +# Can be removed at some time in the future +for dir in ${COWRIEDIR}/twisted ${COWRIEDIR}/cowrie; do + [ -d ${dir} ] && find ${dir} -name '*pyc' | xargs rm -f +done + PIDFILE=var/run/cowrie.pid set -e