     all-words [ dup name>> ] { } map>assoc "words.idx" serialize-index
     all-vocabs-really [ dup vocab-name ] { } map>assoc "vocabs.idx" serialize-index ;
 
+: (generate-help-files) ( -- )
+    all-topics [ '[ _ generate-help-file ] try ] each ;
+
 : generate-help-files ( -- )
-    all-topics [ '[ _ generate-help-file ] try ] each ;
+    f recent-searches [ (generate-help-files) ] with-variable ;
 
 : generate-help ( -- )
     "docs" temp-file

! Copyright (C) 2008, 2010 Slava Pestov.
! See http://factorcode.org/license.txt for BSD license.
USING: io.encodings.utf8 io.encodings.binary
io.files io.files.temp io.directories html.streams help kernel
assocs sequences make words accessors arrays help.topics vocabs
vocabs.hierarchy help.vocabs namespaces prettyprint io
vocabs.loader serialize fry memoize unicode.case math.order

    [ drop help-stylesheet ]
    [ [ print-topic ] with-html-writer ]
    tri simple-page ;

: generate-help-file ( topic -- )
    dup topic>filename utf8 [ help>html write-xml ] with-file-writer ;

