shopify-cli 2.6.6 → 2.7.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.devcontainer.json +5 -0
- data/.github/CODEOWNERS +2 -2
- data/.github/DESIGN.md +1 -1
- data/.github/ISSUE_TEMPLATE.md +7 -0
- data/.github/workflows/shopify.yml +1 -1
- data/.gitignore +1 -0
- data/.ruby-version +1 -1
- data/.vscode/extensions.json +5 -0
- data/.vscode/settings.json +9 -0
- data/CHANGELOG.md +44 -4
- data/CONTRIBUTING.md +1 -29
- data/{Dockerfile → Codespace.dockerfile} +2 -2
- data/Gemfile.lock +5 -5
- data/README.md +20 -99
- data/Rakefile +27 -0
- data/Tests.dockerfile +35 -0
- data/assets/logo.png +0 -0
- data/dev.yml +1 -4
- data/docs/README.md +13 -0
- data/docs/contributors/testing.md +27 -0
- data/docs/users/installation.md +46 -0
- data/{THEMEKIT_MIGRATION.md → docs/users/migrate-from-themekit.md} +1 -1
- data/ext/javy/hashes/javy-arm-macos-v0.1.0.gz.sha256 +1 -0
- data/ext/javy/hashes/javy-x86_64-linux-v0.1.0.gz.sha256 +1 -0
- data/ext/javy/hashes/javy-x86_64-macos-v0.1.0.gz.sha256 +1 -0
- data/ext/javy/hashes/javy-x86_64-windows-v0.1.0.gz.sha256 +1 -0
- data/ext/javy/javy.rb +205 -0
- data/ext/javy/version +1 -0
- data/lib/project_types/extension/cli.rb +6 -3
- data/lib/project_types/extension/commands/build.rb +4 -8
- data/lib/project_types/extension/commands/create.rb +2 -5
- data/lib/project_types/extension/commands/extension_command.rb +1 -1
- data/lib/project_types/extension/features/argo_serve.rb +9 -23
- data/lib/project_types/extension/forms/questions/ask_template.rb +1 -5
- data/lib/project_types/extension/messages/messages.rb +0 -2
- data/lib/project_types/extension/models/development_server.rb +2 -2
- data/lib/project_types/extension/models/development_server_requirements.rb +2 -3
- data/lib/project_types/extension/models/server_config/app.rb +13 -0
- data/lib/project_types/extension/models/server_config/development.rb +5 -4
- data/lib/project_types/extension/models/server_config/development_renderer.rb +1 -1
- data/lib/project_types/extension/models/server_config/development_resource.rb +13 -0
- data/lib/project_types/extension/models/server_config/extension.rb +3 -1
- data/lib/project_types/extension/models/server_config/root.rb +4 -1
- data/lib/project_types/extension/tasks/convert_server_config.rb +65 -0
- data/lib/project_types/extension/tasks/ensure_resource_url.rb +39 -0
- data/lib/project_types/extension/tasks/merge_server_config.rb +32 -0
- data/lib/project_types/extension/tasks/run_extension_command.rb +11 -10
- data/lib/project_types/node/cli.rb +0 -16
- data/lib/project_types/node/forms/create.rb +5 -5
- data/lib/project_types/node/messages/messages.rb +2 -144
- data/lib/project_types/php/cli.rb +0 -11
- data/lib/project_types/php/forms/create.rb +5 -6
- data/lib/project_types/php/messages/messages.rb +2 -161
- data/lib/project_types/rails/cli.rb +0 -16
- data/lib/project_types/rails/commands/create.rb +3 -5
- data/lib/project_types/rails/forms/create.rb +5 -6
- data/lib/project_types/rails/messages/messages.rb +6 -151
- data/lib/project_types/script/cli.rb +8 -2
- data/lib/project_types/script/commands/create.rb +2 -4
- data/lib/project_types/script/commands/javy.rb +29 -0
- data/lib/project_types/script/commands/push.rb +3 -2
- data/lib/project_types/script/config/extension_points.yml +12 -30
- data/lib/project_types/script/forms/ask_app.rb +32 -0
- data/lib/project_types/script/forms/ask_org.rb +30 -0
- data/lib/project_types/script/forms/ask_script_uuid.rb +22 -0
- data/lib/project_types/script/forms/run_against_shopify_org.rb +14 -0
- data/lib/project_types/script/graphql/app_script_set.graphql +2 -2
- data/lib/project_types/script/layers/application/build_script.rb +0 -1
- data/lib/project_types/script/layers/application/connect_app.rb +73 -0
- data/lib/project_types/script/layers/application/create_script.rb +1 -1
- data/lib/project_types/script/layers/application/push_script.rb +1 -1
- data/lib/project_types/script/layers/domain/errors.rb +1 -4
- data/lib/project_types/script/layers/domain/push_package.rb +3 -3
- data/lib/project_types/script/layers/domain/{script_json.rb → script_config.rb} +2 -2
- data/lib/project_types/script/layers/domain/script_project.rb +5 -1
- data/lib/project_types/script/layers/infrastructure/errors.rb +36 -7
- data/lib/project_types/script/layers/infrastructure/languages/assemblyscript_task_runner.rb +0 -4
- data/lib/project_types/script/layers/infrastructure/languages/typescript_task_runner.rb +0 -4
- data/lib/project_types/script/layers/infrastructure/push_package_repository.rb +2 -2
- data/lib/project_types/script/layers/infrastructure/script_project_repository.rb +104 -27
- data/lib/project_types/script/layers/infrastructure/script_service.rb +11 -11
- data/lib/project_types/script/messages/messages.rb +21 -4
- data/lib/project_types/script/ui/error_handler.rb +31 -21
- data/lib/project_types/theme/cli.rb +1 -1
- data/lib/project_types/theme/commands/check.rb +1 -1
- data/lib/project_types/theme/commands/delete.rb +1 -1
- data/lib/project_types/theme/commands/init.rb +1 -1
- data/lib/project_types/theme/commands/language_server.rb +1 -1
- data/lib/project_types/theme/commands/package.rb +1 -1
- data/lib/project_types/theme/commands/publish.rb +1 -1
- data/lib/project_types/theme/commands/pull.rb +4 -1
- data/lib/project_types/theme/commands/push.rb +5 -1
- data/lib/project_types/theme/commands/serve.rb +9 -3
- data/lib/project_types/theme/messages/messages.rb +39 -2
- data/lib/project_types/theme/ui/sync_progress_bar.rb +2 -2
- data/lib/shopify_cli/admin_api/populate_resource_command.rb +1 -1
- data/lib/shopify_cli/api.rb +7 -2
- data/lib/shopify_cli/app_type_detector.rb +24 -20
- data/lib/shopify_cli/command/app_sub_command.rb +10 -0
- data/lib/shopify_cli/command/project_command.rb +31 -0
- data/lib/shopify_cli/command/sub_command.rb +19 -0
- data/lib/shopify_cli/command.rb +7 -2
- data/lib/shopify_cli/commands/app/connect.rb +22 -0
- data/lib/shopify_cli/commands/app/create/node.rb +36 -0
- data/lib/shopify_cli/commands/app/create/php.rb +36 -0
- data/lib/shopify_cli/commands/app/create/rails.rb +38 -0
- data/lib/shopify_cli/commands/app/create.rb +28 -0
- data/lib/shopify_cli/commands/app/deploy.rb +49 -0
- data/lib/shopify_cli/commands/app/open.rb +19 -0
- data/lib/shopify_cli/commands/app/serve.rb +49 -0
- data/lib/shopify_cli/commands/app/tunnel.rb +43 -0
- data/lib/shopify_cli/commands/app.rb +29 -0
- data/lib/shopify_cli/commands/config.rb +2 -2
- data/lib/shopify_cli/commands.rb +1 -0
- data/lib/shopify_cli/constants.rb +7 -0
- data/lib/shopify_cli/context.rb +10 -0
- data/lib/shopify_cli/environment.rb +4 -0
- data/lib/shopify_cli/exception_reporter.rb +3 -4
- data/lib/shopify_cli/git.rb +14 -1
- data/lib/shopify_cli/github/issue_url_generator.rb +19 -0
- data/lib/shopify_cli/github.rb +5 -0
- data/lib/shopify_cli/identity_auth.rb +18 -0
- data/lib/shopify_cli/messages/messages.rb +254 -9
- data/lib/shopify_cli/partners_api.rb +1 -8
- data/lib/shopify_cli/project.rb +5 -1
- data/lib/shopify_cli/project_commands.rb +1 -1
- data/lib/shopify_cli/services/app/connect_service.rb +25 -0
- data/lib/shopify_cli/services/app/create/node_service.rb +155 -0
- data/lib/shopify_cli/services/app/create/php_service.rb +152 -0
- data/lib/shopify_cli/services/app/create/rails_service.rb +215 -0
- data/lib/shopify_cli/services/app/deploy/heroku/node_service.rb +101 -0
- data/lib/shopify_cli/services/app/deploy/heroku/php_service.rb +135 -0
- data/lib/shopify_cli/services/app/deploy/heroku/rails_service.rb +120 -0
- data/lib/shopify_cli/services/app/open_service.rb +19 -0
- data/lib/shopify_cli/services/app/serve/node_service.rb +42 -0
- data/lib/shopify_cli/services/app/serve/php_service.rb +46 -0
- data/lib/shopify_cli/services/app/serve/rails_service.rb +48 -0
- data/lib/shopify_cli/services/app/tunnel/auth_service.rb +21 -0
- data/lib/shopify_cli/services/app/tunnel/start_service.rb +20 -0
- data/lib/shopify_cli/services/app/tunnel/stop_service.rb +20 -0
- data/lib/shopify_cli/services.rb +31 -0
- data/lib/shopify_cli/tasks/ensure_authenticated.rb +9 -3
- data/lib/shopify_cli/theme/dev_server/cdn_fonts.rb +73 -0
- data/lib/shopify_cli/theme/dev_server/hot-reload.js +25 -9
- data/lib/shopify_cli/theme/dev_server/local_assets.rb +1 -1
- data/lib/shopify_cli/theme/dev_server.rb +37 -18
- data/lib/shopify_cli/theme/syncer/error_reporter.rb +45 -0
- data/lib/shopify_cli/theme/syncer/operation.rb +56 -0
- data/lib/shopify_cli/theme/syncer/standard_reporter.rb +32 -0
- data/lib/shopify_cli/theme/syncer.rb +40 -39
- data/lib/shopify_cli/theme/theme.rb +31 -19
- data/lib/shopify_cli/tunnel.rb +26 -22
- data/lib/shopify_cli/version.rb +1 -1
- data/lib/shopify_cli.rb +1 -2
- data/shopify-cli.gemspec +1 -1
- data/shopify-dev +18 -0
- data/utilities/constants.rb +7 -0
- data/utilities/docker/container.rb +10 -3
- data/utilities/docker.rb +2 -2
- data/utilities/utilities.rb +1 -0
- data/vendor/deps/cli-kit/lib/cli/kit/system.rb +1 -1
- metadata +66 -50
- data/docs/_config.yml +0 -2
- data/docs/app/node/commands/index.md +0 -4
- data/docs/app/node/index.md +0 -4
- data/docs/app/rails/commands/index.md +0 -4
- data/docs/app/rails/index.md +0 -4
- data/docs/core/index.md +0 -4
- data/docs/getting-started/index.md +0 -4
- data/docs/getting-started/install/index.md +0 -4
- data/docs/getting-started/migrate/index.md +0 -4
- data/docs/getting-started/uninstall/index.md +0 -4
- data/docs/getting-started/upgrade/index.md +0 -4
- data/docs/help/start-app/index.md +0 -4
- data/docs/index.md +0 -4
- data/install.sh +0 -7
- data/lib/project_types/extension/tasks/converters/server_config_converter.rb +0 -30
- data/lib/project_types/extension/tasks/load_server_config.rb +0 -28
- data/lib/project_types/node/commands/connect.rb +0 -21
- data/lib/project_types/node/commands/create.rb +0 -125
- data/lib/project_types/node/commands/deploy/heroku.rb +0 -96
- data/lib/project_types/node/commands/deploy.rb +0 -32
- data/lib/project_types/node/commands/generate.rb +0 -22
- data/lib/project_types/node/commands/open.rb +0 -18
- data/lib/project_types/node/commands/serve.rb +0 -45
- data/lib/project_types/node/commands/tunnel.rb +0 -41
- data/lib/project_types/php/commands/connect.rb +0 -19
- data/lib/project_types/php/commands/create.rb +0 -143
- data/lib/project_types/php/commands/deploy/heroku.rb +0 -129
- data/lib/project_types/php/commands/deploy.rb +0 -32
- data/lib/project_types/php/commands/open.rb +0 -16
- data/lib/project_types/php/commands/serve.rb +0 -48
- data/lib/project_types/php/commands/tunnel.rb +0 -37
- data/lib/project_types/rails/commands/connect.rb +0 -21
- data/lib/project_types/rails/commands/deploy/heroku.rb +0 -115
- data/lib/project_types/rails/commands/deploy.rb +0 -32
- data/lib/project_types/rails/commands/generate/webhook.rb +0 -42
- data/lib/project_types/rails/commands/generate.rb +0 -60
- data/lib/project_types/rails/commands/open.rb +0 -18
- data/lib/project_types/rails/commands/serve.rb +0 -51
- data/lib/project_types/rails/commands/tunnel.rb +0 -41
- data/lib/project_types/script/tasks/ensure_env.rb +0 -106
- data/lib/shopify_cli/sub_command.rb +0 -17
- data/shopify.fish +0 -12
- data/shopify.sh +0 -11
data/utilities/docker.rb
CHANGED
@@ -59,7 +59,7 @@ module Utilities
|
|
59
59
|
unless image_exists?(image_tag)
|
60
60
|
puts "Rebuilding the Docker image..."
|
61
61
|
_, err, stat = Open3.capture3(
|
62
|
-
"docker", "build",
|
62
|
+
"docker", "build", "-t", image_tag, "-f", File.join(root_dir, "Tests.dockerfile"), root_dir
|
63
63
|
)
|
64
64
|
raise Error, err unless stat.success?
|
65
65
|
end
|
@@ -67,7 +67,7 @@ module Utilities
|
|
67
67
|
|
68
68
|
def image_tag
|
69
69
|
gemfile_lock_path = File.expand_path("./Gemfile.lock", root_dir)
|
70
|
-
dockerfile_path = File.expand_path("./
|
70
|
+
dockerfile_path = File.expand_path("./Tests.dockerfile", root_dir)
|
71
71
|
fingerprintable_strings = [
|
72
72
|
File.read(gemfile_lock_path),
|
73
73
|
File.read(dockerfile_path),
|
data/utilities/utilities.rb
CHANGED
@@ -222,7 +222,7 @@ module CLI
|
|
222
222
|
end
|
223
223
|
|
224
224
|
def which(cmd, env)
|
225
|
-
exts = os == :windows ? env.fetch('PATHEXT').split(';') : ['']
|
225
|
+
exts = os == :windows ? env.fetch('PATHEXT', ['']).split(';') : ['']
|
226
226
|
env.fetch('PATH', '').split(File::PATH_SEPARATOR).each do |path|
|
227
227
|
exts.each do |ext|
|
228
228
|
exe = File.join(path, "#{cmd}#{ext}")
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: shopify-cli
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.
|
4
|
+
version: 2.7.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Shopify
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-12-13 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -92,14 +92,14 @@ dependencies:
|
|
92
92
|
requirements:
|
93
93
|
- - "~>"
|
94
94
|
- !ruby/object:Gem::Version
|
95
|
-
version: 1.
|
95
|
+
version: 1.9.0
|
96
96
|
type: :runtime
|
97
97
|
prerelease: false
|
98
98
|
version_requirements: !ruby/object:Gem::Requirement
|
99
99
|
requirements:
|
100
100
|
- - "~>"
|
101
101
|
- !ruby/object:Gem::Version
|
102
|
-
version: 1.
|
102
|
+
version: 1.9.0
|
103
103
|
description: |
|
104
104
|
Shopify CLI helps you build Shopify apps faster. It quickly scaffolds Node.js
|
105
105
|
and Ruby on Rails embedded apps. It also automates many common tasks in the
|
@@ -112,6 +112,7 @@ executables:
|
|
112
112
|
extensions: []
|
113
113
|
extra_rdoc_files: []
|
114
114
|
files:
|
115
|
+
- ".devcontainer.json"
|
115
116
|
- ".github/CODEOWNERS"
|
116
117
|
- ".github/CODE_OF_CONDUCT.md"
|
117
118
|
- ".github/CONTRIBUTING.md"
|
@@ -127,9 +128,11 @@ files:
|
|
127
128
|
- ".ruby-version"
|
128
129
|
- ".tmp/.gitkeep"
|
129
130
|
- ".tmp/sv/.gitkeep"
|
131
|
+
- ".vscode/extensions.json"
|
132
|
+
- ".vscode/settings.json"
|
130
133
|
- CHANGELOG.md
|
131
134
|
- CONTRIBUTING.md
|
132
|
-
-
|
135
|
+
- Codespace.dockerfile
|
133
136
|
- Gemfile
|
134
137
|
- Gemfile.lock
|
135
138
|
- LICENSE
|
@@ -137,28 +140,25 @@ files:
|
|
137
140
|
- RELEASING.md
|
138
141
|
- Rakefile
|
139
142
|
- SECURITY.md
|
140
|
-
-
|
143
|
+
- Tests.dockerfile
|
144
|
+
- assets/logo.png
|
141
145
|
- bin/console
|
142
146
|
- bin/load_shopify.rb
|
143
147
|
- bin/shopify
|
144
148
|
- dev.yml
|
145
|
-
- docs/
|
146
|
-
- docs/
|
147
|
-
- docs/
|
148
|
-
- docs/
|
149
|
-
-
|
150
|
-
-
|
151
|
-
-
|
152
|
-
-
|
153
|
-
-
|
154
|
-
-
|
155
|
-
- docs/getting-started/upgrade/index.md
|
156
|
-
- docs/help/start-app/index.md
|
157
|
-
- docs/index.md
|
149
|
+
- docs/README.md
|
150
|
+
- docs/contributors/testing.md
|
151
|
+
- docs/users/installation.md
|
152
|
+
- docs/users/migrate-from-themekit.md
|
153
|
+
- ext/javy/hashes/javy-arm-macos-v0.1.0.gz.sha256
|
154
|
+
- ext/javy/hashes/javy-x86_64-linux-v0.1.0.gz.sha256
|
155
|
+
- ext/javy/hashes/javy-x86_64-macos-v0.1.0.gz.sha256
|
156
|
+
- ext/javy/hashes/javy-x86_64-windows-v0.1.0.gz.sha256
|
157
|
+
- ext/javy/javy.rb
|
158
|
+
- ext/javy/version
|
158
159
|
- ext/shopify-extensions/extconf.rb
|
159
160
|
- ext/shopify-extensions/shopify_extensions.rb
|
160
161
|
- ext/shopify-extensions/version
|
161
|
-
- install.sh
|
162
162
|
- lib/docgen/class_template.md.erb
|
163
163
|
- lib/docgen/index_template.md.erb
|
164
164
|
- lib/docgen/markdown.rb
|
@@ -222,10 +222,12 @@ files:
|
|
222
222
|
- lib/project_types/extension/models/npm_package.rb
|
223
223
|
- lib/project_types/extension/models/product.rb
|
224
224
|
- lib/project_types/extension/models/registration.rb
|
225
|
+
- lib/project_types/extension/models/server_config/app.rb
|
225
226
|
- lib/project_types/extension/models/server_config/base.rb
|
226
227
|
- lib/project_types/extension/models/server_config/development.rb
|
227
228
|
- lib/project_types/extension/models/server_config/development_entries.rb
|
228
229
|
- lib/project_types/extension/models/server_config/development_renderer.rb
|
230
|
+
- lib/project_types/extension/models/server_config/development_resource.rb
|
229
231
|
- lib/project_types/extension/models/server_config/extension.rb
|
230
232
|
- lib/project_types/extension/models/server_config/root.rb
|
231
233
|
- lib/project_types/extension/models/server_config/user.rb
|
@@ -240,13 +242,14 @@ files:
|
|
240
242
|
- lib/project_types/extension/tasks/choose_next_available_port.rb
|
241
243
|
- lib/project_types/extension/tasks/configure_features.rb
|
242
244
|
- lib/project_types/extension/tasks/configure_options.rb
|
245
|
+
- lib/project_types/extension/tasks/convert_server_config.rb
|
243
246
|
- lib/project_types/extension/tasks/converters/app_converter.rb
|
244
247
|
- lib/project_types/extension/tasks/converters/product_converter.rb
|
245
248
|
- lib/project_types/extension/tasks/converters/registration_converter.rb
|
246
|
-
- lib/project_types/extension/tasks/converters/server_config_converter.rb
|
247
249
|
- lib/project_types/extension/tasks/converters/validation_error_converter.rb
|
248
250
|
- lib/project_types/extension/tasks/converters/version_converter.rb
|
249
251
|
- lib/project_types/extension/tasks/create_extension.rb
|
252
|
+
- lib/project_types/extension/tasks/ensure_resource_url.rb
|
250
253
|
- lib/project_types/extension/tasks/fetch_specifications.rb
|
251
254
|
- lib/project_types/extension/tasks/find_npm_packages.rb
|
252
255
|
- lib/project_types/extension/tasks/find_package_from_json.rb
|
@@ -254,56 +257,39 @@ files:
|
|
254
257
|
- lib/project_types/extension/tasks/get_apps.rb
|
255
258
|
- lib/project_types/extension/tasks/get_extensions.rb
|
256
259
|
- lib/project_types/extension/tasks/get_product.rb
|
257
|
-
- lib/project_types/extension/tasks/
|
260
|
+
- lib/project_types/extension/tasks/merge_server_config.rb
|
258
261
|
- lib/project_types/extension/tasks/run_extension_command.rb
|
259
262
|
- lib/project_types/extension/tasks/update_draft.rb
|
260
263
|
- lib/project_types/extension/tasks/user_errors.rb
|
261
264
|
- lib/project_types/node/cli.rb
|
262
|
-
- lib/project_types/node/commands/connect.rb
|
263
|
-
- lib/project_types/node/commands/create.rb
|
264
|
-
- lib/project_types/node/commands/deploy.rb
|
265
|
-
- lib/project_types/node/commands/deploy/heroku.rb
|
266
|
-
- lib/project_types/node/commands/generate.rb
|
267
|
-
- lib/project_types/node/commands/open.rb
|
268
|
-
- lib/project_types/node/commands/serve.rb
|
269
|
-
- lib/project_types/node/commands/tunnel.rb
|
270
265
|
- lib/project_types/node/forms/create.rb
|
271
266
|
- lib/project_types/node/messages/messages.rb
|
272
267
|
- lib/project_types/php/cli.rb
|
273
|
-
- lib/project_types/php/commands/connect.rb
|
274
|
-
- lib/project_types/php/commands/create.rb
|
275
|
-
- lib/project_types/php/commands/deploy.rb
|
276
|
-
- lib/project_types/php/commands/deploy/heroku.rb
|
277
|
-
- lib/project_types/php/commands/open.rb
|
278
|
-
- lib/project_types/php/commands/serve.rb
|
279
|
-
- lib/project_types/php/commands/tunnel.rb
|
280
268
|
- lib/project_types/php/forms/create.rb
|
281
269
|
- lib/project_types/php/messages/messages.rb
|
282
270
|
- lib/project_types/rails/cli.rb
|
283
|
-
- lib/project_types/rails/commands/connect.rb
|
284
271
|
- lib/project_types/rails/commands/create.rb
|
285
|
-
- lib/project_types/rails/commands/deploy.rb
|
286
|
-
- lib/project_types/rails/commands/deploy/heroku.rb
|
287
|
-
- lib/project_types/rails/commands/generate.rb
|
288
|
-
- lib/project_types/rails/commands/generate/webhook.rb
|
289
|
-
- lib/project_types/rails/commands/open.rb
|
290
|
-
- lib/project_types/rails/commands/serve.rb
|
291
|
-
- lib/project_types/rails/commands/tunnel.rb
|
292
272
|
- lib/project_types/rails/forms/create.rb
|
293
273
|
- lib/project_types/rails/gem.rb
|
294
274
|
- lib/project_types/rails/messages/messages.rb
|
295
275
|
- lib/project_types/rails/ruby.rb
|
296
276
|
- lib/project_types/script/cli.rb
|
297
277
|
- lib/project_types/script/commands/create.rb
|
278
|
+
- lib/project_types/script/commands/javy.rb
|
298
279
|
- lib/project_types/script/commands/push.rb
|
299
280
|
- lib/project_types/script/config/extension_points.yml
|
300
281
|
- lib/project_types/script/errors.rb
|
282
|
+
- lib/project_types/script/forms/ask_app.rb
|
283
|
+
- lib/project_types/script/forms/ask_org.rb
|
284
|
+
- lib/project_types/script/forms/ask_script_uuid.rb
|
301
285
|
- lib/project_types/script/forms/create.rb
|
286
|
+
- lib/project_types/script/forms/run_against_shopify_org.rb
|
302
287
|
- lib/project_types/script/graphql/app_script_set.graphql
|
303
288
|
- lib/project_types/script/graphql/get_app_scripts.graphql
|
304
289
|
- lib/project_types/script/graphql/module_upload_url_generate.graphql
|
305
290
|
- lib/project_types/script/graphql/script_service_proxy.graphql
|
306
291
|
- lib/project_types/script/layers/application/build_script.rb
|
292
|
+
- lib/project_types/script/layers/application/connect_app.rb
|
307
293
|
- lib/project_types/script/layers/application/create_script.rb
|
308
294
|
- lib/project_types/script/layers/application/extension_points.rb
|
309
295
|
- lib/project_types/script/layers/application/project_dependencies.rb
|
@@ -312,7 +298,7 @@ files:
|
|
312
298
|
- lib/project_types/script/layers/domain/extension_point.rb
|
313
299
|
- lib/project_types/script/layers/domain/metadata.rb
|
314
300
|
- lib/project_types/script/layers/domain/push_package.rb
|
315
|
-
- lib/project_types/script/layers/domain/
|
301
|
+
- lib/project_types/script/layers/domain/script_config.rb
|
316
302
|
- lib/project_types/script/layers/domain/script_project.rb
|
317
303
|
- lib/project_types/script/layers/infrastructure/api_clients/partners_proxy_api_client.rb
|
318
304
|
- lib/project_types/script/layers/infrastructure/api_clients/script_service_api_client.rb
|
@@ -331,7 +317,6 @@ files:
|
|
331
317
|
- lib/project_types/script/layers/infrastructure/script_uploader.rb
|
332
318
|
- lib/project_types/script/layers/infrastructure/service_locator.rb
|
333
319
|
- lib/project_types/script/messages/messages.rb
|
334
|
-
- lib/project_types/script/tasks/ensure_env.rb
|
335
320
|
- lib/project_types/script/ui/error_handler.rb
|
336
321
|
- lib/project_types/script/ui/printing_spinner.rb
|
337
322
|
- lib/project_types/script/ui/strict_spinner.rb
|
@@ -358,9 +343,21 @@ files:
|
|
358
343
|
- lib/shopify_cli/app_type_detector.rb
|
359
344
|
- lib/shopify_cli/command.rb
|
360
345
|
- lib/shopify_cli/command/app_sub_command.rb
|
346
|
+
- lib/shopify_cli/command/project_command.rb
|
347
|
+
- lib/shopify_cli/command/sub_command.rb
|
361
348
|
- lib/shopify_cli/command_options.rb
|
362
349
|
- lib/shopify_cli/command_options/command_serve_options.rb
|
363
350
|
- lib/shopify_cli/commands.rb
|
351
|
+
- lib/shopify_cli/commands/app.rb
|
352
|
+
- lib/shopify_cli/commands/app/connect.rb
|
353
|
+
- lib/shopify_cli/commands/app/create.rb
|
354
|
+
- lib/shopify_cli/commands/app/create/node.rb
|
355
|
+
- lib/shopify_cli/commands/app/create/php.rb
|
356
|
+
- lib/shopify_cli/commands/app/create/rails.rb
|
357
|
+
- lib/shopify_cli/commands/app/deploy.rb
|
358
|
+
- lib/shopify_cli/commands/app/open.rb
|
359
|
+
- lib/shopify_cli/commands/app/serve.rb
|
360
|
+
- lib/shopify_cli/commands/app/tunnel.rb
|
364
361
|
- lib/shopify_cli/commands/config.rb
|
365
362
|
- lib/shopify_cli/commands/help.rb
|
366
363
|
- lib/shopify_cli/commands/login.rb
|
@@ -390,6 +387,8 @@ files:
|
|
390
387
|
- lib/shopify_cli/feature.rb
|
391
388
|
- lib/shopify_cli/form.rb
|
392
389
|
- lib/shopify_cli/git.rb
|
390
|
+
- lib/shopify_cli/github.rb
|
391
|
+
- lib/shopify_cli/github/issue_url_generator.rb
|
393
392
|
- lib/shopify_cli/helpers.rb
|
394
393
|
- lib/shopify_cli/helpers/haikunator.rb
|
395
394
|
- lib/shopify_cli/heroku.rb
|
@@ -420,10 +419,23 @@ files:
|
|
420
419
|
- lib/shopify_cli/resources/env_file.rb
|
421
420
|
- lib/shopify_cli/result.rb
|
422
421
|
- lib/shopify_cli/services.rb
|
422
|
+
- lib/shopify_cli/services/app/connect_service.rb
|
423
|
+
- lib/shopify_cli/services/app/create/node_service.rb
|
424
|
+
- lib/shopify_cli/services/app/create/php_service.rb
|
425
|
+
- lib/shopify_cli/services/app/create/rails_service.rb
|
426
|
+
- lib/shopify_cli/services/app/deploy/heroku/node_service.rb
|
427
|
+
- lib/shopify_cli/services/app/deploy/heroku/php_service.rb
|
428
|
+
- lib/shopify_cli/services/app/deploy/heroku/rails_service.rb
|
429
|
+
- lib/shopify_cli/services/app/open_service.rb
|
430
|
+
- lib/shopify_cli/services/app/serve/node_service.rb
|
431
|
+
- lib/shopify_cli/services/app/serve/php_service.rb
|
432
|
+
- lib/shopify_cli/services/app/serve/rails_service.rb
|
433
|
+
- lib/shopify_cli/services/app/tunnel/auth_service.rb
|
434
|
+
- lib/shopify_cli/services/app/tunnel/start_service.rb
|
435
|
+
- lib/shopify_cli/services/app/tunnel/stop_service.rb
|
423
436
|
- lib/shopify_cli/services/base_service.rb
|
424
437
|
- lib/shopify_cli/services/reporting_service.rb
|
425
438
|
- lib/shopify_cli/shopifolk.rb
|
426
|
-
- lib/shopify_cli/sub_command.rb
|
427
439
|
- lib/shopify_cli/task.rb
|
428
440
|
- lib/shopify_cli/tasks.rb
|
429
441
|
- lib/shopify_cli/tasks/confirm_store.rb
|
@@ -436,6 +448,7 @@ files:
|
|
436
448
|
- lib/shopify_cli/tasks/select_org_and_shop.rb
|
437
449
|
- lib/shopify_cli/tasks/update_dashboard_urls.rb
|
438
450
|
- lib/shopify_cli/theme/dev_server.rb
|
451
|
+
- lib/shopify_cli/theme/dev_server/cdn_fonts.rb
|
439
452
|
- lib/shopify_cli/theme/dev_server/certificate_manager.rb
|
440
453
|
- lib/shopify_cli/theme/dev_server/header_hash.rb
|
441
454
|
- lib/shopify_cli/theme/dev_server/hot-reload.js
|
@@ -450,13 +463,16 @@ files:
|
|
450
463
|
- lib/shopify_cli/theme/ignore_filter.rb
|
451
464
|
- lib/shopify_cli/theme/mime_type.rb
|
452
465
|
- lib/shopify_cli/theme/syncer.rb
|
466
|
+
- lib/shopify_cli/theme/syncer/error_reporter.rb
|
467
|
+
- lib/shopify_cli/theme/syncer/operation.rb
|
468
|
+
- lib/shopify_cli/theme/syncer/standard_reporter.rb
|
453
469
|
- lib/shopify_cli/theme/theme.rb
|
454
470
|
- lib/shopify_cli/transform_data_structure.rb
|
455
471
|
- lib/shopify_cli/tunnel.rb
|
456
472
|
- lib/shopify_cli/version.rb
|
457
473
|
- shopify-cli.gemspec
|
458
|
-
- shopify
|
459
|
-
-
|
474
|
+
- shopify-dev
|
475
|
+
- utilities/constants.rb
|
460
476
|
- utilities/docker.rb
|
461
477
|
- utilities/docker/container.rb
|
462
478
|
- utilities/utilities.rb
|
data/docs/_config.yml
DELETED
data/docs/app/node/index.md
DELETED
data/docs/app/rails/index.md
DELETED
data/docs/core/index.md
DELETED
data/docs/index.md
DELETED
data/install.sh
DELETED
@@ -1,30 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
require "shopify_cli"
|
3
|
-
|
4
|
-
module Extension
|
5
|
-
module Tasks
|
6
|
-
module Converters
|
7
|
-
module ServerConfigConverter
|
8
|
-
def self.from_hash(hash:, type:, registration_uuid:)
|
9
|
-
context.abort(context.message("tasks.errors.parse_error")) if hash.nil?
|
10
|
-
|
11
|
-
extension = Models::ServerConfig::Extension.new(
|
12
|
-
uuid: registration_uuid,
|
13
|
-
type: type.upcase,
|
14
|
-
user: Models::ServerConfig::User.new,
|
15
|
-
development: Models::ServerConfig::Development.new(
|
16
|
-
build_dir: hash.dig("development", "build_dir"),
|
17
|
-
renderer: Models::ServerConfig::DevelopmentRenderer.find(type),
|
18
|
-
entries: Models::ServerConfig::DevelopmentEntries.new(
|
19
|
-
main: hash.dig("development", "entries", "main")
|
20
|
-
)
|
21
|
-
),
|
22
|
-
extension_points: hash.dig("extension_points")
|
23
|
-
)
|
24
|
-
|
25
|
-
Models::ServerConfig::Root.new(extensions: [extension])
|
26
|
-
end
|
27
|
-
end
|
28
|
-
end
|
29
|
-
end
|
30
|
-
end
|
@@ -1,28 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
require "shopify_cli"
|
3
|
-
require "yaml"
|
4
|
-
|
5
|
-
module Extension
|
6
|
-
module Tasks
|
7
|
-
class LoadServerConfig < ShopifyCLI::Task
|
8
|
-
include SmartProperties
|
9
|
-
|
10
|
-
class << self
|
11
|
-
def call(file_name:, type:)
|
12
|
-
config = YAML.load_file(file_name)
|
13
|
-
project = ExtensionProject.current
|
14
|
-
Tasks::Converters::ServerConfigConverter.from_hash(
|
15
|
-
hash: config,
|
16
|
-
type: type,
|
17
|
-
registration_uuid: project.registration_uuid
|
18
|
-
)
|
19
|
-
rescue Psych::SyntaxError => e
|
20
|
-
raise(
|
21
|
-
ShopifyCLI::Abort,
|
22
|
-
ShopifyCLI::Context.message("core.yaml.error.invalid", file_name, e.message)
|
23
|
-
)
|
24
|
-
end
|
25
|
-
end
|
26
|
-
end
|
27
|
-
end
|
28
|
-
end
|
@@ -1,21 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
module Node
|
3
|
-
class Command
|
4
|
-
class Connect < ShopifyCLI::SubCommand
|
5
|
-
prerequisite_task ensure_project_type: :node
|
6
|
-
|
7
|
-
def call(*)
|
8
|
-
if ShopifyCLI::Project.has_current? && ShopifyCLI::Project.current.env
|
9
|
-
@ctx.puts(@ctx.message("node.connect.production_warning"))
|
10
|
-
end
|
11
|
-
|
12
|
-
app = ShopifyCLI::Connect.new(@ctx).default_connect("node")
|
13
|
-
@ctx.done(@ctx.message("node.connect.connected", app))
|
14
|
-
end
|
15
|
-
|
16
|
-
def self.help
|
17
|
-
ShopifyCLI::Context.message("node.connect.help", ShopifyCLI::TOOL_NAME, ShopifyCLI::TOOL_NAME)
|
18
|
-
end
|
19
|
-
end
|
20
|
-
end
|
21
|
-
end
|
@@ -1,125 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
module Node
|
3
|
-
class Command
|
4
|
-
class Create < ShopifyCLI::SubCommand
|
5
|
-
prerequisite_task :ensure_authenticated
|
6
|
-
|
7
|
-
options do |parser, flags|
|
8
|
-
# backwards compatibility allow 'title' for now
|
9
|
-
parser.on("--title=TITLE") { |t| flags[:title] = t }
|
10
|
-
parser.on("--name=NAME") { |t| flags[:title] = t }
|
11
|
-
parser.on("--organization_id=ID") { |id| flags[:organization_id] = id }
|
12
|
-
parser.on("--organization-id=ID") { |id| flags[:organization_id] = id }
|
13
|
-
parser.on("--store=MYSHOPIFYDOMAIN") { |url| flags[:shop_domain] = url }
|
14
|
-
# backwards compatibility allow 'shop domain' for now
|
15
|
-
parser.on("--shop_domain=MYSHOPIFYDOMAIN") { |url| flags[:shop_domain] = url }
|
16
|
-
parser.on("--shop-domain=MYSHOPIFYDOMAIN") { |url| flags[:shop_domain] = url }
|
17
|
-
parser.on("--type=APPTYPE") { |type| flags[:type] = type }
|
18
|
-
parser.on("--verbose") { flags[:verbose] = true }
|
19
|
-
end
|
20
|
-
|
21
|
-
def call(args, _name)
|
22
|
-
form = Forms::Create.ask(@ctx, args, options.flags)
|
23
|
-
return @ctx.puts(self.class.help) if form.nil?
|
24
|
-
|
25
|
-
check_node
|
26
|
-
check_npm
|
27
|
-
build(form.name)
|
28
|
-
|
29
|
-
ShopifyCLI::Project.write(
|
30
|
-
@ctx,
|
31
|
-
project_type: "node",
|
32
|
-
organization_id: form.organization_id,
|
33
|
-
)
|
34
|
-
|
35
|
-
api_client = ShopifyCLI::Tasks::CreateApiClient.call(
|
36
|
-
@ctx,
|
37
|
-
org_id: form.organization_id,
|
38
|
-
title: form.title,
|
39
|
-
type: form.type,
|
40
|
-
)
|
41
|
-
|
42
|
-
ShopifyCLI::Resources::EnvFile.new(
|
43
|
-
api_key: api_client["apiKey"],
|
44
|
-
secret: api_client["apiSecretKeys"].first["secret"],
|
45
|
-
shop: form.shop_domain,
|
46
|
-
scopes: "write_products,write_customers,write_draft_orders",
|
47
|
-
).write(@ctx)
|
48
|
-
|
49
|
-
partners_url = ShopifyCLI::PartnersAPI.partners_url_for(form.organization_id, api_client["id"])
|
50
|
-
|
51
|
-
@ctx.puts(@ctx.message("apps.create.info.created", form.title, partners_url))
|
52
|
-
@ctx.puts(@ctx.message("apps.create.info.serve", form.name, ShopifyCLI::TOOL_NAME, "node"))
|
53
|
-
unless ShopifyCLI::Shopifolk.acting_as_shopify_organization?
|
54
|
-
@ctx.puts(@ctx.message("apps.create.info.install", partners_url, form.title))
|
55
|
-
end
|
56
|
-
end
|
57
|
-
|
58
|
-
def self.help
|
59
|
-
ShopifyCLI::Context.message("node.create.help", ShopifyCLI::TOOL_NAME, ShopifyCLI::TOOL_NAME)
|
60
|
-
end
|
61
|
-
|
62
|
-
private
|
63
|
-
|
64
|
-
def check_node
|
65
|
-
cmd_path = @ctx.which("node")
|
66
|
-
@ctx.abort(@ctx.message("node.create.error.node_required")) if cmd_path.nil?
|
67
|
-
|
68
|
-
version, stat = @ctx.capture2e("node", "-v")
|
69
|
-
@ctx.abort(@ctx.message("node.create.error.node_version_failure")) unless stat.success?
|
70
|
-
|
71
|
-
@ctx.done(@ctx.message("node.create.node_version", version))
|
72
|
-
end
|
73
|
-
|
74
|
-
def check_npm
|
75
|
-
cmd_path = @ctx.which("npm")
|
76
|
-
@ctx.abort(@ctx.message("node.create.error.npm_required")) if cmd_path.nil?
|
77
|
-
|
78
|
-
version, stat = @ctx.capture2e("npm", "-v")
|
79
|
-
@ctx.abort(@ctx.message("node.create.error.npm_version_failure")) unless stat.success?
|
80
|
-
|
81
|
-
@ctx.done(@ctx.message("node.create.npm_version", version))
|
82
|
-
end
|
83
|
-
|
84
|
-
def set_npm_config
|
85
|
-
# check available npmrc (either user or system) for production registry
|
86
|
-
registry, _ = @ctx.capture2("npm config get @shopify:registry")
|
87
|
-
return if registry.include?("https://registry.yarnpkg.com")
|
88
|
-
|
89
|
-
# available npmrc doesn't have production registry =>
|
90
|
-
# set a project-based .npmrc
|
91
|
-
@ctx.system(
|
92
|
-
"npm",
|
93
|
-
"--userconfig",
|
94
|
-
"./.npmrc",
|
95
|
-
"config",
|
96
|
-
"set",
|
97
|
-
"@shopify:registry",
|
98
|
-
"https://registry.yarnpkg.com",
|
99
|
-
chdir: @ctx.root
|
100
|
-
)
|
101
|
-
end
|
102
|
-
|
103
|
-
def build(name)
|
104
|
-
ShopifyCLI::Git.clone("https://github.com/Shopify/shopify-app-node.git", name)
|
105
|
-
|
106
|
-
@ctx.root = File.join(@ctx.root, name)
|
107
|
-
|
108
|
-
set_npm_config
|
109
|
-
ShopifyCLI::JsDeps.install(@ctx, !options.flags[:verbose].nil?)
|
110
|
-
|
111
|
-
begin
|
112
|
-
@ctx.rm_r(".git")
|
113
|
-
@ctx.rm_r(".github")
|
114
|
-
@ctx.rm(File.join("server", "handlers", "client.js"))
|
115
|
-
@ctx.rename(
|
116
|
-
File.join("server", "handlers", "client.cli.js"),
|
117
|
-
File.join("server", "handlers", "client.js")
|
118
|
-
)
|
119
|
-
rescue Errno::ENOENT => e
|
120
|
-
@ctx.debug(e)
|
121
|
-
end
|
122
|
-
end
|
123
|
-
end
|
124
|
-
end
|
125
|
-
end
|