mongoid-history 0.4.0 → 0.4.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +15 -0
- data/.document +5 -5
- data/.rspec +1 -1
- data/.rubocop.yml +75 -0
- data/.travis.yml +7 -5
- data/CHANGELOG.md +94 -76
- data/Gemfile +16 -12
- data/LICENSE.txt +20 -20
- data/README.md +309 -307
- data/Rakefile +37 -37
- data/VERSION +1 -1
- data/lib/mongoid/history/trackable.rb +337 -338
- data/lib/mongoid/history/tracker.rb +215 -220
- data/lib/mongoid/history.rb +25 -27
- data/lib/mongoid-history.rb +9 -10
- data/mongoid-history.gemspec +80 -68
- data/spec/integration/integration_spec.rb +788 -754
- data/spec/integration/multi_relation_spec.rb +53 -50
- data/spec/integration/nested_embedded_documents_spec.rb +77 -77
- data/spec/integration/subclasses_spec.rb +29 -0
- data/spec/spec_helper.rb +10 -11
- data/spec/support/mongoid.rb +11 -15
- data/spec/support/mongoid_history.rb +13 -15
- data/spec/trackable_spec.rb +240 -240
- data/spec/tracker_spec.rb +10 -10
- metadata +65 -30
- data/lib/mongoid/history/sweeper.rb +0 -44
data/mongoid-history.gemspec
CHANGED
@@ -1,68 +1,80 @@
|
|
1
|
-
# Generated by jeweler
|
2
|
-
# DO NOT EDIT THIS FILE DIRECTLY
|
3
|
-
# Instead, edit Jeweler::Tasks in
|
4
|
-
# -*- encoding: utf-8 -*-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
s.
|
9
|
-
|
10
|
-
|
11
|
-
s.
|
12
|
-
s.
|
13
|
-
s.
|
14
|
-
s.
|
15
|
-
s.
|
16
|
-
|
17
|
-
"
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
".
|
23
|
-
"
|
24
|
-
"
|
25
|
-
"
|
26
|
-
"
|
27
|
-
"
|
28
|
-
"
|
29
|
-
"
|
30
|
-
"
|
31
|
-
"
|
32
|
-
"lib/mongoid
|
33
|
-
"lib/mongoid/history
|
34
|
-
"mongoid
|
35
|
-
"
|
36
|
-
"
|
37
|
-
"spec/integration/
|
38
|
-
"spec/
|
39
|
-
"spec/
|
40
|
-
"spec/
|
41
|
-
"spec/
|
42
|
-
"spec/
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
s.
|
48
|
-
s.
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
s.
|
59
|
-
s.
|
60
|
-
s.
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
1
|
+
# Generated by jeweler
|
2
|
+
# DO NOT EDIT THIS FILE DIRECTLY
|
3
|
+
# Instead, edit Jeweler::Tasks in rakefile, and run 'rake gemspec'
|
4
|
+
# -*- encoding: utf-8 -*-
|
5
|
+
# stub: mongoid-history 0.4.1 ruby lib
|
6
|
+
|
7
|
+
Gem::Specification.new do |s|
|
8
|
+
s.name = "mongoid-history"
|
9
|
+
s.version = "0.4.1"
|
10
|
+
|
11
|
+
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
12
|
+
s.authors = ["Aaron Qian", "Justin Grimes", "Daniel Doubrovkine"]
|
13
|
+
s.date = "2014-01-11"
|
14
|
+
s.description = "This library tracks historical changes for any document, including embedded ones. It achieves this by storing all history tracks in a single collection that you define. Embedded documents are referenced by storing an association path, which is an array of document_name and document_id fields starting from the top most parent document and down to the embedded document that should track history. Mongoid-history implements multi-user undo, which allows users to undo any history change in any order. Undoing a document also creates a new history track. This is great for auditing and preventing vandalism, but it is probably not suitable for use cases such as a wiki."
|
15
|
+
s.email = ["aq1018@gmail.com", "justin.mgrimes@gmail.com", "dblock@dblock.org"]
|
16
|
+
s.extra_rdoc_files = [
|
17
|
+
"CHANGELOG.md",
|
18
|
+
"LICENSE.txt",
|
19
|
+
"README.md"
|
20
|
+
]
|
21
|
+
s.files = [
|
22
|
+
".document",
|
23
|
+
".rspec",
|
24
|
+
".rubocop.yml",
|
25
|
+
".travis.yml",
|
26
|
+
"CHANGELOG.md",
|
27
|
+
"Gemfile",
|
28
|
+
"LICENSE.txt",
|
29
|
+
"README.md",
|
30
|
+
"Rakefile",
|
31
|
+
"VERSION",
|
32
|
+
"lib/mongoid-history.rb",
|
33
|
+
"lib/mongoid/history.rb",
|
34
|
+
"lib/mongoid/history/trackable.rb",
|
35
|
+
"lib/mongoid/history/tracker.rb",
|
36
|
+
"mongoid-history.gemspec",
|
37
|
+
"spec/integration/integration_spec.rb",
|
38
|
+
"spec/integration/multi_relation_spec.rb",
|
39
|
+
"spec/integration/nested_embedded_documents_spec.rb",
|
40
|
+
"spec/integration/subclasses_spec.rb",
|
41
|
+
"spec/spec_helper.rb",
|
42
|
+
"spec/support/mongoid.rb",
|
43
|
+
"spec/support/mongoid_history.rb",
|
44
|
+
"spec/trackable_spec.rb",
|
45
|
+
"spec/tracker_spec.rb"
|
46
|
+
]
|
47
|
+
s.homepage = "http://github.com/aq1018/mongoid-history"
|
48
|
+
s.licenses = ["MIT"]
|
49
|
+
s.require_paths = ["lib"]
|
50
|
+
s.rubygems_version = "2.1.8"
|
51
|
+
s.summary = "Track and audit, undo and redo changes on Mongoid documents."
|
52
|
+
|
53
|
+
if s.respond_to? :specification_version then
|
54
|
+
s.specification_version = 4
|
55
|
+
|
56
|
+
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
|
57
|
+
s.add_runtime_dependency(%q<easy_diff>, [">= 0"])
|
58
|
+
s.add_runtime_dependency(%q<mongoid>, [">= 3.0"])
|
59
|
+
s.add_runtime_dependency(%q<activesupport>, [">= 0"])
|
60
|
+
s.add_development_dependency(%q<rubocop>, ["~> 0.15.0"])
|
61
|
+
s.add_development_dependency(%q<yard>, [">= 0"])
|
62
|
+
s.add_development_dependency(%q<jeweler>, [">= 0"])
|
63
|
+
else
|
64
|
+
s.add_dependency(%q<easy_diff>, [">= 0"])
|
65
|
+
s.add_dependency(%q<mongoid>, [">= 3.0"])
|
66
|
+
s.add_dependency(%q<activesupport>, [">= 0"])
|
67
|
+
s.add_dependency(%q<rubocop>, ["~> 0.15.0"])
|
68
|
+
s.add_dependency(%q<yard>, [">= 0"])
|
69
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
70
|
+
end
|
71
|
+
else
|
72
|
+
s.add_dependency(%q<easy_diff>, [">= 0"])
|
73
|
+
s.add_dependency(%q<mongoid>, [">= 3.0"])
|
74
|
+
s.add_dependency(%q<activesupport>, [">= 0"])
|
75
|
+
s.add_dependency(%q<rubocop>, ["~> 0.15.0"])
|
76
|
+
s.add_dependency(%q<yard>, [">= 0"])
|
77
|
+
s.add_dependency(%q<jeweler>, [">= 0"])
|
78
|
+
end
|
79
|
+
end
|
80
|
+
|