Skip to main content

Simplate template rensder usesd jinja2

Project description

pyrender

jinja2を使った簡単なテンプレートレンダー パッケージングの練習に利用

使い方

# pyrender --vars vars.yml template.j2

上記のように実行すると、Jinja2の形式で書かれたtempalte.j2vars.ymlの変数を用いてレンダリングします。

結果は標準出力に出力されます。

ファイル出力する機能はそのうち追加予定。

Jinja2公式ドキュメント

開発

Require

  • python3 (venvを利用)
  • docker (rpmパッケージのビルドに利用)

テスト

$ make test

make lintflake8を走らせることもできる

ビルド

$ make build

wheelパッケージ、tar.gzアーカイブ, zipアーカイブの3つがdistディレクトリ内に作成される。

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

renderj2-1.1.0.tar.gz (3.0 kB view hashes)

Uploaded Source

Built Distribution

renderj2-1.1.0-py3-none-any.whl (3.4 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page