hugosoucycc

[ARCHIVED] Another old source code of <hugo.soucy.cc>.
Log | Files | Refs | Submodules

commit 064c02b25698987486ea53ff5e1b8d91a7b02712
parent 49ff07efe355e43e6e1597faacff897541411256
Author: Hugo Soucy <hugo@soucy.cc>
Date:   Sun, 12 Mar 2017 21:23:27 -0400

Enhance the construction of the templates array.

Diffstat:
Mfunctions/get-pandoc-templates | 5++---
1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/functions/get-pandoc-templates b/functions/get-pandoc-templates @@ -4,11 +4,10 @@ get_pandoc_templates () { templates=() - for template in $TPL_PANDOC_PATH/*; do + for template in $(find "$TPL_PANDOC_PATH/" -type f \( -name "*.html" \! -name "*.inc.html" ! -name "*-index.html" \)); do # Template name without path templatename=$(basename "$template") # Push templates names in the array templates+=(${templatename%.*}) - done - # End + done }