doc/wipe
This commit is contained in:
parent
313cc30aec
commit
b05de437d0
1 changed files with 5 additions and 1 deletions
|
@ -69,7 +69,11 @@ def read_file_text(file_path: Path, charset: str = CHARSET) -> str:
|
||||||
|
|
||||||
|
|
||||||
def wipe(path: Path) -> None:
|
def wipe(path: Path) -> None:
|
||||||
"""Wipe provided path, whether directory or file."""
|
"""Wipe provided path, whether directory or file.
|
||||||
|
|
||||||
|
:param path: target path
|
||||||
|
:type path: Path
|
||||||
|
"""
|
||||||
try:
|
try:
|
||||||
shutil.rmtree(path)
|
shutil.rmtree(path)
|
||||||
except NotADirectoryError:
|
except NotADirectoryError:
|
||||||
|
|
Loading…
Reference in a new issue