mirror of
https://github.com/Cog-Creators/Red-DiscordBot.git
synced 2025-11-07 11:48:55 -05:00
[Launcher] Set default permissions to 'lib' before updating
This commit is contained in:
parent
9b6804ea09
commit
7eabe70db5
@ -418,7 +418,7 @@ def user_pick_yes_no():
|
||||
|
||||
|
||||
def remove_readonly(func, path, excinfo):
|
||||
os.chmod(path, stat.S_IWRITE)
|
||||
os.chmod(path, 0o755)
|
||||
func(path)
|
||||
|
||||
|
||||
@ -426,12 +426,12 @@ def remove_reqs_readonly():
|
||||
"""Workaround for issue #569"""
|
||||
if not os.path.isdir(REQS_DIR):
|
||||
return
|
||||
os.chmod(REQS_DIR, stat.S_IWRITE)
|
||||
os.chmod(REQS_DIR, 0o755)
|
||||
for root, dirs, files in os.walk(REQS_DIR):
|
||||
for d in dirs:
|
||||
os.chmod(os.path.join(root, d), stat.S_IWRITE)
|
||||
os.chmod(os.path.join(root, d), 0o755)
|
||||
for f in files:
|
||||
os.chmod(os.path.join(root, f), stat.S_IWRITE)
|
||||
os.chmod(os.path.join(root, f), 0o755)
|
||||
|
||||
|
||||
def calculate_md5(filename):
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user