aboutsummaryrefslogtreecommitdiff
path: root/doc/markdowndoc.lua
diff options
context:
space:
mode:
authormitchell <70453897+667e-11@users.noreply.github.com>2013-04-29 16:13:59 -0400
committermitchell <70453897+667e-11@users.noreply.github.com>2013-04-29 16:13:59 -0400
commit78990df4f114c45adc7fd2678ffaedf0c4124d95 (patch)
tree9e79e8f93aa07ee9384b5ddd8cc548dc3c8ea20f /doc/markdowndoc.lua
parent8407377bbe3800dbc4706f584285b7a7858efabc (diff)
downloadtextadept-78990df4f114c45adc7fd2678ffaedf0c4124d95.tar.gz
textadept-78990df4f114c45adc7fd2678ffaedf0c4124d95.zip
More code cleanup.
"local buffer = buffer" and similar optimizations are not needed since lexing the buffer is much more expensive and reaction time is limited by how fast the keyboard can submit key presses.
Diffstat (limited to 'doc/markdowndoc.lua')
-rw-r--r--doc/markdowndoc.lua4
1 files changed, 2 insertions, 2 deletions
diff --git a/doc/markdowndoc.lua b/doc/markdowndoc.lua
index 3abe6217..ea1ba26a 100644
--- a/doc/markdowndoc.lua
+++ b/doc/markdowndoc.lua
@@ -162,7 +162,7 @@ function M.start(doc)
end
h[#h + 1] = self
end
- (require 'lfs').mkdir(M.options.output_dir..'/api')
+ require('lfs').mkdir(M.options.output_dir..'/api')
local navfile = M.options.output_dir..'/api/.nav.md'
local f = io_open(navfile, 'wb')
write_nav(f, hierarchy)
@@ -174,7 +174,7 @@ function M.start(doc)
-- Write index.html.
template.nav = nav
local api_index = M.options.output_dir..'/.api_index.md'
- if (require 'lfs').attributes(api_index) then
+ if require('lfs').attributes(api_index) then
local p = io_popen('markdown -f toc -T "'..api_index..'"')
template.toc, template.main = p:read('*all'):match('^(.-\n</ul>\n)(.+)$')
p:close()