Skip to content

Commit

Permalink
review-init creates lib/tasks for custom Rakefile, ref #921
Browse files Browse the repository at this point in the history
  • Loading branch information
kdmsnr committed Jan 14, 2018
1 parent a542176 commit 42a00b3
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion bin/review-init
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,18 @@ def generate_texmacro(dir)
end

def generate_rakefile(dir)
FileUtils.cp @review_dir + '/test/sample-book/src/Rakefile', dir
FileUtils.mkdir_p dir + '/lib/tasks'

File.open(dir + '/Rakefile', 'w') do |file|
file.write <<-EOS
Dir.glob('lib/tasks/*.rake').each do |file|
load(file)
end
EOS
end

FileUtils.cp @review_dir + '/test/sample-book/src/Rakefile',
dir + '/lib/tasks/review.rake'
end

def generate_locale(dir)
Expand Down

0 comments on commit 42a00b3

Please sign in to comment.