Skip to content

Commit

Permalink
Eliminate middleman rake task. Depend directly on the metagrammar file.
Browse files Browse the repository at this point in the history
  • Loading branch information
jeremy committed Mar 7, 2010
1 parent d9d3e23 commit 89baa8a
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,12 @@ Rake::GemPackageTask.new($gemspec) do |pkg|
pkg.need_tar = true
end

task :spec => :regenerate_metagrammar
task :regenerate_metagrammar => 'lib/treetop/compiler/metagrammar.treetop' do |t|
task :spec => 'lib/treetop/compiler/metagrammar.treetop'
file 'lib/treetop/compiler/metagrammar.treetop' do |t|
unless $bootstrapped_gen_1_metagrammar
load File.join(File.dirname(__FILE__), 'lib', 'treetop', 'bootstrap_gen_1_metagrammar.rb')
load File.expand_path('../lib/treetop/bootstrap_gen_1_metagrammar.rb', __FILE__)
end

Treetop::Compiler::GrammarCompiler.new.compile(METAGRAMMAR_PATH)
end

Expand Down

0 comments on commit 89baa8a

Please sign in to comment.