Skip to main content

A drop-in pathlib.Path replacement with fully chainable methods.

Project description

pathchain – chainable extension of pathlib.Path

During a data science project and building modular functions with the Dataset.pipe methods provided by xarray.Dataset, a subclass of pathlib.Path was written to make a path pipeline combining Path.joinpath and Path.mkdir.

Instead of copying this class between projects, it is made available as a package on PyPI.

A similar approach can be found in the ubelt.Path class from the ubelt package, although ubelt provides a variety of different extensions to the standard library, and subclasses str instead of pathlib.Path.


Install

Install the package using pip:

pip install pathchain

Develop

  • Clone the repository (HTTPS):
git clone https://github.com/kolja-wagner/python-pathchain.git
  • Clone the repository (SSH):
git clone git@github.com:kolja-wagner/python-pathchain.git
  • Install dependencies
pip install -e .[dev,doc]

Links

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

pathchain-1.0.2.tar.gz (4.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pathchain-1.0.2-py3-none-any.whl (3.3 kB view details)

Uploaded Python 3

File details

Details for the file pathchain-1.0.2.tar.gz.

File metadata

  • Download URL: pathchain-1.0.2.tar.gz
  • Upload date:
  • Size: 4.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.14

File hashes

Hashes for pathchain-1.0.2.tar.gz
Algorithm Hash digest
SHA256 6d10ea79bbd61b12cc3ac39e9527b40a4f59ebf361524c36fa76f5603dc33dd7
MD5 766d5b2c762eb0f4e3a49f93d3027720
BLAKE2b-256 6a7a6e1b5e409676e0ac096a914e24ad55835de2545326df49a7872d55869367

See more details on using hashes here.

File details

Details for the file pathchain-1.0.2-py3-none-any.whl.

File metadata

  • Download URL: pathchain-1.0.2-py3-none-any.whl
  • Upload date:
  • Size: 3.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.14

File hashes

Hashes for pathchain-1.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 995aff511ff4cf5fdf90ac5d5ae204667740fede03d492fb2618aecad6f89250
MD5 b36e9c68fe727fdd86942edce81e4f7c
BLAKE2b-256 d60551456a050e4dc91b714013ef5304c192e7aae8bd33711eb958aed1d665a0

See more details on using hashes here.

Supported by

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