File tree Expand file tree Collapse file tree 1 file changed +6
-17
lines changed Expand file tree Collapse file tree 1 file changed +6
-17
lines changed Original file line number Diff line number Diff line change 12
12
getfileList = ' '
13
13
newfileExt = []
14
14
newSet = set ()
15
- fullPath = os .path .join (chgeDirectory , getfileList )
16
- getFilename = []
17
- myAppend = []
18
-
15
+ fullPath = ''
19
16
20
17
if currentDirectory != chgeDirectory :
21
18
os .chdir (chgeDirectory )
41
38
else :
42
39
fileSide .append (check )
43
40
44
-
45
41
if newFolder not in folderSide :
46
42
os .mkdir (newFolder )
47
43
48
44
print (f"{ newFolder } folder created successful" )
49
45
else :
50
46
print (f"{ newFolder } folder already exits" )
51
47
52
-
53
- # Differentiate the file from the extension
48
+ # Differentiate the file from the extension
54
49
55
50
for f in fileSide :
56
51
60
55
fileName = splitFileExt [0 ]
61
56
fileExt = splitFileExt [1 ]
62
57
63
- # Using regular Expression to separate the file extension from the file name
58
+ # Using regular Expression to separate the file extension from the file name
64
59
65
60
for ext in fileExt :
66
61
regExt = re .search (r'\.(\w+)' , fileExt )
67
62
newfileExt .append (regExt .group (1 ))
68
63
69
- # Making the extension to be unique in the file
64
+ # Making the extension to be unique in the file
70
65
71
66
for uni in newfileExt :
72
67
newSet .add (uni .lower ())
73
68
74
- print (newSet )
75
-
76
- print ("Here is the second set side" )
77
- print (len (newSet ))
78
-
79
- # Creating the Folder from the file extension
69
+ # Creating the Folder from the file extension
80
70
81
71
for uniqFile in newSet :
82
72
try :
92
82
for vryFile in lstDir :
93
83
94
84
if os .path .isfile (vryFile ):
95
-
96
85
fullPath = os .path .join (chgeDirectory , vryFile )
97
86
98
87
for chkFolder in folderSide :
114
103
115
104
urlLink3 = "https://www.youtube.com/watch?v=isRtFdu8sRs"
116
105
#
117
- #
106
+ #
You can’t perform that action at this time.
0 commit comments