parse drive for server
This commit is contained in:
parent
1ce95ac842
commit
f082cd6e36
|
@ -1,6 +1,6 @@
|
||||||
import os
|
import os
|
||||||
import shutil
|
import shutil
|
||||||
from add_file import addFile
|
# from add_file import addFile
|
||||||
|
|
||||||
def isVideo(path):
|
def isVideo(path):
|
||||||
basename, ext = os.path.splitext(path)
|
basename, ext = os.path.splitext(path)
|
||||||
|
@ -30,7 +30,7 @@ def spider(path, fn, **kwargs):
|
||||||
def mvFile(dirpath, filename):
|
def mvFile(dirpath, filename):
|
||||||
path = os.path.join(dirpath, filename)
|
path = os.path.join(dirpath, filename)
|
||||||
if isVideo(path) or isAudio(path):
|
if isVideo(path) or isAudio(path):
|
||||||
new_path = os.path.join("/srv2/EdgwareNTFS/RawMedia/Edgware Road SMS/", filename)
|
new_path = os.path.join("/srv/edgware/RawMedia/", filename)
|
||||||
shutil.move(path, new_path)
|
shutil.move(path, new_path)
|
||||||
return True
|
return True
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user