diff --git a/rwx/fs/__init__.py b/rwx/fs/__init__.py index c91e0b8..9189778 100644 --- a/rwx/fs/__init__.py +++ b/rwx/fs/__init__.py @@ -23,7 +23,7 @@ def empty_file(path: str) -> None: def get_mount_uuid(path: str) -> str: - """Return the UUID of provided mountpoint path.""" + """Return the filesystem UUID of a mountpoint path.""" return ps.run_line( ("findmnt",), ("--noheadings",), @@ -32,7 +32,8 @@ def get_mount_uuid(path: str) -> str: ) -def get_path_mount(path: str): +def get_path_mount(path: str) -> str: + """Return the mountpoint path of an arbitrary path.""" return ps.run_line( ("stat",), ("--format", "%m"), @@ -40,11 +41,13 @@ def get_path_mount(path: str): ) -def get_path_uuid(path: str): +def get_path_uuid(path: str) -> str: + """Return the filesystem UUID of an arbitrary path.""" return get_mount_uuid(get_path_mount(path)) -def make_directory(path: str): +def make_directory(path: str) -> None: + """Make a directory (and its parents) from a path.""" os.makedirs(path, exist_ok=True)