Commit 60ebefa3 authored by grisel-davy's avatar grisel-davy

.lower sur les partition par lettres

parent 33a826da
......@@ -28,7 +28,7 @@ def reconfigure(api_client):
error = False
os.chdir("/home-adh")
for user in users:
home = '/home-adh/{}/{}'.format(user['pseudo'][0],user['pseudo'])
home = '/home-adh/{}/{}'.format(user['pseudo'][0].lower(),user['pseudo'])
uid = user['uid']
gid = user['gid']
......@@ -53,8 +53,8 @@ def reconfigure(api_client):
# Simlink
link = '/home-adh/{}'.format(user['pseudo'])
if not os.path.islink(link):
link2 = '{}'.format(user['pseudo'].lower())
home2 = '{}/{}'.format(user['pseudo'][0].lower(),user['pseudo'].lower())
link2 = '{}'.format(user['pseudo'])
home2 = '{}/{}'.format(user['pseudo'][0].lower(),user['pseudo'])
os.symlink(home2, link2)
if not ((os.path.exists(home+'/Mail') or os.path.islink(home + '/Mail')) and (os.path.exists(home+'/OwnCloud') or os.path.islink(home + '/OwnCloud')) and os.path.islink(link)):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment