markdown/use_cases/Rakefile in markdown_helper-2.3.0 vs markdown/use_cases/Rakefile in markdown_helper-2.4.0

- old
+ new

@@ -16,11 +16,11 @@ EOT ) dir_path = File.dirname(__FILE__) Dir.chdir(dir_path) do use_case_dirs = { - :include_files => %w/ + :include => %w/ reuse_text nest_inclusions include_markdown include_code_block include_highlighted_code @@ -31,10 +31,13 @@ include_generated_text include_with_added_comments diagnose_missing_includee diagnose_circular_includes /, + :run_irb => %w/ + run_irb + / } use_case_dirs.each_pair do |section, dir_names| # Header for section, if any dirs therein. title = StringHelper.to_title(section.to_s).sub(/ toc$/i, ' TOC') @@ -52,11 +55,11 @@ # Each use case is in a separate directory. dir_names.each do |dir_name| Dir.chdir("#{section}/#{dir_name}") do if File.exist?('includer.md') - command = 'markdown_helper include --pristine includer.md included.md' + command = "markdown_helper #{section} --pristine includer.md included.md" if backtrace_cases.include?(dir_name) # Capture the exception. command += " 2> #{dir_name}.err" # Generate the error. begin @@ -65,9 +68,13 @@ # end else system(command) end + end + if File.exist?('template.md') + command = "markdown_helper #{section} --pristine template.md markdown.md" + system(command) end command = 'markdown_helper include --pristine use_case_template.md use_case.md' system(command) title_line = File.open('use_case_template.md').grep(/^#/).first.chomp