noodall-core 0.6.3 → 0.7.2

Sign up to get free protection for your applications and to get access to all the features.
data/Gemfile CHANGED
@@ -1,19 +1,14 @@
1
1
  source "http://rubygems.org"
2
2
 
3
- gem 'mongo_mapper', '~> 0.8.6'
4
- gem 'ramdiv-mongo_mapper_acts_as_tree', '~> 0.1.1'
5
- gem 'mm-multi-parameter-attributes', '~> 0.1.1'
6
- gem 'canable', '~> 0.1.1'
7
- gem 'ruby-stemmer'
8
- gem 'i18n'
3
+ gemspec
9
4
 
10
5
  group :development do
11
- gem 'jeweler', '~> 1.4.0'
12
- gem "rspec", "~> 2.0.0.beta.22"
6
+ gem "rspec", "~> 2.0.0"
13
7
  gem "database_cleaner", "~> 0.5.2"
14
8
  gem "factory_girl", "~> 1.3.2"
15
9
  gem "faker", "~> 0.3.1"
16
10
  gem "rake"
17
11
  gem 'bson_ext', '~> 1.3.0'
12
+ gem 'SystemTimer', '~> 1.2.0'
18
13
  end
19
14
 
data/Rakefile CHANGED
@@ -1,28 +1,8 @@
1
1
  require "bundler"
2
2
  Bundler.setup(:default, :development)
3
- require "rspec/core/rake_task"
4
-
5
- begin
6
- require 'jeweler'
7
- Jeweler::Tasks.new do |gem|
8
- gem.name = "noodall-core"
9
- gem.summary = %Q{Core data objects for Noodall}
10
- gem.description = %Q{Core data objects for Noodall}
11
- gem.email = "steve@wearebeef.co.uk"
12
- gem.homepage = "http://github.com/beef/noodall-core"
13
- gem.authors = ["Steve England"]
14
- gem.add_dependency('mongo_mapper', '~> 0.8.6')
15
- gem.add_dependency('ramdiv-mongo_mapper_acts_as_tree', '~> 0.1.1')
16
- gem.add_dependency('mm-multi-parameter-attributes', '~> 0.1.1')
17
- gem.add_dependency('canable', '0.1.1')
18
- gem.add_dependency('ruby-stemmer')
3
+ Bundler::GemHelper.install_tasks
19
4
 
20
- # gem is a Gem::Specification... see http://www.rubygems.org/read/chapter/20 for additional settings
21
- end
22
- Jeweler::GemcutterTasks.new
23
- rescue LoadError
24
- puts "Jeweler (or a dependency) not available. Install it with: gem install jeweler"
25
- end
5
+ require "rspec/core/rake_task"
26
6
 
27
7
  RSpec::Core::RakeTask.new(:spec)
28
8
 
@@ -30,8 +10,6 @@ RSpec::Core::RakeTask.new(:rcov) do |spec|
30
10
  spec.rcov = true
31
11
  end
32
12
 
33
- task :spec => :check_dependencies
34
-
35
13
  task :default => :spec
36
14
 
37
15
 
data/lib/noodall-core.rb CHANGED
@@ -2,6 +2,7 @@ require 'mongo_mapper'
2
2
  require 'mongo_mapper_acts_as_tree'
3
3
  require 'canable'
4
4
  require 'mm-multi-parameter-attributes'
5
+ require 'versionable'
5
6
  require 'noodall/global_update_time'
6
7
  require 'noodall/search'
7
8
  require 'noodall/tagging'
@@ -14,7 +15,6 @@ require 'noodall/node'
14
15
  # Ruby 1.8 Compatibilty
15
16
  class Object
16
17
  unless defined?(define_singleton_method)
17
- puts "Redefining 'define_singleton_method' to work with Ruby1.8"
18
18
  def define_singleton_method(sym, &block)
19
19
  singleton_class.instance_eval do
20
20
  define_method sym, block
@@ -0,0 +1,5 @@
1
+ module Noodall
2
+ module Core
3
+ VERSION = "0.7.2"
4
+ end
5
+ end
@@ -1,22 +1,22 @@
1
1
  module Noodall
2
2
  module GlobalUpdateTime
3
+ extend ActiveSupport::Concern
4
+
3
5
  class Stamp
4
6
  def self.read
5
7
  Rails.cache.read('global_update_time') if defined?(Rails)
6
8
  end
7
-
9
+
8
10
  def self.update!
9
11
  Rails.cache.write('global_update_time', Time.zone.now.utc) if defined?(Rails)
10
12
  end
11
13
  end
12
-
13
- def self.configure(model)
14
- model.class_eval do
15
- after_save :global_updated!
16
- after_destroy :global_updated!
17
- end
14
+
15
+ included do
16
+ after_save :global_updated!
17
+ after_destroy :global_updated!
18
18
  end
19
-
19
+
20
20
  module InstanceMethods
21
21
  # Cache the updated time
22
22
  def global_updated!
@@ -1,18 +1,19 @@
1
1
  module Noodall
2
2
  module Indexer
3
- def self.configure(model)
4
- model.class_eval do
5
- cattr_accessor :indexes
6
- end
7
- model.indexes = []
3
+ extend ActiveSupport::Concern
4
+
5
+ included do
6
+ cattr_accessor :indexes
7
+ self.indexes = []
8
8
  end
9
+
9
10
  module ClassMethods
10
11
  def ensure_index(*args)
11
- indexes << args
12
+ self.indexes << args
12
13
  end
13
14
 
14
15
  def create_indexes!
15
- indexes.each do |args|
16
+ self.indexes.each do |args|
16
17
  puts "Creating index #{args.inspect}"
17
18
  collection.create_index(*args)
18
19
  end
data/lib/noodall/node.rb CHANGED
@@ -28,6 +28,8 @@ module Noodall
28
28
  timestamps!
29
29
  userstamps!
30
30
 
31
+ enable_versioning
32
+
31
33
  alias_method :keywords, :tag_list
32
34
  alias_method :keywords=, :tag_list=
33
35
 
@@ -37,9 +39,7 @@ module Noodall
37
39
  acts_as_tree :order => "position", :search_class => Noodall::Node
38
40
 
39
41
  # if there are any children that are not of an allowed template, error
40
- validates_true_for :template,
41
- :message => "cannot be changed as sub content is not allowed in this template",
42
- :logic => lambda { |args| !_type_changed? or children.empty? or children.select{|c| !self._type.constantize.template_classes.include?(c.class)}.empty? }
42
+ validate :child_templates_allowed
43
43
 
44
44
  scope :published, lambda { where(:published_at => { :$lte => current_time }, :published_to => { :$gte => current_time }) }
45
45
 
@@ -65,6 +65,10 @@ module Noodall
65
65
  !published_at.nil? and published_at <= current_time and (published_to.nil? or published_to >= current_time)
66
66
  end
67
67
 
68
+ def has_draft?
69
+ !version_at(:latest).nil? && version_at(:latest).pos != version_number
70
+ end
71
+
68
72
  def pending?
69
73
  published_at.nil? or published_at >= current_time
70
74
  end
@@ -91,17 +95,17 @@ module Noodall
91
95
  switch_position(sibling)
92
96
  end
93
97
 
94
- def run_callbacks(kind, options = {}, &block)
95
- self.class.send("#{kind}_callback_chain").run(self, options, &block)
96
- self.embedded_associations.each do |association|
97
- self.send(association.name).each do |document|
98
- document.run_callbacks(kind, options, &block)
99
- end
100
- end
101
- self.embedded_keys.each do |key|
102
- self.send(key.name).run_callbacks(kind, options, &block) unless self.send(key.name).nil?
103
- end
104
- end
98
+ #def run_callbacks(kind, options = {}, &block)
99
+ #self.class.send("#{kind}_callback_chain").run(self, options, &block)
100
+ #self.embedded_associations.each do |association|
101
+ #self.send(association.name).each do |document|
102
+ #document.run_callbacks(kind, options, &block)
103
+ #end
104
+ #end
105
+ #self.embedded_keys.each do |key|
106
+ #self.send(key.name).run_callbacks(kind, options, &block) unless self.send(key.name).nil?
107
+ #end
108
+ #end
105
109
 
106
110
  def slots
107
111
  slots = []
@@ -302,6 +306,13 @@ module Noodall
302
306
  self.name = self.title if self.name.blank?
303
307
  end
304
308
 
309
+ # Validate that child templates (set via sub_templates) are allowed if the template is changed
310
+ def child_templates_allowed
311
+ unless !_type_changed? or children.empty?
312
+ errors.add(:base, "Template cannot be changed as sub content is not allowed in this template") unless children.select{|c| !self._type.constantize.template_classes.include?(c.class)}.empty?
313
+ end
314
+ end
315
+
305
316
  class << self
306
317
  @@slots = []
307
318
 
@@ -320,9 +331,10 @@ module Noodall
320
331
  define_singleton_method("#{slot}_slots") do |count|
321
332
  instance_variable_set("@#{slot}_slots_count", count)
322
333
  count.times do |i|
323
- key "#{slot}_slot_#{i}", Noodall::Component
324
- validates_each "#{slot}_slot_#{i}", :logic => lambda { |args| errors.add("#{slot}_slot_#{i}", "is not allowed in a #{slot} slot") unless send("#{slot}_slot_#{i}").nil? or Noodall::Component.positions_classes(slot).include?(send("#{slot}_slot_#{i}").class) } # TODO: Nicer message please
325
- validates_associated "#{slot}_slot_#{i}"
334
+ slot_sym = "#{slot}_slot_#{i}".to_sym
335
+ key slot_sym, Noodall::Component
336
+ validates slot_sym, :slot => { :slot_type => slot }
337
+ validates_associated slot_sym
326
338
  end
327
339
  end
328
340
  define_singleton_method("#{slot}_slots_count") { instance_variable_get("@#{slot}_slots_count") }
@@ -403,6 +415,12 @@ module Noodall
403
415
  end
404
416
  end
405
417
 
418
+ class SlotValidator < ActiveModel::EachValidator
419
+ def validate_each(record, attribute, value)
420
+ record.errors[attribute] << "cannnot contain #{value.class.name.humanize}" unless value.nil? or Noodall::Component.positions_classes(options[:slot_type]).include?(value.class)
421
+ end
422
+ end
423
+
406
424
  end
407
425
 
408
426
  end
@@ -1,16 +1,17 @@
1
1
  module Noodall
2
2
  module Search
3
+ extend ActiveSupport::Concern
4
+
3
5
  STOPWORDS = ["all","also","and","any","are","been","but","can", "cannot", "cant","else","etc","for","from","get", "give","had","has","hasnt","have","inc","into","its","not","put","see","this","too","via","was","were","when","with"]
4
6
 
5
- def self.configure(model)
7
+
8
+ included do
6
9
  require 'lingua/stemmer'
7
10
 
8
- model.class_eval do
9
- key :_keywords, Array, :index => true
10
- attr_accessor :relevance
11
+ key :_keywords, Array, :index => true
12
+ attr_accessor :relevance
11
13
 
12
- before_save :_update_keywords
13
- end
14
+ before_save :_update_keywords
14
15
  end
15
16
 
16
17
  module ClassMethods
@@ -41,7 +42,7 @@ module Noodall
41
42
  options = plucky_query.options.to_hash
42
43
 
43
44
  # Extract words from the query and clean up
44
- words = query.to_s.downcase.split(/\W/) - STOPWORDS
45
+ words = query.downcase.split(/\W/) - STOPWORDS
45
46
  words.reject!{|w| w.length < 3}
46
47
 
47
48
  # add stemmed words to the array of words
@@ -1,11 +1,11 @@
1
1
  module Noodall
2
2
  module Tagging
3
- def self.configure(model)
4
- model.class_eval do
5
- key :tags, Array, :index => true
6
- end
3
+ extend ActiveSupport::Concern
4
+
5
+ included do
6
+ key :tags, Array, :index => true
7
7
  end
8
-
8
+
9
9
  module ClassMethods
10
10
  def tag_cloud(options = {})
11
11
  return [] if self.count == 0 # Don't bother if there is nothing in this collection
@@ -20,7 +20,7 @@ module Noodall
20
20
  []
21
21
  end
22
22
  end
23
-
23
+
24
24
  def tag_cloud_map
25
25
  "function(){" +
26
26
  "this.tags.forEach(" +
@@ -29,7 +29,7 @@ module Noodall
29
29
  "}" +
30
30
  ")}"
31
31
  end
32
-
32
+
33
33
  def tag_cloud_reduce
34
34
  "function( key , values ){" +
35
35
  "var total = 0;" +
@@ -40,24 +40,24 @@ module Noodall
40
40
  "}"
41
41
  end
42
42
  end
43
-
43
+
44
44
  module InstanceMethods
45
45
  def tag_list=(string)
46
46
  self.tags = string.to_s.split(',').map{ |t| t.strip.downcase }.reject(&:blank?).compact.uniq
47
47
  end
48
-
48
+
49
49
  def tag_list
50
50
  tags.join(', ')
51
51
  end
52
-
52
+
53
53
  def related(options ={})
54
54
  self.class.all(options.merge({:_id => {'$ne' => self._id}, :tags => /(#{self.tags.join('|')})/i}))
55
55
  end
56
56
  end
57
-
57
+
58
58
  class Tag
59
59
  attr_reader :name, :count
60
-
60
+
61
61
  def initialize(name, count)
62
62
  @name = name
63
63
  @count = count.to_i
@@ -0,0 +1,22 @@
1
+ # This is a duplicate of mm-versionable lib/versionable/models/version.rb
2
+ # with indexing turned off so it doesn't complian when included that there
3
+ # is no db connection
4
+ class Version
5
+ include MongoMapper::Document
6
+
7
+ key :data, Hash
8
+ key :date, Time
9
+ key :pos, Integer#, :index => true
10
+ key :doc_id, String#, :index => true
11
+ key :message, String
12
+ key :updater_id, String
13
+
14
+ def content(key)
15
+ cdata = self.data[key]
16
+ if cdata.respond_to?(:join)
17
+ cdata.join(" ")
18
+ else
19
+ cdata
20
+ end
21
+ end
22
+ end
data/noodall-core.gemspec CHANGED
@@ -1,83 +1,28 @@
1
- # Generated by jeweler
2
- # DO NOT EDIT THIS FILE DIRECTLY
3
- # Instead, edit Jeweler::Tasks in Rakefile, and run the gemspec command
4
1
  # -*- encoding: utf-8 -*-
2
+ require File.expand_path("../lib/noodall/core/version", __FILE__)
5
3
 
6
4
  Gem::Specification.new do |s|
7
- s.name = %q{noodall-core}
8
- s.version = "0.6.3"
9
-
10
- s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
5
+ s.name = "noodall-core"
6
+ s.version = Noodall::Core::VERSION
7
+ s.platform = Gem::Platform::RUBY
8
+
11
9
  s.authors = ["Steve England"]
12
- s.date = %q{2011-06-03}
13
- s.description = %q{Core data objects for Noodall}
14
- s.email = %q{steve@wearebeef.co.uk}
15
- s.extra_rdoc_files = [
16
- "LICENSE",
17
- "README.rdoc"
18
- ]
19
- s.files = [
20
- ".document",
21
- ".gitignore",
22
- ".rvmrc",
23
- "Gemfile",
24
- "LICENSE",
25
- "README.rdoc",
26
- "Rakefile",
27
- "VERSION",
28
- "lib/noodall-core.rb",
29
- "lib/noodall/component.rb",
30
- "lib/noodall/global_update_time.rb",
31
- "lib/noodall/indexer.rb",
32
- "lib/noodall/node.rb",
33
- "lib/noodall/permalink.rb",
34
- "lib/noodall/search.rb",
35
- "lib/noodall/site.rb",
36
- "lib/noodall/tagging.rb",
37
- "noodall-core.gemspec",
38
- "spec/component_spec.rb",
39
- "spec/factories/component.rb",
40
- "spec/factories/node.rb",
41
- "spec/node_spec.rb",
42
- "spec/site_map_spec.rb",
43
- "spec/spec_helper.rb"
44
- ]
45
- s.homepage = %q{http://github.com/beef/noodall-core}
46
- s.rdoc_options = ["--charset=UTF-8"]
47
- s.require_paths = ["lib"]
48
- s.rubygems_version = %q{1.6.2}
49
- s.summary = %q{Core data objects for Noodall}
50
- s.test_files = [
51
- "spec/component_spec.rb",
52
- "spec/factories/component.rb",
53
- "spec/factories/node.rb",
54
- "spec/node_spec.rb",
55
- "spec/site_map_spec.rb",
56
- "spec/spec_helper.rb"
57
- ]
58
-
59
- if s.respond_to? :specification_version then
60
- s.specification_version = 3
61
-
62
- if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
63
- s.add_runtime_dependency(%q<mongo_mapper>, ["~> 0.8.6"])
64
- s.add_runtime_dependency(%q<ramdiv-mongo_mapper_acts_as_tree>, ["~> 0.1.1"])
65
- s.add_runtime_dependency(%q<mm-multi-parameter-attributes>, ["~> 0.1.1"])
66
- s.add_runtime_dependency(%q<canable>, ["= 0.1.1"])
67
- s.add_runtime_dependency(%q<ruby-stemmer>, [">= 0"])
68
- else
69
- s.add_dependency(%q<mongo_mapper>, ["~> 0.8.6"])
70
- s.add_dependency(%q<ramdiv-mongo_mapper_acts_as_tree>, ["~> 0.1.1"])
71
- s.add_dependency(%q<mm-multi-parameter-attributes>, ["~> 0.1.1"])
72
- s.add_dependency(%q<canable>, ["= 0.1.1"])
73
- s.add_dependency(%q<ruby-stemmer>, [">= 0"])
74
- end
75
- else
76
- s.add_dependency(%q<mongo_mapper>, ["~> 0.8.6"])
77
- s.add_dependency(%q<ramdiv-mongo_mapper_acts_as_tree>, ["~> 0.1.1"])
78
- s.add_dependency(%q<mm-multi-parameter-attributes>, ["~> 0.1.1"])
79
- s.add_dependency(%q<canable>, ["= 0.1.1"])
80
- s.add_dependency(%q<ruby-stemmer>, [">= 0"])
81
- end
10
+ s.email = ['steve@wearebeef.co.uk']
11
+ s.homepage = "http://github.com/beef/noodall-core"
12
+ s.summary = "Core data objects for Noodall"
13
+ s.description = "Core data objects for Noodall"
14
+
15
+ s.required_rubygems_version = ">= 1.3.6"
16
+
17
+ s.add_dependency(%q<mongo_mapper>, ["~> 0.9.0"])
18
+ s.add_dependency(%q<ramdiv-mongo_mapper_acts_as_tree>, ["~> 0.1.1"])
19
+ s.add_dependency(%q<mm-multi-parameter-attributes>, ["~> 0.2.1"])
20
+ s.add_dependency(%q<canable>, ["= 0.1.1"])
21
+ s.add_dependency(%q<mm-versionable>, ["= 0.2.4"])
22
+ s.add_dependency(%q<ruby-stemmer>, [">= 0"])
23
+
24
+ s.files = `git ls-files`.split("\n")
25
+ s.executables = `git ls-files`.split("\n").map{|f| f =~ /^bin\/(.*)/ ? $1 : nil}.compact
26
+ s.require_path = 'lib'
82
27
  end
83
28
 
data/spec/node_spec.rb CHANGED
@@ -464,4 +464,13 @@ describe Noodall::Node do
464
464
  @page.save!
465
465
  end
466
466
  end
467
+
468
+ it "should know if newer (draft) versions are avaiable" do
469
+ @page = Factory(:page)
470
+ @page.has_draft?.should be(false)
471
+ @page.title = "Some title"
472
+ @page.save_version
473
+ @page.reload
474
+ @page.has_draft?.should == true
475
+ end
467
476
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: noodall-core
3
3
  version: !ruby/object:Gem::Version
4
- hash: 1
4
+ hash: 7
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
- - 6
9
- - 3
10
- version: 0.6.3
8
+ - 7
9
+ - 2
10
+ version: 0.7.2
11
11
  platform: ruby
12
12
  authors:
13
13
  - Steve England
@@ -15,29 +15,27 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2011-06-03 00:00:00 +01:00
18
+ date: 2011-06-17 00:00:00 +01:00
19
19
  default_executable:
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency
22
- prerelease: false
23
- type: :runtime
24
- requirement: &id001 !ruby/object:Gem::Requirement
22
+ version_requirements: &id001 !ruby/object:Gem::Requirement
25
23
  none: false
26
24
  requirements:
27
25
  - - ~>
28
26
  - !ruby/object:Gem::Version
29
- hash: 51
27
+ hash: 59
30
28
  segments:
31
29
  - 0
32
- - 8
33
- - 6
34
- version: 0.8.6
35
- name: mongo_mapper
36
- version_requirements: *id001
37
- - !ruby/object:Gem::Dependency
30
+ - 9
31
+ - 0
32
+ version: 0.9.0
38
33
  prerelease: false
34
+ requirement: *id001
39
35
  type: :runtime
40
- requirement: &id002 !ruby/object:Gem::Requirement
36
+ name: mongo_mapper
37
+ - !ruby/object:Gem::Dependency
38
+ version_requirements: &id002 !ruby/object:Gem::Requirement
41
39
  none: false
42
40
  requirements:
43
41
  - - ~>
@@ -48,28 +46,28 @@ dependencies:
48
46
  - 1
49
47
  - 1
50
48
  version: 0.1.1
51
- name: ramdiv-mongo_mapper_acts_as_tree
52
- version_requirements: *id002
53
- - !ruby/object:Gem::Dependency
54
49
  prerelease: false
50
+ requirement: *id002
55
51
  type: :runtime
56
- requirement: &id003 !ruby/object:Gem::Requirement
52
+ name: ramdiv-mongo_mapper_acts_as_tree
53
+ - !ruby/object:Gem::Dependency
54
+ version_requirements: &id003 !ruby/object:Gem::Requirement
57
55
  none: false
58
56
  requirements:
59
57
  - - ~>
60
58
  - !ruby/object:Gem::Version
61
- hash: 25
59
+ hash: 21
62
60
  segments:
63
61
  - 0
62
+ - 2
64
63
  - 1
65
- - 1
66
- version: 0.1.1
67
- name: mm-multi-parameter-attributes
68
- version_requirements: *id003
69
- - !ruby/object:Gem::Dependency
64
+ version: 0.2.1
70
65
  prerelease: false
66
+ requirement: *id003
71
67
  type: :runtime
72
- requirement: &id004 !ruby/object:Gem::Requirement
68
+ name: mm-multi-parameter-attributes
69
+ - !ruby/object:Gem::Dependency
70
+ version_requirements: &id004 !ruby/object:Gem::Requirement
73
71
  none: false
74
72
  requirements:
75
73
  - - "="
@@ -80,12 +78,28 @@ dependencies:
80
78
  - 1
81
79
  - 1
82
80
  version: 0.1.1
81
+ prerelease: false
82
+ requirement: *id004
83
+ type: :runtime
83
84
  name: canable
84
- version_requirements: *id004
85
85
  - !ruby/object:Gem::Dependency
86
+ version_requirements: &id005 !ruby/object:Gem::Requirement
87
+ none: false
88
+ requirements:
89
+ - - "="
90
+ - !ruby/object:Gem::Version
91
+ hash: 31
92
+ segments:
93
+ - 0
94
+ - 2
95
+ - 4
96
+ version: 0.2.4
86
97
  prerelease: false
98
+ requirement: *id005
87
99
  type: :runtime
88
- requirement: &id005 !ruby/object:Gem::Requirement
100
+ name: mm-versionable
101
+ - !ruby/object:Gem::Dependency
102
+ version_requirements: &id006 !ruby/object:Gem::Requirement
89
103
  none: false
90
104
  requirements:
91
105
  - - ">="
@@ -94,28 +108,29 @@ dependencies:
94
108
  segments:
95
109
  - 0
96
110
  version: "0"
111
+ prerelease: false
112
+ requirement: *id006
113
+ type: :runtime
97
114
  name: ruby-stemmer
98
- version_requirements: *id005
99
115
  description: Core data objects for Noodall
100
- email: steve@wearebeef.co.uk
116
+ email:
117
+ - steve@wearebeef.co.uk
101
118
  executables: []
102
119
 
103
120
  extensions: []
104
121
 
105
- extra_rdoc_files:
106
- - LICENSE
107
- - README.rdoc
122
+ extra_rdoc_files: []
123
+
108
124
  files:
109
125
  - .document
110
126
  - .gitignore
111
- - .rvmrc
112
127
  - Gemfile
113
128
  - LICENSE
114
129
  - README.rdoc
115
130
  - Rakefile
116
- - VERSION
117
131
  - lib/noodall-core.rb
118
132
  - lib/noodall/component.rb
133
+ - lib/noodall/core/version.rb
119
134
  - lib/noodall/global_update_time.rb
120
135
  - lib/noodall/indexer.rb
121
136
  - lib/noodall/node.rb
@@ -123,6 +138,7 @@ files:
123
138
  - lib/noodall/search.rb
124
139
  - lib/noodall/site.rb
125
140
  - lib/noodall/tagging.rb
141
+ - lib/versionable/models/version.rb
126
142
  - noodall-core.gemspec
127
143
  - spec/component_spec.rb
128
144
  - spec/factories/component.rb
@@ -135,8 +151,8 @@ homepage: http://github.com/beef/noodall-core
135
151
  licenses: []
136
152
 
137
153
  post_install_message:
138
- rdoc_options:
139
- - --charset=UTF-8
154
+ rdoc_options: []
155
+
140
156
  require_paths:
141
157
  - lib
142
158
  required_ruby_version: !ruby/object:Gem::Requirement
@@ -153,10 +169,12 @@ required_rubygems_version: !ruby/object:Gem::Requirement
153
169
  requirements:
154
170
  - - ">="
155
171
  - !ruby/object:Gem::Version
156
- hash: 3
172
+ hash: 23
157
173
  segments:
158
- - 0
159
- version: "0"
174
+ - 1
175
+ - 3
176
+ - 6
177
+ version: 1.3.6
160
178
  requirements: []
161
179
 
162
180
  rubyforge_project:
@@ -164,10 +182,5 @@ rubygems_version: 1.6.2
164
182
  signing_key:
165
183
  specification_version: 3
166
184
  summary: Core data objects for Noodall
167
- test_files:
168
- - spec/component_spec.rb
169
- - spec/factories/component.rb
170
- - spec/factories/node.rb
171
- - spec/node_spec.rb
172
- - spec/site_map_spec.rb
173
- - spec/spec_helper.rb
185
+ test_files: []
186
+
data/.rvmrc DELETED
@@ -1,49 +0,0 @@
1
- #!/usr/bin/env bash
2
-
3
- # This is an RVM Project .rvmrc file, used to automatically load the ruby
4
- # development environment upon cd'ing into the directory
5
-
6
- # First we specify our desired <ruby>[@<gemset>], the @gemset name is optional.
7
- environment_id="ruby-1.8.7-p334@g-noodall-core"
8
-
9
- #
10
- # First we attempt to load the desired environment directly from the environment
11
- # file. This is very fast and efficicent compared to running through the entire
12
- # CLI and selector. If you want feedback on which environment was used then
13
- # insert the word 'use' after --create as this triggers verbose mode.
14
- #
15
- if [[ -d "${rvm_path:-$HOME/.rvm}/environments" \
16
- && -s "${rvm_path:-$HOME/.rvm}/environments/$environment_id" ]] ; then
17
- \. "${rvm_path:-$HOME/.rvm}/environments/$environment_id"
18
-
19
- [[ -s ".rvm/hooks/after_use" ]] && . ".rvm/hooks/after_use"
20
- else
21
- # If the environment file has not yet been created, use the RVM CLI to select.
22
- rvm --create use "$environment_id"
23
- fi
24
-
25
- #
26
- # If you use an RVM gemset file to install a list of gems (*.gems), you can have
27
- # it be automatically loaded. Uncomment the following and adjust the filename if
28
- # necessary.
29
- #
30
- # filename=".gems"
31
- # if [[ -s "$filename" ]] ; then
32
- # rvm gemset import "$filename" | grep -v already | grep -v listed | grep -v complete | sed '/^$/d'
33
- # fi
34
-
35
- #
36
- # If you use bundler and would like to run bundle each time you enter the
37
- # directory, you can uncomment the following code.
38
- #
39
- # # Ensure that Bundler is installed. Install it if it is not.
40
- # if ! command -v bundle >/dev/null; then
41
- # printf "The rubygem 'bundler' is not installed. Installing it now.\n"
42
- # gem install bundler
43
- # fi
44
- #
45
- # # Bundle while reducing excess noise.
46
- # printf "Bundling your gems. This may take a few minutes on a fresh clone.\n"
47
- # bundle | grep -v '^Using ' | grep -v ' is complete' | sed '/^$/d'
48
- #
49
-
data/VERSION DELETED
@@ -1 +0,0 @@
1
- 0.6.3