nulib/bash/tests/test-template.sh

30 lines
651 B
Bash
Executable File

#!/bin/bash
# -*- coding: utf-8 mode: sh -*- vim:sw=4:sts=4:et:ai:si:sta:fenc=utf-8
source "$(dirname -- "$0")/../src/nulib.sh" || exit 1
require: template
#NULIB_NO_DISABLE_SET_X=1
args=(
"description"
#"usage"
)
parse_args "$@"; set -- "${args[@]}"
function template__source_envs() {
eval "$("$MYDIR/_template-source_envs")"
}
cd "$MYDIR"
#template_generate_scripts \
# /tmp/awkscript /tmp/sedscript \
# template_values.env
#
#for i in awk sed; do
# etitle "$i" cat "/tmp/${i}script"
#done
template_copy_replace _template-source.txt _template-dest.txt
template_process_userfiles _template_values.env
cat _template-dest.txt