@faststore/cli 3.99.1 → 4.0.0-dev.4

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.
Files changed (96) hide show
  1. package/README.md +48 -39
  2. package/bin/dev.cmd +1 -1
  3. package/bin/dev.js +5 -0
  4. package/bin/run.js +5 -0
  5. package/dist/index.js +2252 -19
  6. package/dist/index.js.map +1 -1
  7. package/package.json +46 -27
  8. package/bin/dev +0 -17
  9. package/bin/run +0 -5
  10. package/dist/__mocks__/hcms.d.ts +0 -62
  11. package/dist/__mocks__/hcms.d.ts.map +0 -1
  12. package/dist/__mocks__/hcms.js +0 -184
  13. package/dist/__mocks__/hcms.js.map +0 -1
  14. package/dist/commands/build.d.ts +0 -12
  15. package/dist/commands/build.d.ts.map +0 -1
  16. package/dist/commands/build.js +0 -118
  17. package/dist/commands/build.js.map +0 -1
  18. package/dist/commands/cms-sync.d.ts +0 -13
  19. package/dist/commands/cms-sync.d.ts.map +0 -1
  20. package/dist/commands/cms-sync.js +0 -39
  21. package/dist/commands/cms-sync.js.map +0 -1
  22. package/dist/commands/create.d.ts +0 -11
  23. package/dist/commands/create.d.ts.map +0 -1
  24. package/dist/commands/create.js +0 -38
  25. package/dist/commands/create.js.map +0 -1
  26. package/dist/commands/dev.d.ts +0 -12
  27. package/dist/commands/dev.d.ts.map +0 -1
  28. package/dist/commands/dev.js +0 -164
  29. package/dist/commands/dev.js.map +0 -1
  30. package/dist/commands/generate-graphql.d.ts +0 -12
  31. package/dist/commands/generate-graphql.d.ts.map +0 -1
  32. package/dist/commands/generate-graphql.js +0 -60
  33. package/dist/commands/generate-graphql.js.map +0 -1
  34. package/dist/commands/start.d.ts +0 -10
  35. package/dist/commands/start.d.ts.map +0 -1
  36. package/dist/commands/start.js +0 -40
  37. package/dist/commands/start.js.map +0 -1
  38. package/dist/commands/test.d.ts +0 -9
  39. package/dist/commands/test.d.ts.map +0 -1
  40. package/dist/commands/test.js +0 -79
  41. package/dist/commands/test.js.map +0 -1
  42. package/dist/index.d.ts +0 -16
  43. package/dist/index.d.ts.map +0 -1
  44. package/dist/utils/commands.d.ts +0 -2
  45. package/dist/utils/commands.d.ts.map +0 -1
  46. package/dist/utils/commands.js +0 -16
  47. package/dist/utils/commands.js.map +0 -1
  48. package/dist/utils/createNextjsPages.d.ts +0 -2
  49. package/dist/utils/createNextjsPages.d.ts.map +0 -1
  50. package/dist/utils/createNextjsPages.js +0 -83
  51. package/dist/utils/createNextjsPages.js.map +0 -1
  52. package/dist/utils/dependencies.d.ts +0 -8
  53. package/dist/utils/dependencies.d.ts.map +0 -1
  54. package/dist/utils/dependencies.js +0 -17
  55. package/dist/utils/dependencies.js.map +0 -1
  56. package/dist/utils/deprecations.d.ts +0 -7
  57. package/dist/utils/deprecations.d.ts.map +0 -1
  58. package/dist/utils/deprecations.js +0 -32
  59. package/dist/utils/deprecations.js.map +0 -1
  60. package/dist/utils/directory.d.ts +0 -26
  61. package/dist/utils/directory.d.ts.map +0 -1
  62. package/dist/utils/directory.js +0 -68
  63. package/dist/utils/directory.js.map +0 -1
  64. package/dist/utils/directory.test.d.ts +0 -2
  65. package/dist/utils/directory.test.d.ts.map +0 -1
  66. package/dist/utils/directory.test.js +0 -175
  67. package/dist/utils/directory.test.js.map +0 -1
  68. package/dist/utils/generate.d.ts +0 -7
  69. package/dist/utils/generate.d.ts.map +0 -1
  70. package/dist/utils/generate.js +0 -387
  71. package/dist/utils/generate.js.map +0 -1
  72. package/dist/utils/hcms.d.ts +0 -25
  73. package/dist/utils/hcms.d.ts.map +0 -1
  74. package/dist/utils/hcms.js +0 -118
  75. package/dist/utils/hcms.js.map +0 -1
  76. package/dist/utils/hcms.test.d.ts +0 -2
  77. package/dist/utils/hcms.test.d.ts.map +0 -1
  78. package/dist/utils/hcms.test.js +0 -189
  79. package/dist/utils/hcms.test.js.map +0 -1
  80. package/dist/utils/logger.d.ts +0 -2
  81. package/dist/utils/logger.d.ts.map +0 -1
  82. package/dist/utils/logger.js +0 -16
  83. package/dist/utils/logger.js.map +0 -1
  84. package/dist/utils/plugins.d.ts +0 -25
  85. package/dist/utils/plugins.d.ts.map +0 -1
  86. package/dist/utils/plugins.js +0 -235
  87. package/dist/utils/plugins.js.map +0 -1
  88. package/dist/utils/runCommandSync.d.ts +0 -7
  89. package/dist/utils/runCommandSync.d.ts.map +0 -1
  90. package/dist/utils/runCommandSync.js +0 -45
  91. package/dist/utils/runCommandSync.js.map +0 -1
  92. package/dist/utils/templates/myAccountPage.d.ts +0 -2
  93. package/dist/utils/templates/myAccountPage.d.ts.map +0 -1
  94. package/dist/utils/templates/myAccountPage.js +0 -49
  95. package/dist/utils/templates/myAccountPage.js.map +0 -1
  96. package/oclif.manifest.json +0 -1
package/README.md CHANGED
@@ -30,7 +30,7 @@ $ npm install -g @faststore/cli
30
30
  $ faststore COMMAND
31
31
  running command...
32
32
  $ faststore (--version)
33
- @faststore/cli/3.99.1 linux-x64 node-v20.20.2
33
+ @faststore/cli/4.0.0-dev.4 linux-x64 node-v24.13.0
34
34
  $ faststore --help [COMMAND]
35
35
  USAGE
36
36
  $ faststore COMMAND
@@ -42,12 +42,14 @@ USAGE
42
42
 
43
43
  <!-- commands -->
44
44
  * [`faststore build [ACCOUNT] [PATH]`](#faststore-build-account-path)
45
+ * [`faststore cache-graphql [STORE]`](#faststore-cache-graphql-store)
45
46
  * [`faststore cms-sync [PATH]`](#faststore-cms-sync-path)
46
47
  * [`faststore create [PATH]`](#faststore-create-path)
47
- * [`faststore dev [ACCOUNT] [PATH] [PORT]`](#faststore-dev-account-path-port)
48
- * [`faststore generate-graphql [PATH]`](#faststore-generate-graphql-path)
48
+ * [`faststore dev [PATH] [ACCOUNT] [PORT]`](#faststore-dev-path-account-port)
49
+ * [`faststore generate`](#faststore-generate)
49
50
  * [`faststore help [COMMAND]`](#faststore-help-command)
50
- * [`faststore start [ACCOUNT] [PATH] [PORT]`](#faststore-start-account-path-port)
51
+ * [`faststore prepare [PATH]`](#faststore-prepare-path)
52
+ * [`faststore serve [ACCOUNT] [PATH] [PORT]`](#faststore-serve-account-path-port)
51
53
  * [`faststore test [PATH]`](#faststore-test-path)
52
54
 
53
55
  ## `faststore build [ACCOUNT] [PATH]`
@@ -57,15 +59,27 @@ USAGE
57
59
  $ faststore build [ACCOUNT] [PATH] [--no-verify]
58
60
 
59
61
  ARGUMENTS
60
- ACCOUNT The account for which the Discovery is running. Currently noop.
61
- PATH The path where the FastStore being built is. Defaults to cwd.
62
+ [ACCOUNT] The account for which the Discovery is running. Currently noop.
63
+ [PATH] The path where the FastStore being built is. Defaults to cwd.
62
64
 
63
65
  FLAGS
64
66
  --no-verify Skips verification of faststore dependencies version string to prevent usage of packages outside npm
65
67
  registry.
66
68
  ```
67
69
 
68
- _See code: [dist/commands/build.js](https://github.com/vtex/faststore/blob/v3.99.1/dist/commands/build.js)_
70
+ ## `faststore cache-graphql [STORE]`
71
+
72
+ ```
73
+ USAGE
74
+ $ faststore cache-graphql [STORE] [--queries <value>] [--config <value>]
75
+
76
+ ARGUMENTS
77
+ [STORE] The path where the FastStore being built is or the persisted-document path. Defaults to cwd.
78
+
79
+ FLAGS
80
+ --config=<value> The path where the discovery.config is located
81
+ --queries=<value> The path to locate persisted-document file.
82
+ ```
69
83
 
70
84
  ## `faststore cms-sync [PATH]`
71
85
 
@@ -74,14 +88,12 @@ USAGE
74
88
  $ faststore cms-sync [PATH] [-d]
75
89
 
76
90
  ARGUMENTS
77
- PATH The path where the FastStore being synched with the CMS is. Defaults to cwd.
91
+ [PATH] The path where the FastStore being synched with the CMS is. Defaults to cwd.
78
92
 
79
93
  FLAGS
80
94
  -d, --dry-run
81
95
  ```
82
96
 
83
- _See code: [dist/commands/cms-sync.js](https://github.com/vtex/faststore/blob/v3.99.1/dist/commands/cms-sync.js)_
84
-
85
97
  ## `faststore create [PATH]`
86
98
 
87
99
  Creates a discovery folder based on the starter.store template.
@@ -91,7 +103,7 @@ USAGE
91
103
  $ faststore create [PATH]
92
104
 
93
105
  ARGUMENTS
94
- PATH The path where the Discovery folder will be created. Defaults to ./discovery.
106
+ [PATH] The path where the Discovery folder will be created. Defaults to ./discovery.
95
107
 
96
108
  DESCRIPTION
97
109
  Creates a discovery folder based on the starter.store template.
@@ -100,47 +112,38 @@ EXAMPLES
100
112
  $ yarn faststore create discovery
101
113
  ```
102
114
 
103
- _See code: [dist/commands/create.js](https://github.com/vtex/faststore/blob/v3.99.1/dist/commands/create.js)_
104
-
105
- ## `faststore dev [ACCOUNT] [PATH] [PORT]`
115
+ ## `faststore dev [PATH] [ACCOUNT] [PORT]`
106
116
 
107
117
  ```
108
118
  USAGE
109
- $ faststore dev [ACCOUNT] [PATH] [PORT] [--watch-plugins]
119
+ $ faststore dev [PATH] [ACCOUNT] [PORT] [--watch-plugins]
110
120
 
111
121
  ARGUMENTS
112
- ACCOUNT The account for which the Discovery is running. Currently noop.
113
- PATH The path where the FastStore being run is. Defaults to cwd.
114
- PORT The port where FastStore should run. Defaults to 3000.
122
+ [PATH] The path where the FastStore being run is. Defaults to cwd.
123
+ [ACCOUNT] The account for which the Discovery is running. Currently noop.
124
+ [PORT] The port where FastStore should run. Defaults to 3000.
115
125
 
116
126
  FLAGS
117
127
  --watch-plugins Enable watching for plugin changes
118
128
  ```
119
129
 
120
- _See code: [dist/commands/dev.js](https://github.com/vtex/faststore/blob/v3.99.1/dist/commands/dev.js)_
121
-
122
- ## `faststore generate-graphql [PATH]`
130
+ ## `faststore generate`
123
131
 
124
132
  ```
125
133
  USAGE
126
- $ faststore generate-graphql [PATH]
127
-
128
- ARGUMENTS
129
- PATH The path where the FastStore GraphQL customization is. Defaults to cwd.
134
+ $ faststore generate
130
135
  ```
131
136
 
132
- _See code: [dist/commands/generate-graphql.js](https://github.com/vtex/faststore/blob/v3.99.1/dist/commands/generate-graphql.js)_
133
-
134
137
  ## `faststore help [COMMAND]`
135
138
 
136
139
  Display help for faststore.
137
140
 
138
141
  ```
139
142
  USAGE
140
- $ faststore help [COMMAND] [-n]
143
+ $ faststore help [COMMAND...] [-n]
141
144
 
142
145
  ARGUMENTS
143
- COMMAND Command to show help for.
146
+ [COMMAND...] Command to show help for.
144
147
 
145
148
  FLAGS
146
149
  -n, --nested-commands Include all nested commands in the output.
@@ -149,21 +152,29 @@ DESCRIPTION
149
152
  Display help for faststore.
150
153
  ```
151
154
 
152
- _See code: [@oclif/plugin-help](https://github.com/oclif/plugin-help/blob/v5.1.22/src/commands/help.ts)_
155
+ _See code: [@oclif/plugin-help](https://github.com/oclif/plugin-help/blob/v6.2.37/src/commands/help.ts)_
153
156
 
154
- ## `faststore start [ACCOUNT] [PATH] [PORT]`
157
+ ## `faststore prepare [PATH]`
155
158
 
156
159
  ```
157
160
  USAGE
158
- $ faststore start [ACCOUNT] [PATH] [PORT]
161
+ $ faststore prepare [PATH]
159
162
 
160
163
  ARGUMENTS
161
- ACCOUNT The account for which the Discovery is running. Currently noop.
162
- PATH The path where the FastStore being run is. Defaults to cwd.
163
- PORT The port where FastStore should run. Defaults to 3000.
164
+ [PATH] The path where the FastStore being run is. Defaults to cwd.
165
+ ```
166
+
167
+ ## `faststore serve [ACCOUNT] [PATH] [PORT]`
168
+
164
169
  ```
170
+ USAGE
171
+ $ faststore serve [ACCOUNT] [PATH] [PORT]
165
172
 
166
- _See code: [dist/commands/start.js](https://github.com/vtex/faststore/blob/v3.99.1/dist/commands/start.js)_
173
+ ARGUMENTS
174
+ [ACCOUNT] The account for which the Discovery is running. Currently noop.
175
+ [PATH] The path where the FastStore being run is. Defaults to cwd.
176
+ [PORT] The port where FastStore should run. Defaults to 3000.
177
+ ```
167
178
 
168
179
  ## `faststore test [PATH]`
169
180
 
@@ -172,8 +183,6 @@ USAGE
172
183
  $ faststore test [PATH]
173
184
 
174
185
  ARGUMENTS
175
- PATH The path where the FastStore being tested is. Defaults to cwd.
186
+ [PATH] The path where the FastStore being tested is. Defaults to cwd.
176
187
  ```
177
-
178
- _See code: [dist/commands/test.js](https://github.com/vtex/faststore/blob/v3.99.1/dist/commands/test.js)_
179
188
  <!-- commandsstop -->
package/bin/dev.cmd CHANGED
@@ -1,3 +1,3 @@
1
1
  @echo off
2
2
 
3
- node "%~dp0\dev" %*
3
+ node --loader ts-node/esm --no-warnings=ExperimentalWarning "%~dp0\dev" %*
package/bin/dev.js ADDED
@@ -0,0 +1,5 @@
1
+ #!/usr/bin/env -S node --loader ts-node/esm --disable-warning=ExperimentalWarning
2
+
3
+ import { execute } from '@oclif/core'
4
+
5
+ await execute({ development: true, dir: import.meta.url })
package/bin/run.js ADDED
@@ -0,0 +1,5 @@
1
+ #!/usr/bin/env node
2
+
3
+ import { execute } from '@oclif/core'
4
+
5
+ await execute({ dir: import.meta.url })