generator md: Capture output of markdown
This commit is contained in:
parent
14aba911bb
commit
934b88bcf0
10
qsgen2
10
qsgen2
@ -153,12 +153,14 @@ elif [[ ${generator} == "markdown" ]]; then
|
|||||||
else
|
else
|
||||||
# Usage: ${engine} ${1} - Where 1 is the file you want parsed
|
# Usage: ${engine} ${1} - Where 1 is the file you want parsed
|
||||||
function engine() {
|
function engine() {
|
||||||
|
typeset -g "$1"="$2"
|
||||||
|
|
||||||
local command="/usr/bin/markdown"
|
local command="/usr/bin/markdown"
|
||||||
local c-opts="-d -n -s"
|
local c-opts="-d -n -s"
|
||||||
|
|
||||||
local buffer=$(< <($(command) $c-opts "$1"))
|
eval "$1=\$(< <($(command) $c-opts \"${(P)1}\"))"
|
||||||
|
|
||||||
echo "${buffer}"
|
# echo "${(P)1}"
|
||||||
}
|
}
|
||||||
export file_ext=md
|
export file_ext=md
|
||||||
fi
|
fi
|
||||||
|
Loading…
Reference in New Issue
Block a user