# eds4jinja2
An easy way to reports generation with Jinja2 templates.
With Embedded Datasource Specifications inside Jinja2 templates, you can fetch the data you need on the spot.
![test](https://github.com/meaningfy-ws/eds4jinja2/workflows/test/badge.svg)
[![codecov](https://codecov.io/gh/meaningfy-ws/eds4jinja2/branch/master/graph/badge.svg)](https://codecov.io/gh/meaningfy-ws/eds4jinja2)
[![Documentation Status](https://readthedocs.org/projects/eds4jinja2/badge/?version=latest)](https://eds4jinja2.readthedocs.io/en/latest/?badge=latest)
![PyPI](https://img.shields.io/pypi/v/eds4jinja2?color=teal&label=version)
![PyPI - Status](https://img.shields.io/pypi/status/eds4jinja2)
![PyPI - Python Version](https://img.shields.io/pypi/pyversions/eds4jinja2)
![PyPI - License](https://img.shields.io/pypi/l/eds4jinja2?color=green)
![PyPI - Wheel](https://img.shields.io/pypi/wheel/eds4jinja2)
Specify the data sources in your JINJA templates directly.
```jinja2
{% set content, error = from_file(path).fetch_tree() %} \n
content: {{ content }}\n
error: {{ error }}\n
```
```jinja2
{% set content, error =
from_endpoint(endpoint).with_query(query_string).fetch_tabular() %}
content: {{ content }} \n
error: {{ error }} \n
```
# Installation
```shell script
pip install eds4jinja2
```
# Usage
[Read the docs here](https://eds4jinja2.readthedocs.io/en/latest/)
## Contributing
You are more than welcome to help expand and mature this project. We adhere to [Apache code of conduct](https://www.apache.org/foundation/policies/conduct), please follow it in all your interactions on the project.
When contributing to this repository, please first discuss the change you wish to make via issue, email, or any other method with the maintainers of this repository before making a change.
## Licence
This project is licensed under [Apache License 2.0](https://www.apache.org/licenses/LICENSE-2.0).
Powered by [Meaningfy](https://github.com/meaningfy-ws).
Raw data
{
"_id": null,
"home_page": "https://github.com/meaningfy-ws/eds4jinja2",
"name": "eds4jinja2",
"maintainer": "Eugeniu Costetchi",
"docs_url": null,
"requires_python": ">=3.8",
"maintainer_email": "costezki.eugen@gmail.com",
"keywords": "template,jinja,report,report generation,rdf,sparql,linked-data,data-source,dynamic-context",
"author": "Eugeniu Costetchi",
"author_email": "costezki.eugen@gmail.com",
"download_url": "https://files.pythonhosted.org/packages/6d/d3/ee1f3096b46883e43121058c5aa927c124374406a26216b737b45a2f2414/eds4jinja2-0.2.0.tar.gz",
"platform": "any",
"description": "# eds4jinja2\nAn easy way to reports generation with Jinja2 templates. \n\nWith Embedded Datasource Specifications inside Jinja2 templates, you can fetch the data you need on the spot. \n\n![test](https://github.com/meaningfy-ws/eds4jinja2/workflows/test/badge.svg)\n[![codecov](https://codecov.io/gh/meaningfy-ws/eds4jinja2/branch/master/graph/badge.svg)](https://codecov.io/gh/meaningfy-ws/eds4jinja2)\n[![Documentation Status](https://readthedocs.org/projects/eds4jinja2/badge/?version=latest)](https://eds4jinja2.readthedocs.io/en/latest/?badge=latest)\n\n![PyPI](https://img.shields.io/pypi/v/eds4jinja2?color=teal&label=version)\n![PyPI - Status](https://img.shields.io/pypi/status/eds4jinja2)\n![PyPI - Python Version](https://img.shields.io/pypi/pyversions/eds4jinja2)\n![PyPI - License](https://img.shields.io/pypi/l/eds4jinja2?color=green)\n![PyPI - Wheel](https://img.shields.io/pypi/wheel/eds4jinja2)\n\nSpecify the data sources in your JINJA templates directly.\n\n```jinja2\n{% set content, error = from_file(path).fetch_tree() %} \\n\ncontent: {{ content }}\\n\nerror: {{ error }}\\n\n```\n\n```jinja2\n{% set content, error =\n from_endpoint(endpoint).with_query(query_string).fetch_tabular() %}\ncontent: {{ content }} \\n\nerror: {{ error }} \\n\n```\n\n# Installation\n\n```shell script\npip install eds4jinja2\n```\n\n# Usage\n\n[Read the docs here](https://eds4jinja2.readthedocs.io/en/latest/) \n\n## Contributing\nYou are more than welcome to help expand and mature this project. We adhere to [Apache code of conduct](https://www.apache.org/foundation/policies/conduct), please follow it in all your interactions on the project. \nWhen contributing to this repository, please first discuss the change you wish to make via issue, email, or any other method with the maintainers of this repository before making a change.\n\n## Licence \nThis project is licensed under [Apache License 2.0](https://www.apache.org/licenses/LICENSE-2.0).\nPowered by [Meaningfy](https://github.com/meaningfy-ws).\n",
"bugtrack_url": null,
"license": "Apache License 2.0",
"summary": "Embed the data source specifications in your JINJA templates directly, and enjoy the dynamic data contexts.",
"version": "0.2.0",
"project_urls": {
"Homepage": "https://github.com/meaningfy-ws/eds4jinja2"
},
"split_keywords": [
"template",
"jinja",
"report",
"report generation",
"rdf",
"sparql",
"linked-data",
"data-source",
"dynamic-context"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "5dc559ec4a82e3aac338cae258c0be5e5ba0bcfecaeaf4c02d476b4afa466afa",
"md5": "fc7727b7dc7075dcb80c588d59b9a5f6",
"sha256": "f09c470bd036ed7c6e600173c8523af957382eeca29be2cbed95917c25469e99"
},
"downloads": -1,
"filename": "eds4jinja2-0.2.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "fc7727b7dc7075dcb80c588d59b9a5f6",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.8",
"size": 27549,
"upload_time": "2023-10-24T19:12:24",
"upload_time_iso_8601": "2023-10-24T19:12:24.650847Z",
"url": "https://files.pythonhosted.org/packages/5d/c5/59ec4a82e3aac338cae258c0be5e5ba0bcfecaeaf4c02d476b4afa466afa/eds4jinja2-0.2.0-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "6dd3ee1f3096b46883e43121058c5aa927c124374406a26216b737b45a2f2414",
"md5": "0c852eb7ac1915be4b7e70000cd7dcb9",
"sha256": "40310565de9db6dba890308ea95e0d20a251e85e3912355dc0b914e573f61be9"
},
"downloads": -1,
"filename": "eds4jinja2-0.2.0.tar.gz",
"has_sig": false,
"md5_digest": "0c852eb7ac1915be4b7e70000cd7dcb9",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.8",
"size": 22604,
"upload_time": "2023-10-24T19:12:26",
"upload_time_iso_8601": "2023-10-24T19:12:26.714790Z",
"url": "https://files.pythonhosted.org/packages/6d/d3/ee1f3096b46883e43121058c5aa927c124374406a26216b737b45a2f2414/eds4jinja2-0.2.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2023-10-24 19:12:26",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "meaningfy-ws",
"github_project": "eds4jinja2",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"requirements": [],
"tox": true,
"lcname": "eds4jinja2"
}