Handy decorators for converting parameters
Project description
parameter-decorators
Handy decorators for converting parameters
Installation
Install the last released version using pip
:
python3 -m pip install -U parameter-decorators
Or install the latest version from sources:
git clone git@github.com:matan1008/parameter-decorators.git
cd parameter-decorators
python3 -m pip install -U -e .
Usage
The package contains several handy decorators, lets give an example with str_to_path
:
from parameter_decorators import str_to_path
@str_to_path('input_file')
def get_parent(input_file):
return input_file.parent
# Will print "/usr/bin"
print(get_parent('/usr/bin/python'))
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
File details
Details for the file parameter_decorators-0.0.2.tar.gz
.
File metadata
- Download URL: parameter_decorators-0.0.2.tar.gz
- Upload date:
- Size: 41.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 499ec96e71394705be9e3eeb28542aab4875694042516c31051d5dcb0488028e |
|
MD5 | b76438b32bcebb7052d94653dada592a |
|
BLAKE2b-256 | 40b903b5e409930cb4cff0f25f6f3199145f4319a88d5f9be7ee17882359f72d |
File details
Details for the file parameter_decorators-0.0.2-py2.py3-none-any.whl
.
File metadata
- Download URL: parameter_decorators-0.0.2-py2.py3-none-any.whl
- Upload date:
- Size: 30.4 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8f89280356f7ea983725bf47534c22171fbd10a13d98159f44f3c55ba8ae73e7 |
|
MD5 | a6356fb4ab68b754d9b8e65e8de3021d |
|
BLAKE2b-256 | de7b1fa9000dbe427745af3eda3f1690d86e2161b6cfcd56b16cd76008a8f2c5 |