graphql_migrate_execution 0.0.1 → 0.0.2
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/bin/graphql_migrate_execution +39 -0
- data/lib/graphql_migrate_execution/version.rb +1 -1
- metadata +7 -5
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 4fbd874076a766e4abf14571cc0d4d9a348f5868f89df74f9e0f2ad421e65fd4
|
|
4
|
+
data.tar.gz: 013e06b1123c06b80d9fd2e270ace5032890c8d35cb8bac8f91e78e8805755ac
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 24a586f44159ceac3d674171cbc25d31c342c7238f6d025954f833e6000231a61893c04bdac741df32e5e90c9f30dd22976069eca8c7af66a8c0b1571fc4c6f9
|
|
7
|
+
data.tar.gz: fc25e0c9baf95aed3104802604bbd8aba57cd528dd136c912f5f459c973f08f1b510623b13b9a7abcae272ce98c834572ca64b4391841b184c6810e19d99ecc6
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
#!/usr/bin/env ruby
|
|
2
|
+
# frozen_string_literal: true
|
|
3
|
+
require "graphql_migrate_execution"
|
|
4
|
+
require "optparse"
|
|
5
|
+
|
|
6
|
+
options = {}
|
|
7
|
+
parser = OptionParser.new
|
|
8
|
+
parser.banner = <<~TEXT
|
|
9
|
+
Usage: graphql_migrate_execution glob [options]
|
|
10
|
+
|
|
11
|
+
A development tool for adopting GraphQL-Ruby's new runtime module, GraphQL::Execution::Next
|
|
12
|
+
|
|
13
|
+
Inspect the files matched by `glob` and ...
|
|
14
|
+
|
|
15
|
+
- (default) print an analysis result for what can be updated
|
|
16
|
+
- `--migrate`: update files with new configuration
|
|
17
|
+
- `--cleanup`: remove legacy configuration and instance methods
|
|
18
|
+
|
|
19
|
+
Options:
|
|
20
|
+
|
|
21
|
+
TEXT
|
|
22
|
+
|
|
23
|
+
parser.on("--migrate", "Update the files with future-compatibile configuration")
|
|
24
|
+
parser.on("--cleanup", "Remove resolver instance methods for GraphQL-Ruby's old runtime")
|
|
25
|
+
parser.on("--concise", "Don't print migration strategy descriptions")
|
|
26
|
+
|
|
27
|
+
# TODO:
|
|
28
|
+
parser.on("--implicit MODE", "Handle implicit field resolution using MODE")
|
|
29
|
+
parser.on("--only PATTERN", "Only analyze or update fields whose path (`Type.field`) matches /PATTERN/")
|
|
30
|
+
|
|
31
|
+
parser.parse!(into: options)
|
|
32
|
+
|
|
33
|
+
filename = ARGV.shift || begin
|
|
34
|
+
warn "graphql_migrate_execution requires a filename or path as a first argument, please pass one."
|
|
35
|
+
exit 1
|
|
36
|
+
end
|
|
37
|
+
|
|
38
|
+
migration = GraphqlMigrateExecution::Migration.new(filename, **options)
|
|
39
|
+
migration.run
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: graphql_migrate_execution
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.0.
|
|
4
|
+
version: 0.0.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Robert Mosolgo
|
|
@@ -82,11 +82,13 @@ dependencies:
|
|
|
82
82
|
description: A development script for migrating to GraphQL-Ruby's new runtime engine
|
|
83
83
|
email:
|
|
84
84
|
- rdmosolgo@gmail.com
|
|
85
|
-
executables:
|
|
85
|
+
executables:
|
|
86
|
+
- graphql_migrate_execution
|
|
86
87
|
extensions: []
|
|
87
88
|
extra_rdoc_files: []
|
|
88
89
|
files:
|
|
89
90
|
- MIT-LICENSE
|
|
91
|
+
- bin/graphql_migrate_execution
|
|
90
92
|
- lib/graphql_migrate_execution.rb
|
|
91
93
|
- lib/graphql_migrate_execution/action.rb
|
|
92
94
|
- lib/graphql_migrate_execution/add_future.rb
|
|
@@ -113,9 +115,9 @@ licenses:
|
|
|
113
115
|
- MIT
|
|
114
116
|
metadata:
|
|
115
117
|
homepage_uri: https://graphql-ruby.org
|
|
116
|
-
changelog_uri: https://github.com/rmosolgo/
|
|
117
|
-
source_code_uri: https://github.com/rmosolgo/
|
|
118
|
-
bug_tracker_uri: https://github.com/rmosolgo/
|
|
118
|
+
changelog_uri: https://github.com/rmosolgo/graphql_migrate_execution
|
|
119
|
+
source_code_uri: https://github.com/rmosolgo/graphql_migrate_execution
|
|
120
|
+
bug_tracker_uri: https://github.com/rmosolgo/graphql_migrate_execution/issues
|
|
119
121
|
mailing_list_uri: https://buttondown.email/graphql-ruby
|
|
120
122
|
rubygems_mfa_required: 'true'
|
|
121
123
|
rdoc_options: []
|