Name | fr-date JSON |
Version |
2.0.7
JSON |
| download |
home_page | None |
Summary | Converts french text to python date object |
upload_time | 2024-08-06 22:26:49 |
maintainer | None |
docs_url | None |
author | None |
requires_python | >=3.8 |
license | MIT-License |
keywords |
dates
french
français
conversion
|
VCS |
|
bugtrack_url |
|
requirements |
No requirements were recorded.
|
Travis-CI |
No Travis.
|
coveralls test coverage |
No coveralls.
|
# fr-date
[![](https://img.shields.io/pypi/v/fr-date)](https://pypi.org/project/fr-date/)
[![](https://img.shields.io/pypi/dm/fr-date)](https://pypi.org/project/fr-date/)
[![](https://gitlab.com/outils-jcp/fr-date/badges/main/pipeline.svg)](https://gitlab.com/outils-jcp/fr-date/-/tree/main)
Date conversion (from numbers to letters or from letters to date object), in french.
**Installation :**
```bash
pip install fr-date
```
**Usage :**
The main method of this package is `conv()`
It takes one mandatory argument (the input to convert) and two optional boolean args :
- to_date (default = False) : set to True if you need to convert the input into a `datetime.date()` object
- litteral (default = False) : set to True if you need to convert the input into a string object only using letters
**Supported formats :**
The input can be :
- a datetime.date object
- a datetime.datetime object
- a string representing a date, in any format,
- a list of the above elements
**Examples:**
```python
from fr_date import conv
conv('14071789')
#'14 juillet 1789'
conv('17890714',to_date=True)
#datetime.date(1789, 7, 14)
conv('1789-07-14',litteral=True)
#'quatorze juillet mille sept cent quatre-vingt-neuf'
conv(['01/01/2000','2000-01-01',date(2000,1,1)])
#['1er janvier 2000','1er janvier 2000','1er janvier 2000']
```
Raw data
{
"_id": null,
"home_page": null,
"name": "fr-date",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.8",
"maintainer_email": null,
"keywords": "dates, french, fran\u00e7ais, conversion",
"author": null,
"author_email": "Thibaut_S <py@spriet.online>",
"download_url": "https://files.pythonhosted.org/packages/4f/eb/fe62689dc0c1da5b0a5e2043e0b0e1fa273978424d893d0ac7d2531dfc2e/fr_date-2.0.7.tar.gz",
"platform": null,
"description": "# fr-date\n[![](https://img.shields.io/pypi/v/fr-date)](https://pypi.org/project/fr-date/)\n[![](https://img.shields.io/pypi/dm/fr-date)](https://pypi.org/project/fr-date/)\n[![](https://gitlab.com/outils-jcp/fr-date/badges/main/pipeline.svg)](https://gitlab.com/outils-jcp/fr-date/-/tree/main)\n\nDate conversion (from numbers to letters or from letters to date object), in french.\n\n**Installation :**\n```bash\npip install fr-date\n```\n\n**Usage :**\n\nThe main method of this package is `conv()`\n\nIt takes one mandatory argument (the input to convert) and two optional boolean args :\n- to_date (default = False) : set to True if you need to convert the input into a `datetime.date()` object\n- litteral (default = False) : set to True if you need to convert the input into a string object only using letters\n\n**Supported formats :**\n\nThe input can be :\n- a datetime.date object\n- a datetime.datetime object\n- a string representing a date, in any format,\n- a list of the above elements\n\n**Examples:**\n\n```python\nfrom fr_date import conv\n\nconv('14071789')\n#'14 juillet 1789'\n\nconv('17890714',to_date=True)\n#datetime.date(1789, 7, 14)\n\nconv('1789-07-14',litteral=True)\n#'quatorze juillet mille sept cent quatre-vingt-neuf'\n\nconv(['01/01/2000','2000-01-01',date(2000,1,1)])\n#['1er janvier 2000','1er janvier 2000','1er janvier 2000']\n```\n",
"bugtrack_url": null,
"license": "MIT-License",
"summary": "Converts french text to python date object",
"version": "2.0.7",
"project_urls": {
"Bug Tracker": "https://gitlab.com/outils-jcp/fr-date/-/issues",
"Homepage": "https://gitlab.com/outils-jcp/fr-date"
},
"split_keywords": [
"dates",
" french",
" fran\u00e7ais",
" conversion"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "d884cf55cf0accd5b4a475e0d4e9b672dab3a0f39aed914a27942c98e016aee0",
"md5": "363a21fec9ddffd79aee42c7a0d6053e",
"sha256": "c2d4466c925e66fe0daedb278ff6f2ade0990147553f453342628e2913c7c8bc"
},
"downloads": -1,
"filename": "fr_date-2.0.7-py3-none-any.whl",
"has_sig": false,
"md5_digest": "363a21fec9ddffd79aee42c7a0d6053e",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.8",
"size": 4388,
"upload_time": "2024-08-06T22:26:49",
"upload_time_iso_8601": "2024-08-06T22:26:49.061322Z",
"url": "https://files.pythonhosted.org/packages/d8/84/cf55cf0accd5b4a475e0d4e9b672dab3a0f39aed914a27942c98e016aee0/fr_date-2.0.7-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "4febfe62689dc0c1da5b0a5e2043e0b0e1fa273978424d893d0ac7d2531dfc2e",
"md5": "9fa23884ee3448d079e601a0e55bf010",
"sha256": "2cd751858226e533c94b7fc146d02ad59c49363a95898ab65770256ee86f30a9"
},
"downloads": -1,
"filename": "fr_date-2.0.7.tar.gz",
"has_sig": false,
"md5_digest": "9fa23884ee3448d079e601a0e55bf010",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.8",
"size": 4136,
"upload_time": "2024-08-06T22:26:49",
"upload_time_iso_8601": "2024-08-06T22:26:49.978133Z",
"url": "https://files.pythonhosted.org/packages/4f/eb/fe62689dc0c1da5b0a5e2043e0b0e1fa273978424d893d0ac7d2531dfc2e/fr_date-2.0.7.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-08-06 22:26:49",
"github": false,
"gitlab": true,
"bitbucket": false,
"codeberg": false,
"gitlab_user": "outils-jcp",
"gitlab_project": "fr-date",
"lcname": "fr-date"
}