mirror of
https://github.com/home-assistant/supervisor.git
synced 2025-07-07 17:26:32 +00:00
Clean env on remove-folder (#2839)
This commit is contained in:
parent
9112f27dc0
commit
29e55d3664
@ -86,7 +86,11 @@ async def remove_folder(folder: Path, content_only: bool = False) -> None:
|
||||
del_folder = f"{folder}" + "/{,.[!.],..?}*" if content_only else f"{folder}"
|
||||
try:
|
||||
proc = await asyncio.create_subprocess_exec(
|
||||
"bash", "-c", f"rm -rf {del_folder}", stdout=asyncio.subprocess.DEVNULL
|
||||
"bash",
|
||||
"-c",
|
||||
f"rm -rf {del_folder}",
|
||||
stdout=asyncio.subprocess.DEVNULL,
|
||||
env=clean_env(),
|
||||
)
|
||||
|
||||
_, error_msg = await proc.communicate()
|
||||
|
Loading…
x
Reference in New Issue
Block a user