Добавлено удаление пустой директории Moved в домашней директории

git-svn-id: http://svn.calculate.ru/calculate2/calculate-client/trunk@657 c91db197-33c1-4113-bf15-f8a5c547ca64
develop
asamoukin 16 years ago
parent 83ac62d01c
commit fdd57db718

@ -846,6 +846,7 @@ install/6intranet" %(domain,servDn,unixDN,bindDn,bindPw)
# Удаленный ресурс share
pathRemote.append((os.path.join(homeDir,"Disks"), "share"))
flagError = False
self.moveHomeDir(homeDir)
for path, res in pathRemote:
if self.isMount(path ,"cifs"):
textLine = self.execProg("umount %s"%path)
@ -975,6 +976,10 @@ install/6intranet" %(domain,servDn,unixDN,bindDn,bindPw)
else:
filesDir.append(fd)
if not filesDir or not os.path.exists("Home"):
# Удаляем пустую папку Moved
if os.path.exists(movedPath) and not os.listdir(movedPath):
os.rmdir(movedPath)
# Удалям ссылку на Moved в домашней директории
if os.path.islink(movedLink) and not os.path.exists(movedPath):
os.unlink(movedLink)
return True
@ -1010,6 +1015,7 @@ install/6intranet" %(domain,servDn,unixDN,bindDn,bindPw)
"""Переносим файлы пользователя в директорию Home/Moved если в домене"""
if self.isDomain():
return self.copyFilesToMovie(userHome)
return True
def syncUser(self, userName, userHome, sync):
"""Синхронизация пользовательских настроек"""

Loading…
Cancel
Save