Skip to main content

getpath

Helps with pathing in python scripts. Inspired by pathlib.

IMPORTING

from getpaths import getpath

USING CURRENT FILE PATH

current_dir = getpath() # current file's path

USER-SPECIFIED PATH

custom_dir = getpath('a','b',custom=True)
print(custom_dir)
# /a/b

ADD FILES

custom_dir/'example.txt'
# /a/b/example.txt

custom_dir.add('/a/example.txt')
# /a/b/example.txt

GO UP THE DIRECTORY

custom_dir = getpath('a','b',custom=True)

custom_dir/'..'
# /a

custom_dir.add('..')
# /a

custom_dir.up(1)
# /a

LIST EXISTING FILES AND FOLDERS

custom_dir.ls()
# /a/b/example.txt
# throws error if path does not exist

Metadata

Release files for getpaths 1.0.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for getpaths 1.0.0
File Size Uploaded Provenance Actions
getpaths-1.0.0.tar.gz 4.5 kB Without provenance Details for getpaths-1.0.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for getpaths 1.0.0
File Interpreter ABI Platform Actions
getpaths-1.0.0-py3-none-any.whl Python 3 none any Details for getpaths-1.0.0-py3-none-any.whl

Total release size: 9.0 kB

Release files / getpaths-1.0.0.tar.gz

Download URL getpaths-1.0.0.tar.gz
Size 4.5 kB
Tags Source
SHA-256 checksum
How to use checksums
785fd929d8b7393c84349731f2dcc942ca029d4f1c5ab1d49d771be0f090e736
BLAKE2b-256 checksum
How to use checksums
e9ffba4e7f306746ff8b6c12a83f64c22c96c2991c07362e0fc267534214a8fb
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.4.1 importlib_metadata/4.6.0 pkginfo/1.7.0 requests/2.21.0 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.0

Release files / getpaths-1.0.0-py3-none-any.whl

Download URL getpaths-1.0.0-py3-none-any.whl
Size 4.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
2015dabeac9e6ab13555aa656c62255bbd3286ab5236a0012ffc72a981b79303
BLAKE2b-256 checksum
How to use checksums
06e436d533889a4da19ddd694f2efc1b8649a0ec724dc1f3ae0923ec510b9052
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.4.1 importlib_metadata/4.6.0 pkginfo/1.7.0 requests/2.21.0 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.0

Security for getpaths 1.0.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page