ydd 0.0.6 → 0.0.7
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.
- data/.rvmrc +1 -6
- data/VERSION +1 -1
- data/lib/ydd/serialization_helper.rb +2 -1
- data/lib/ydd.rb +13 -3
- data/ydd.gemspec +2 -2
- metadata +4 -4
data/.rvmrc
CHANGED
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.0.
|
1
|
+
0.0.7
|
@@ -131,7 +131,8 @@ module YDD
|
|
131
131
|
def self.tables
|
132
132
|
base_tables = YDD.connection.tables
|
133
133
|
base_tables &= YDD.tables if YDD.tables.present?
|
134
|
-
base_tables
|
134
|
+
base_tables.reject! { |table| YDD.schema_tables.include?(table) } if YDD.skip_schema?
|
135
|
+
base_tables
|
135
136
|
end
|
136
137
|
|
137
138
|
def self.dump_table(io, table)
|
data/lib/ydd.rb
CHANGED
@@ -18,6 +18,10 @@ module YDD
|
|
18
18
|
!!skip_schema
|
19
19
|
end
|
20
20
|
|
21
|
+
def self.schema_tables
|
22
|
+
[ 'schema_info', 'schema_migrations' ]
|
23
|
+
end
|
24
|
+
|
21
25
|
def self.skip_data?
|
22
26
|
!!skip_data
|
23
27
|
end
|
@@ -71,9 +75,15 @@ module YDD
|
|
71
75
|
if !File.directory?(directory)
|
72
76
|
raise Error, "Please provide a valid directory - #{directory} doesn't exist."
|
73
77
|
end
|
74
|
-
|
75
|
-
|
76
|
-
|
78
|
+
unless skip_schema?
|
79
|
+
check_files! directory, "schema.rb"
|
80
|
+
SchemaManager.load File.join(directory, "schema.rb")
|
81
|
+
end
|
82
|
+
|
83
|
+
unless skip_data?
|
84
|
+
check_files! directory, "data.yml"
|
85
|
+
DataManager.load File.join(directory, "data.yml")
|
86
|
+
end
|
77
87
|
end
|
78
88
|
|
79
89
|
def self.check_files!(dir, *files)
|
data/ydd.gemspec
CHANGED
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{ydd}
|
8
|
-
s.version = "0.0.
|
8
|
+
s.version = "0.0.7"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Adam Wiggins", "Orion Henry", "Darcy Laycock"]
|
12
|
-
s.date = %q{2010-
|
12
|
+
s.date = %q{2010-11-08}
|
13
13
|
s.default_executable = %q{ydd}
|
14
14
|
s.description = %q{
|
15
15
|
YDD is a tool (a fork of yaml_db really) to make it generally easy
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ydd
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 17
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 0
|
9
|
-
-
|
10
|
-
version: 0.0.
|
9
|
+
- 7
|
10
|
+
version: 0.0.7
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Adam Wiggins
|
@@ -17,7 +17,7 @@ autorequire:
|
|
17
17
|
bindir: bin
|
18
18
|
cert_chain: []
|
19
19
|
|
20
|
-
date: 2010-
|
20
|
+
date: 2010-11-08 00:00:00 +08:00
|
21
21
|
default_executable: ydd
|
22
22
|
dependencies:
|
23
23
|
- !ruby/object:Gem::Dependency
|