dbmapper 0.0.4 → 0.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/dbmapper-0.0.4.gem +0 -0
- data/lib/dbmapper.rb +5 -5
- data/lib/dbmapper/version.rb +1 -1
- metadata +2 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 671c841eb2910213f35a65231d5217c58fc6c22a
|
4
|
+
data.tar.gz: b3c2119ef958abd804583be021e6474909b1233a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6eb2f0c41e4171bb3c69db5cc54613608d9017062af7f592cfdd62f2725d7b13ad50c56cca66aad5fc8b6a1aa3a0ff6fd83e5e474fb9a391af2db3c003ec1d5f
|
7
|
+
data.tar.gz: eb348c620c2f123999d453dcbc64356cf3ef612ee6377137f936cd66065c23825c6bbe904fddcce5c7095dd6b15a02b3d6830c2deb154b31c91dddebe56b12b8
|
data/dbmapper-0.0.4.gem
ADDED
Binary file
|
data/lib/dbmapper.rb
CHANGED
@@ -12,7 +12,7 @@ module Dbmapper
|
|
12
12
|
text_file = File.open("mapped_databse.txt", 'w')
|
13
13
|
ActiveRecord::Base.descendants.each do |model|
|
14
14
|
text_file.write(model)
|
15
|
-
text_file.write(
|
15
|
+
text_file.write("\n")
|
16
16
|
end
|
17
17
|
puts "All your models have been written to mapped_databse.txt"
|
18
18
|
text_file.close
|
@@ -23,10 +23,10 @@ module Dbmapper
|
|
23
23
|
text_file = File.open("mapped_databse.txt", 'w')
|
24
24
|
ActiveRecord::Base.descendants.each do |model|
|
25
25
|
text_file.write(model)
|
26
|
-
text_file.write(
|
26
|
+
text_file.write("\n\n")
|
27
27
|
model.column_names.each do |column|
|
28
28
|
text_file.write(column)
|
29
|
-
text_file.write(
|
29
|
+
text_file.write("\n")
|
30
30
|
end
|
31
31
|
end
|
32
32
|
puts "All your columns have been written to mapped_databse.txt"
|
@@ -39,12 +39,12 @@ module Dbmapper
|
|
39
39
|
association_string = "-->"
|
40
40
|
ActiveRecord::Base.descendants.each do |model|
|
41
41
|
text_file.write(model)
|
42
|
-
text_file.write(
|
42
|
+
text_file.write("\n")
|
43
43
|
model.relfect_on_all_associations.map(&:name).each do |assocations|
|
44
44
|
association_string = association_string + " #{assocations},"
|
45
45
|
end
|
46
46
|
text_file.write(association_string)
|
47
|
-
text_file.write(
|
47
|
+
text_file.write("\n\n")
|
48
48
|
association_string = "-->"
|
49
49
|
end
|
50
50
|
puts "all models with their assocations have been written to mapped_databse.txt"
|
data/lib/dbmapper/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: dbmapper
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- sh6khan
|
@@ -53,6 +53,7 @@ files:
|
|
53
53
|
- dbmapper-0.0.1.gem
|
54
54
|
- dbmapper-0.0.2.gem
|
55
55
|
- dbmapper-0.0.3.gem
|
56
|
+
- dbmapper-0.0.4.gem
|
56
57
|
- dbmapper.gemspec
|
57
58
|
- lib/dbmapper.rb
|
58
59
|
- lib/dbmapper/version.rb
|