hq-graphql 2.0.6 → 2.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.
- checksums.yaml +4 -4
- data/lib/hq/graphql.rb +1 -0
- data/lib/hq/graphql/comparator.rb +0 -5
- data/lib/hq/graphql/schema.rb +22 -0
- data/lib/hq/graphql/version.rb +1 -1
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: df65e3199361b5b97a2600a99ff594ba2194032a7c9f7d5553ba045264e311c4
|
4
|
+
data.tar.gz: 7ada8061fd1cb4a5f4b5f66d42d0ab9304698320001ec0a97a6e8ca5962e4860
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a83be3fbfba6ca63deffcbcb379f5f21943d542e812eda2ff6d11e37eacb522d02b63d59bb66f9f9d22d0b8a6ef4d3920fe0b884e72bda0c46ea9b5819e7f859
|
7
|
+
data.tar.gz: 03da6a427384a58b832e62119f21337b824b3129d3b2b73e7ee0a8cf79c7e6013ed04594f876aa322e631f4f0535189a0e02b88f64bd575b2f4f8cce0e1e9de7
|
data/lib/hq/graphql.rb
CHANGED
@@ -34,11 +34,6 @@ module HQ
|
|
34
34
|
changes
|
35
35
|
end
|
36
36
|
|
37
|
-
def dump_schema_to_file(directory:, filename:, schema:)
|
38
|
-
::FileUtils.mkdir_p(directory)
|
39
|
-
::File.open(::File.join(directory, filename), "w") { |file| file.write(schema.to_definition) }
|
40
|
-
end
|
41
|
-
|
42
37
|
private
|
43
38
|
|
44
39
|
def convert_schema_to_string(schema)
|
@@ -0,0 +1,22 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module HQ
|
4
|
+
module GraphQL
|
5
|
+
class Schema < ::GraphQL::Schema
|
6
|
+
class << self
|
7
|
+
def dump_directory(directory = Rails.root.join("app", "graphql"))
|
8
|
+
@dump_directory ||= directory
|
9
|
+
end
|
10
|
+
|
11
|
+
def dump_filename(filename = "#{self.name.underscore}.graphql")
|
12
|
+
@dump_filename ||= filename
|
13
|
+
end
|
14
|
+
|
15
|
+
def dump
|
16
|
+
::FileUtils.mkdir_p(dump_directory)
|
17
|
+
::File.open(::File.join(dump_directory, dump_filename), "w") { |file| file.write(self.to_definition) }
|
18
|
+
end
|
19
|
+
end
|
20
|
+
end
|
21
|
+
end
|
22
|
+
end
|
data/lib/hq/graphql/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: hq-graphql
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.
|
4
|
+
version: 2.0.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Danny Jones
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-11-
|
11
|
+
date: 2019-11-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|
@@ -296,6 +296,7 @@ files:
|
|
296
296
|
- lib/hq/graphql/root_mutation.rb
|
297
297
|
- lib/hq/graphql/root_query.rb
|
298
298
|
- lib/hq/graphql/scalars.rb
|
299
|
+
- lib/hq/graphql/schema.rb
|
299
300
|
- lib/hq/graphql/types.rb
|
300
301
|
- lib/hq/graphql/types/object.rb
|
301
302
|
- lib/hq/graphql/types/uuid.rb
|