vim-jp / slacklog-generator

Archive generator for Slack
https://vim-jp.org/slacklog/
Creative Commons Attribution 4.0 International
26 stars 9 forks source link

split templates #119

Closed koron closed 4 years ago

koron commented 4 years ago

fix #21

とりあえずテンプレートを複数ファイルに分けられるようにしたところ。 templates/channel_per_month/ ディレクトリに置いた *.tmpl が全部読み込まれる。 起点になるファイルは常に index.tmpl

テンプレートの分け方のサンプルとして {{ template "attachement.tmpl" . }} で同名のテンプレートファイルを 2か所で利用するようにしてみた。 この時の .Messaage 相当。

koron commented 4 years ago

index と channel_index も分けたほうが統一感があるが、 さほど大きくないので今はそのままとします。