Python Utilities & Basalam Micro-Services SDK
Project description
Requirements
- Python 3.6+
Installation & Upgrade
pip install basalam.backbone-translation
Usage
from backbone_translation.translator import Translator
translator = Translator({
"messages.greeting" : "Bonjour {name}"
})
# OR translator = Translator.from_json_file("path_to_json_file")
translator.translate("messages.greeting", name="Mojtabaa")
# Bonjour Mojtabaa
Testing
# install pytest
pip install pytest
# run tests
python -m pytest
Changelog
- 0.0.2 added from_json_file method
- 0.0.3 Now build and push are done using gitlab-ci
- 0.0.4 new
exists(phrase: str) -> boolmethod - 0.1.0 added utf-8 encoding thanks to alimohammayali@gmail.com
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 basalam_backbone_translation-1.0.0.tar.gz.
File metadata
- Download URL: basalam_backbone_translation-1.0.0.tar.gz
- Upload date:
- Size: 2.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.0.1 CPython/3.9.21
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a345cd4c84364802075801cf960b38debd41d197d03ac2680867386df7ac4018
|
|
| MD5 |
3f4b88376bc1912d27e0e6fc23e7e1fa
|
|
| BLAKE2b-256 |
76499c2315c2b4db2062ed2632aefb5501cee03fb209cf0544dc8ad12143925c
|
File details
Details for the file basalam.backbone_translation-1.0.0-py3-none-any.whl.
File metadata
- Download URL: basalam.backbone_translation-1.0.0-py3-none-any.whl
- Upload date:
- Size: 4.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.0.1 CPython/3.9.21
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5f1d55a623f420ac59f995daf3bfe31c3a0a0c3dbf4ba7183dcfaabbc2724eb4
|
|
| MD5 |
36a4132a61f9227e1aec18d8ffce7c7b
|
|
| BLAKE2b-256 |
40329d0c605505d3e68f398e095cf6d78b0742f00e70bef6016368ac2860ea62
|