Provides a directory with all its parent directories, if it does not yet exist
Project description
provide_directory
Function to create the given path, including potential parent directories. Writes to the provided sink (e.g. print
) whether the directory was created or whether it already existed.
Dependencies
None
Usage
from pathlib import Path
from provide_dir import provide_dir
needed_path = Path("/path/to/directory/with/subdirectories")
provide_dir(needed_path, print)
Installation
Pip
pip install provide_dir
Developer's Installation
You can clone the repository and install it with pip install -e /path/to/local/repository
.
Test dependencies
To run the tests you will need
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
provide_dir-0.1.2.tar.gz
(4.0 kB
view hashes)
Built Distribution
Close
Hashes for provide_dir-0.1.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 214f7c00d3962aa41fa2e8b36451197823d5ea2a0526c085376fb3687bdc5fa1 |
|
MD5 | b6a5cf6f4ef5cbd433c363bf1497dcef |
|
BLAKE2b-256 | 4981d7ebfd2aab814108fa67676bf8277f4c2861b4ff63cd07e46f9e9125069d |