diff options
| author | pepperpepperpepper <pepper@scannerjammer.com> | 2015-11-16 15:19:30 -0800 |
|---|---|---|
| committer | pepperpepperpepper <pepper@scannerjammer.com> | 2015-11-16 15:19:30 -0800 |
| commit | f65284969e4cffb88914de49ace8850a7f41c836 (patch) | |
| tree | 3c1e0c99abdb9a6376e47fac6a160dbb805967ff /share/frontend/im/OLD/clearthedirectories | |
| parent | 4b86f4b2bdfa6b11d8f8ed0f8adca8d3adfcc0c8 (diff) | |
| parent | c2f9f9ae233a4883b62afe54e9e45e5eb262e6f1 (diff) | |
resolved conflicts
Diffstat (limited to 'share/frontend/im/OLD/clearthedirectories')
| -rwxr-xr-x | share/frontend/im/OLD/clearthedirectories | 51 |
1 files changed, 0 insertions, 51 deletions
diff --git a/share/frontend/im/OLD/clearthedirectories b/share/frontend/im/OLD/clearthedirectories deleted file mode 100755 index 6d5b2a7..0000000 --- a/share/frontend/im/OLD/clearthedirectories +++ /dev/null @@ -1,51 +0,0 @@ -#!/usr/bin/python2.7 - -import sys -import os -import time - -f = open("directories",'r') -lines = f.readlines() -f.close() -newlines = [] -for line in lines: - if "\n" in line: - jerry = line.replace("\n","") - if len(jerry) == 2: - newlines.append(jerry) -dirs = newlines -print dirs -for dir in dirs: - print dir - if len(dir) == 2: - delete = False - os.system("ls "+dir+"/ >> contents") - f = open("contents","r") - thecontents = f.readlines() - f.close() - print thecontents - os.system("rm contents") - tempbool = False - tempbool2 = False - if len(thecontents) != 0: - for x in thecontents: - if ".jpg" in x: - tempbool = True -# if len(thedirs)>40: -# tempbool2 = True - if tempbool == True:# and tempbool2 == True: - print "deleting contents.." - print "moving to directory '"+dir+"'" - if len(thecontents)>0: - x = input("bout to do some deleting 1=yes 0=no") - if x == 1: - print "ok deleting "+dir+"/*" - try: - os.system("rm "+dir+"/*") - except: - continue - else: - sys.exit() - else: - print "nothing there" - continue |
