Permalink
Browse files

Switch from vendored 1.4.3 fork to gem dep on 1.4.5

  • Loading branch information...
1 parent 9ef1889 commit 2bfa04ae3f474a6eb12b9a78e82ad60b5ab86369 @jeremy jeremy committed Mar 29, 2010
View
@@ -1,3 +0,0 @@
-[submodule "lib/mail/vendor/treetop-1.4.4"]
- path = lib/mail/vendor/treetop-1.4.4
- url = git://github.com/mikel/treetop.git
View
@@ -3,6 +3,7 @@ source 'http://rubygems.org'
gem "activesupport", ">= 2.3.6.pre"
gem "tlsmail" if RUBY_VERSION <= '1.8.6'
gem "mime-types"
+gem "treetop", ">= 1.4.5"
group :test do
gem "rcov"
View
@@ -21,6 +21,7 @@ spec = Gem::Specification.new do |s|
s.add_dependency('activesupport', ">= 2.3.4")
s.add_dependency('mime-types')
+ s.add_dependency('treetop', '>= 1.4.5')
s.require_path = 'lib'
s.files = %w(README.rdoc Rakefile TODO.rdoc) + Dir.glob("lib/**/*")
View
@@ -50,7 +50,6 @@ module Mail # :doc:
require 'mail/envelope'
- require 'mail/vendor/treetop'
parsers = %w[ rfc2822_obsolete rfc2822 address_lists phrase_lists
date_time received message_ids envelope_from rfc2045
mime_version content_type content_disposition
Submodule treetop-1.4.4 deleted from b8f5e4
@@ -1,2 +0,0 @@
-# Have to vendor treetop to avoid loading polyglot
-$:.unshift "#{File.dirname(__FILE__)}/treetop-1.4.4/lib"
@@ -2,9 +2,9 @@ namespace :treetop do
desc "Pre-generate all the .treetop files into .rb files"
task :generate do
- Dir[File.join(File.dirname(__FILE__), '..', 'mail', 'parsers', '*.treetop')].each do |filename|
- `lib/mail/vendor/treetop-1.4.3/bin/tt #{filename}`
+ Dir.glob(File.expand_path('../../mail/parsers/*.treetop', __FILE__)).each do |filename|
+ `bundle exec tt #{filename}`
end
end
-
-end
+
+end
@@ -1,7 +1,6 @@
# encoding: utf-8
require 'spec_helper'
-require 'mail/vendor/treetop'
require 'treetop/compiler'
Treetop.load(File.join(MAIL_ROOT, 'lib/mail/parsers/rfc2822_obsolete'))
Treetop.load(File.join(MAIL_ROOT, 'lib/mail/parsers/rfc2822'))

0 comments on commit 2bfa04a

Please sign in to comment.