Skip to main content

rabs

Relative to absolute file names

Converts a string path that is relative to the calling file to an absolute path.

Usage:

function: real_to_abs_filename

Args: path: str ret: ret: Literal["string","path"] = "string"

from rabs import real_to_abs_filename

real_to_abs_filename(".", ret="string") # the default

real_to_abs_filename("../siblingfolder/someotherfile.py")

# or 

real_to_abs_filename("./somefile.exe", ret="path")

# returns a pathlib.Path object (python's built in library)

Why:

Python is inconsistent with respect to relative paths. This makes it as bulletproof as possible.

Metadata

Release files for rabs 0.1.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 rabs 0.1.0
File Size Uploaded
rabs-0.1.0.tar.gz 1.8 kB Details

Built distribution (wheel)

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

Total release size: 4.1 kB

Release files / rabs-0.1.0.tar.gz

Download URL rabs-0.1.0.tar.gz
Size 1.8 kB
Tags Source
SHA-256 checksum
How to use checksums
ba1a90f44af6c0157011290ce2e5dbc876d8c445fb97aef6d4b2d088062a56f1
BLAKE2b-256 checksum
How to use checksums
3310d046c74d10ace35f989c130dbee4d2ac5abd69f32669a8b1e6fd9460d734
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.7.0 CPython/3.10.12 Linux/5.10.102.1-microsoft-standard-WSL2

Release files / rabs-0.1.0-py3-none-any.whl

Download URL rabs-0.1.0-py3-none-any.whl
Size 2.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
4db96f9f9b1e0ff672d651f7f5f7ce6960d3ed11b6b70ebca7f024b20a23c503
BLAKE2b-256 checksum
How to use checksums
2b31bb1d4f27f64f6f24ac64d6e23f90fe37a85b30db1fe34afd28c3c446ed6f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.7.0 CPython/3.10.12 Linux/5.10.102.1-microsoft-standard-WSL2

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files

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