Skip to content

Commit ec98723

Browse files
authored
Update render.sh
1 parent 6a728c9 commit ec98723

File tree

1 file changed

+9
-18
lines changed

1 file changed

+9
-18
lines changed

lib/render.sh

+9-18
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,15 @@
11
Render() {
22

3-
if read -t 0; then
4-
STDIN=$(cat -)
5-
fi
6-
7-
if [[ ${STDIN} ]]
8-
then
9-
10-
source <(echo ${STDIN} | bash-tpl)
11-
12-
else
13-
14-
if [[ ${1} ]]
15-
then
16-
17-
source <(bash-tpl ${1})
18-
19-
fi
3+
if [[ ${1} ]]
4+
then
5+
source <(bash-tpl ${1})
206

21-
fi
7+
else
8+
if read -t 0; then
9+
STDIN=$(cat -)
10+
source <(echo ${STDIN} | bash-tpl)
11+
fi
12+
fi
2213

2314
}
2415

0 commit comments

Comments
 (0)