+#!/bin/bash
+
+
# Modifies tribler sources to output logging information.
./modify_all_print.sh
+#!/bin/bash
sed -i.bak "s/print[ \t]\+'/print >>sys.strderr, \'/g" Tribler/Core/BitTornado/BT1/Connecter.py;
+#!/bin/bash
+
# Modifies all print instructions in order to output time information.
for i in $(find -name '*.py' -type f | grep -v '.svn'); do sed -i.bak 's/print[ \t]*>>[ \t]*sys.stderr,/print >>sys.stderr, strftime("%d-%m-%Y %H:%M:%S", localtime())," ",/g' $i; sed -i.bak '1i\from time import localtime, strftime' $i; done;
+#!/bin/bash
# Modifies print instructions in given files in order to output time information.
if test $# -lt 2 -o \( "-$1" != "-a" -a "-$1" != "-d" \)
+#!/bin/bash
if test $# -lt 2 -o \( "-$1" != "-f" -a "-$1" != "-t" \)
then
-
+#!/bin/bash
if test $# -lt 2 -o \( "-$1" != "-f" -a "-$1" != "-t" \)
then
+#!/bin/bash
./unmodify_all_print.sh
./set_DEBUG.sh f modified_files_DEBUG
+#!/bin/bash
+
for i in $(find -name '*.py' -type f | grep -v '.svn'); do sed -i.bak 's/print >>sys.stderr, strftime("%d-%m-%Y %H:%M:%S", localtime())," ",/print >>sys.stderr,/g' $i; sed -i.bak '1s/from time import localtime, strftime/ /;t' $i; done;