Skip to main content

Mutable Pathlib

Project description

mutapath

CircleCI codecov Dependabot Status CodeFactor PyPI - Python Version PyPI GitHub License GitHub last commit

This library is for you if you are also annoyed that there is no mutable pathlib wrapper for use cases where paths are often changed. mutapath solves this by wrapping the extended pathlib library path.py and updating the encapsulated object every time the path might be changed.

>>> from mutapath import MutaPath

>>> folder = MutaPath("/home/joe/doe/folder/sub")
>>> folder
Path('/home/joe/doe/folder/sub')

>>> folder.name = top
>>> folder
Path('/home/joe/doe/folder/top')

>>> next = MutaPath("/home/joe/doe/folder/next")
>>> next
Path('/home/joe/doe/folder/next')

>>> next.rename(folder)
>>> next
Path('/home/joe/doe/folder/top')

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

mutapath-0.1.5.tar.gz (3.7 kB view hashes)

Uploaded Source

Built Distribution

mutapath-0.1.5-py3-none-any.whl (7.6 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page