str2path(value)

Parse a string into a Path object.

The path will be expanded (~ becomes home directory) and resolved to an absolute path.

Parameters:

value (str) – The path string to parse.

Return type:

Path

Returns:

The parsed Path object.