Metadata-Version: 2.1
Name: pathbase
Version: 0.0.1
Summary: Lightweight bidirectional filesystem path templates for Python.
Author-email: Ryan Galloway <ryan@rsgalloway.com>
License: BSD-3-Clause
Keywords: filesystem,path,template,parsing,formatting,pipeline,vfx
Classifier: Development Status :: 2 - Pre-Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: BSD License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3 :: Only
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: 3.14
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Classifier: Topic :: Utilities
Requires-Python: >=3.8
Description-Content-Type: text/markdown
Provides-Extra: dev
Requires-Dist: pytest; extra == "dev"
Requires-Dist: flake8==7.1.1; extra == "dev"
Requires-Dist: mccabe==0.7.0; extra == "dev"
Requires-Dist: isort==5.13.2; extra == "dev"
Requires-Dist: black==24.8.0; extra == "dev"
Provides-Extra: test
Requires-Dist: pytest; extra == "test"

# pathbase

`pathbase` is a lightweight, dependency-free Python library for bidirectional
filesystem path templates.

## Status

This repository is currently a minimal v0 scaffold.

## Planned Direction

The core idea is a single template that can both format and parse paths:

```python
from pathbase import Template

template = Template(
    "/shows/{show}/shots/{sequence}/{shot}/"
    "{shot}_{task}_v{version:03d}.{frame:04d}.exr"
)

path = template.apply_fields(
    show="bigbuckbunny",
    sequence="bbb",
    shot="0150",
    task="plate",
    version=1,
    frame=1001,
)

fields = template.parse(path)
```

Pathbase is intended to remain focused on path formatting and parsing rather
than environment loading, filesystem mutation, or pipeline orchestration.

## Installation

```bash
pip install -U pathbase
```
