mirror of https://github.com/mpastell/Weave.jl
Bug fix: eval=false was excluding code from output
parent
3c9398e711
commit
9e5f7cb1c2
|
@ -14,11 +14,6 @@ and Sweave.
|
|||
* Capture PyPlot, Gadfly or Winston figures.
|
||||
* Supports LaTex, Pandoc and Github markdown and reStructuredText output
|
||||
|
||||
**Not implemented**
|
||||
|
||||
* Script reader
|
||||
* Inline code
|
||||
* Caching
|
||||
|
||||
## Chunk options
|
||||
|
||||
|
|
|
@ -182,7 +182,12 @@ function run(parsed)
|
|||
merge!(chunk, options)
|
||||
delete!(chunk, :options)
|
||||
|
||||
chunk[:eval] || (chunk[:result] = ""; continue) #Do nothing if eval is false
|
||||
if !chunk[:eval]
|
||||
chunk[:result] = ""
|
||||
parsed[i] = copy(chunk)
|
||||
i += 1
|
||||
continue #Do nothing if eval is false
|
||||
end
|
||||
|
||||
report.fignum = 1
|
||||
report.cur_result = ""
|
||||
|
|
|
@ -56,7 +56,7 @@ function format_codechunk(chunk, formatdict)
|
|||
|
||||
if !chunk[:eval]
|
||||
if chunk[:echo]
|
||||
result = "$(formatdict[:codestart])$(chunk[:content])$(formatdict[:codeend])"
|
||||
result = "$(formatdict[:codestart])$(chunk[:content])\n$(formatdict[:codeend])"
|
||||
return result
|
||||
else
|
||||
r = ""
|
||||
|
|
Loading…
Reference in New Issue