Project path strings between Windows, WSL, MSYS2/Mingw, and POSIX conventions.
Project description
pypathdub
pypathdub projects path strings between Windows, WSL, MSYS2/Mingw, and POSIX conventions.
It is for the common cross-shell case where the producer shell's path shape is not the shape a consumer binary expects.
pypathdub 'C:\work\project\data.local' --fmt python-wsl
# /mnt/c/work/project/data.local
pypathdub 'C:\work\project\data.local' --fmt python-mingw
# /c/work/project/data.local
Python
from pypathdub import normalizePathString
print(normalizePathString(r"C:\work\project\data.local", "python-mingw"))
normalize_path_string is also exported as a Python-style alias.
From a source checkout, the compatibility script is:
python .\scripts\normalize_path_string.py 'C:\work\project\data.local' --fmt python-mingw
Formats
python-winpython-winabsolutepython-nixpython-mingwpython-wslosnative-winosnative-winabsoluteosnative-nixosnative-mingwosnative-wsl
The python-* formats use Python-literal-safe separators. The osnative-* formats use the native path style for that convention.
Drive-backed Windows paths cannot be projected to plain nix; use Mingw or WSL when the drive mount is part of the target convention.
The winabsolute formats require a Windows drive or UNC authority. Relative paths and plain POSIX absolute paths are rejected instead of resolved against the current working directory.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file pypathdub-0.2.3.tar.gz.
File metadata
- Download URL: pypathdub-0.2.3.tar.gz
- Upload date:
- Size: 5.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
04fa4597a9b7861c1bfb6fde0d438c9289445d6c8d0bac25948ccbc341b12b3f
|
|
| MD5 |
0ed50960d75daafe764ee998d3dc5112
|
|
| BLAKE2b-256 |
40a5bd8e9d7d7f87ae7d2279a9d72c7a90d6bf7c20b2b7d2e53c662e85948d18
|
Provenance
The following attestation bundles were made for pypathdub-0.2.3.tar.gz:
Publisher:
publish.yml on warrentc3/pypathdub
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
pypathdub-0.2.3.tar.gz -
Subject digest:
04fa4597a9b7861c1bfb6fde0d438c9289445d6c8d0bac25948ccbc341b12b3f - Sigstore transparency entry: 1971139719
- Sigstore integration time:
-
Permalink:
warrentc3/pypathdub@f0f4f0f73b1f922295c26f59f1013935461052e6 -
Branch / Tag:
refs/tags/v0.2.3 - Owner: https://github.com/warrentc3
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@f0f4f0f73b1f922295c26f59f1013935461052e6 -
Trigger Event:
push
-
Statement type:
File details
Details for the file pypathdub-0.2.3-py3-none-any.whl.
File metadata
- Download URL: pypathdub-0.2.3-py3-none-any.whl
- Upload date:
- Size: 6.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ffc198ab861e1d484e207d43671015d01ce171bbcac8bdb0448e071a17eadd7d
|
|
| MD5 |
6a12cd0916e6a2f07e305e6314d431e6
|
|
| BLAKE2b-256 |
031e0607ac4c0a4aeb154ea8b218e0d2dda6b9b73ac43fab6e496785a891703f
|
Provenance
The following attestation bundles were made for pypathdub-0.2.3-py3-none-any.whl:
Publisher:
publish.yml on warrentc3/pypathdub
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
pypathdub-0.2.3-py3-none-any.whl -
Subject digest:
ffc198ab861e1d484e207d43671015d01ce171bbcac8bdb0448e071a17eadd7d - Sigstore transparency entry: 1971139831
- Sigstore integration time:
-
Permalink:
warrentc3/pypathdub@f0f4f0f73b1f922295c26f59f1013935461052e6 -
Branch / Tag:
refs/tags/v0.2.3 - Owner: https://github.com/warrentc3
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@f0f4f0f73b1f922295c26f59f1013935461052e6 -
Trigger Event:
push
-
Statement type: