瀏覽代碼

replace os.system(mkdir) with os.mkdir

master
myitinos 4 年之前
父節點
當前提交
9f5f5af5f8
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. +1
    -1
      clone.py

+ 1
- 1
clone.py 查看文件

@ -16,7 +16,7 @@ class Cloner:
def handleDir(self, dirPath: str):
backupDirPath = dirPath.replace(self.targetDir, self.backupDir)
if not os.path.isdir(backupDirPath):
os.system('mkdir {path}'.format(path=backupDirPath))
os.mkdir(backupDirPath)
with os.scandir(dirPath) as it:
for entry in it:
if entry.is_dir():

Loading…
取消
儲存