Skip to content

Commit c70751a

Browse files
Clarify app config link flag descriptions
1 parent f1b8250 commit c70751a

5 files changed

Lines changed: 23 additions & 13 deletions

File tree

‎.changeset/config-link-flag-error.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@
22
'@shopify/app': patch
33
---
44

5-
Recommend `--file-name` when `app config link` receives both `--config` and `--client-id`
5+
Clarify `app config link` flags and recommend `--file-name` when both `--config` and `--client-id` are provided

‎docs-shopify.dev/generated/generated_docs_data_v2.json‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -504,7 +504,7 @@
504504
"syntaxKind": "PropertySignature",
505505
"name": "--client-id <value>",
506506
"value": "string",
507-
"description": "The Client ID of your app. Required if non interactive.",
507+
"description": "The Client ID of the remote app to link. Use --file-name to specify the destination configuration file. Required if non interactive.",
508508
"isOptional": true,
509509
"environmentValue": "SHOPIFY_FLAG_CLIENT_ID"
510510
},
@@ -513,7 +513,7 @@
513513
"syntaxKind": "PropertySignature",
514514
"name": "--file-name <value>",
515515
"value": "string",
516-
"description": "The name of the app configuration file to create or overwrite.",
516+
"description": "The name of the app configuration file to create or overwrite. Requires --force to overwrite an existing file.",
517517
"isOptional": true,
518518
"environmentValue": "SHOPIFY_FLAG_APP_CONFIG_FILE_NAME"
519519
},
@@ -585,12 +585,12 @@
585585
"syntaxKind": "PropertySignature",
586586
"name": "-c, --config <value>",
587587
"value": "string",
588-
"description": "The name of the app configuration.",
588+
"description": "The name of the local app configuration to read and overwrite. Use --file-name instead when specifying --client-id.",
589589
"isOptional": true,
590590
"environmentValue": "SHOPIFY_FLAG_APP_CONFIG"
591591
}
592592
],
593-
"value": "export interface appconfiglink {\n /**\n * Alias of the Shopify account to use for authentication.\n * @environment SHOPIFY_FLAG_AUTH_ALIAS\n */\n '--auth-alias <value>'?: string\n\n /**\n * The Client ID of your app. Required if non interactive.\n * @environment SHOPIFY_FLAG_CLIENT_ID\n */\n '--client-id <value>'?: string\n\n /**\n * The name of the app configuration.\n * @environment SHOPIFY_FLAG_APP_CONFIG\n */\n '-c, --config <value>'?: string\n\n /**\n * The name of the app configuration file to create or overwrite.\n * @environment SHOPIFY_FLAG_APP_CONFIG_FILE_NAME\n */\n '--file-name <value>'?: string\n\n /**\n * Overwrite an existing configuration file without prompting.\n * @environment SHOPIFY_FLAG_FORCE\n */\n '--force'?: ''\n\n /**\n * Print the command's JSON schemas.\n * @environment SHOPIFY_FLAG_JSON_SCHEMA\n */\n '--json-schema'?: ''\n\n /**\n * Disable color output.\n * @environment SHOPIFY_FLAG_NO_COLOR\n */\n '--no-color'?: ''\n\n /**\n * Disable interactive prompts and browser authentication.\n * @environment SHOPIFY_FLAG_NO_INPUT\n */\n '--no-input'?: ''\n\n /**\n * The path to your app directory.\n * @environment SHOPIFY_FLAG_PATH\n */\n '--path <value>'?: string\n\n /**\n * Reset all your settings.\n * @environment SHOPIFY_FLAG_RESET\n */\n '--reset'?: ''\n\n /**\n * Increase the verbosity of the output. May include sensitive data.\n * @environment SHOPIFY_FLAG_VERBOSE\n */\n '--verbose'?: ''\n}"
593+
"value": "export interface appconfiglink {\n /**\n * Alias of the Shopify account to use for authentication.\n * @environment SHOPIFY_FLAG_AUTH_ALIAS\n */\n '--auth-alias <value>'?: string\n\n /**\n * The Client ID of the remote app to link. Use --file-name to specify the destination configuration file. Required if non interactive.\n * @environment SHOPIFY_FLAG_CLIENT_ID\n */\n '--client-id <value>'?: string\n\n /**\n * The name of the local app configuration to read and overwrite. Use --file-name instead when specifying --client-id.\n * @environment SHOPIFY_FLAG_APP_CONFIG\n */\n '-c, --config <value>'?: string\n\n /**\n * The name of the app configuration file to create or overwrite. Requires --force to overwrite an existing file.\n * @environment SHOPIFY_FLAG_APP_CONFIG_FILE_NAME\n */\n '--file-name <value>'?: string\n\n /**\n * Overwrite an existing configuration file without prompting.\n * @environment SHOPIFY_FLAG_FORCE\n */\n '--force'?: ''\n\n /**\n * Print the command's JSON schemas.\n * @environment SHOPIFY_FLAG_JSON_SCHEMA\n */\n '--json-schema'?: ''\n\n /**\n * Disable color output.\n * @environment SHOPIFY_FLAG_NO_COLOR\n */\n '--no-color'?: ''\n\n /**\n * Disable interactive prompts and browser authentication.\n * @environment SHOPIFY_FLAG_NO_INPUT\n */\n '--no-input'?: ''\n\n /**\n * The path to your app directory.\n * @environment SHOPIFY_FLAG_PATH\n */\n '--path <value>'?: string\n\n /**\n * Reset all your settings.\n * @environment SHOPIFY_FLAG_RESET\n */\n '--reset'?: ''\n\n /**\n * Increase the verbosity of the output. May include sensitive data.\n * @environment SHOPIFY_FLAG_VERBOSE\n */\n '--verbose'?: ''\n}"
594594
}
595595
},
596596
"appconfigpull": {

‎packages/app/src/cli/commands/app/config/link.ts‎

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,13 @@ export default class ConfigLink extends AppLinkedCommand {
1919
static flags = {
2020
...globalFlags,
2121
...appFlags,
22+
config: Flags.string({
23+
hidden: false,
24+
char: 'c',
25+
description:
26+
'The name of the local app configuration to read and overwrite. Use --file-name instead when specifying --client-id.',
27+
env: 'SHOPIFY_FLAG_APP_CONFIG',
28+
}),
2229
'organization-id': Flags.string({
2330
hidden: true,
2431
env: 'SHOPIFY_FLAG_ORGANIZATION_ID',
@@ -28,13 +35,15 @@ export default class ConfigLink extends AppLinkedCommand {
2835
'client-id': requiredIfNonInteractive(
2936
Flags.string({
3037
hidden: false,
31-
description: 'The Client ID of your app.',
38+
description:
39+
'The Client ID of the remote app to link. Use --file-name to specify the destination configuration file.',
3240
env: 'SHOPIFY_FLAG_CLIENT_ID',
3341
}),
3442
),
3543
'file-name': Flags.string({
3644
hidden: false,
37-
description: 'The name of the app configuration file to create or overwrite.',
45+
description:
46+
'The name of the app configuration file to create or overwrite. Requires --force to overwrite an existing file.',
3847
env: 'SHOPIFY_FLAG_APP_CONFIG_FILE_NAME',
3948
exclusive: ['config'],
4049
}),

‎packages/cli/README.md‎

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -415,19 +415,20 @@ USAGE
415415
416416
FLAGS
417417
-c, --config=<value>
418-
The name of the app configuration.
418+
The name of the local app configuration to read and overwrite. Use --file-name instead when specifying --client-id.
419419
[env: SHOPIFY_FLAG_APP_CONFIG]
420420
421421
--auth-alias=<value>
422422
Alias of the Shopify account to use for authentication.
423423
[env: SHOPIFY_FLAG_AUTH_ALIAS]
424424
425425
--client-id=<value>
426-
The Client ID of your app. Required if non interactive.
426+
The Client ID of the remote app to link. Use --file-name to specify the destination configuration file. Required if
427+
non interactive.
427428
[env: SHOPIFY_FLAG_CLIENT_ID]
428429
429430
--file-name=<value>
430-
The name of the app configuration file to create or overwrite.
431+
The name of the app configuration file to create or overwrite. Requires --force to overwrite an existing file.
431432
[env: SHOPIFY_FLAG_APP_CONFIG_FILE_NAME]
432433
433434
--force

‎packages/cli/oclif.manifest.json‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -536,7 +536,7 @@
536536
"type": "option"
537537
},
538538
"client-id": {
539-
"description": "The Client ID of your app. Required if non interactive.",
539+
"description": "The Client ID of the remote app to link. Use --file-name to specify the destination configuration file. Required if non interactive.",
540540
"env": "SHOPIFY_FLAG_CLIENT_ID",
541541
"hasDynamicHelp": false,
542542
"hidden": false,
@@ -546,7 +546,7 @@
546546
},
547547
"config": {
548548
"char": "c",
549-
"description": "The name of the app configuration.",
549+
"description": "The name of the local app configuration to read and overwrite. Use --file-name instead when specifying --client-id.",
550550
"env": "SHOPIFY_FLAG_APP_CONFIG",
551551
"hasDynamicHelp": false,
552552
"hidden": false,
@@ -555,7 +555,7 @@
555555
"type": "option"
556556
},
557557
"file-name": {
558-
"description": "The name of the app configuration file to create or overwrite.",
558+
"description": "The name of the app configuration file to create or overwrite. Requires --force to overwrite an existing file.",
559559
"env": "SHOPIFY_FLAG_APP_CONFIG_FILE_NAME",
560560
"exclusive": [
561561
"config"

0 commit comments

Comments
 (0)