Nice formatting of paths
Project description
nice_path
A Python library for formatting a path in a nice way. If a path is
relative to the users home directory it will rewrite it to use ~.
Examples
from nice_path import nice_path
from pathlib import Path
nice_path("/Users/<user>/.config/something") # "~/.config/something"
nice_path("/Users/<user>/") # "~"
nice_path("/tmp") # "/tmp"
nice_path(Path("/Users/<user>/Documents")) # "~/Documents"
License
This project is licensed under the MIT License.
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
nice_path-0.1.3.tar.gz
(1.9 kB
view details)
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 nice_path-0.1.3.tar.gz.
File metadata
- Download URL: nice_path-0.1.3.tar.gz
- Upload date:
- Size: 1.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.10.7 {"installer":{"name":"uv","version":"0.10.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
eaed2808d2ce9f2e93fff30776d686b9a30588fe70d44625aa4815a559b72eb4
|
|
| MD5 |
b3d852d68e3173a6021a1c25d0512ec2
|
|
| BLAKE2b-256 |
55fbab5e59758fcebca7617526cb37a3f90ee86816dc7b0c180de602fe8da1db
|
File details
Details for the file nice_path-0.1.3-py3-none-any.whl.
File metadata
- Download URL: nice_path-0.1.3-py3-none-any.whl
- Upload date:
- Size: 3.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.10.7 {"installer":{"name":"uv","version":"0.10.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
52216e7f86c502f867ebf50f93a629aca599ac6ad44dd2a37d516df357b169b3
|
|
| MD5 |
116fca371a61a3851ecfe7fb1c00daa0
|
|
| BLAKE2b-256 |
65c8330c6571d2d9562ffcd20cb334f8bd6e7ca6520edcb811259dfc174b1ac0
|