@teambit/harmony.content.cli-reference 2.0.800 → 2.0.802

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.
@@ -1,4 +1,4 @@
1
1
  ---
2
- description: 'Bit command synopses. Bit version: 1.12.154'
2
+ description: 'Bit command synopses. Bit version: 1.12.156'
3
3
  labels: ['cli', 'mdx', 'docs']
4
4
  ---
@@ -74,6 +74,198 @@
74
74
  "group": "system",
75
75
  "private": false
76
76
  },
77
+ {
78
+ "name": "show <component-name>",
79
+ "alias": "",
80
+ "options": [
81
+ [
82
+ "j",
83
+ "json",
84
+ "return the component data in json format"
85
+ ],
86
+ [
87
+ "l",
88
+ "legacy",
89
+ "use the legacy bit show."
90
+ ],
91
+ [
92
+ "r",
93
+ "remote",
94
+ "show data for a remote component"
95
+ ],
96
+ [
97
+ "b",
98
+ "browser",
99
+ "open the component page in the browser"
100
+ ],
101
+ [
102
+ "c",
103
+ "compare",
104
+ "legacy-only. compare current file system component to its latest tagged version [default=latest]"
105
+ ]
106
+ ],
107
+ "description": "display component metadata, dependencies, and configuration",
108
+ "extendedDescription": "shows detailed information about a component including its version, dependencies, environment, and other metadata.\nnote: to see file changes made in a specific version, use `bit diff <component> <version> --parent`.",
109
+ "group": "info-analysis",
110
+ "private": false,
111
+ "arguments": [
112
+ {
113
+ "name": "component-name",
114
+ "description": "component name or component id"
115
+ }
116
+ ]
117
+ },
118
+ {
119
+ "name": "component-issues",
120
+ "alias": "",
121
+ "options": [
122
+ [
123
+ "j",
124
+ "json",
125
+ "output issues in json format"
126
+ ]
127
+ ],
128
+ "description": "list available component-issues",
129
+ "extendedDescription": "",
130
+ "group": "info-analysis",
131
+ "private": true
132
+ },
133
+ {
134
+ "name": "envs",
135
+ "alias": "env",
136
+ "options": [],
137
+ "description": "show components and their assigned environments",
138
+ "extendedDescription": "displays a table showing each workspace component and its corresponding environment.\nenvironments control how components are built, tested, linted, and deployed.",
139
+ "group": "component-config",
140
+ "private": false,
141
+ "commands": [
142
+ {
143
+ "name": "list",
144
+ "alias": "",
145
+ "options": [],
146
+ "description": "list all envs currently used in the workspace",
147
+ "extendedDescription": "",
148
+ "group": "component-config",
149
+ "private": false
150
+ },
151
+ {
152
+ "name": "get <component-name>",
153
+ "alias": "",
154
+ "options": [
155
+ [
156
+ "",
157
+ "services <string>",
158
+ "show information about the specific services only. for multiple services, separate by a comma and wrap with quotes"
159
+ ]
160
+ ],
161
+ "description": "show config information from a component's env",
162
+ "extendedDescription": "",
163
+ "group": "component-config",
164
+ "private": false,
165
+ "arguments": [
166
+ {
167
+ "name": "component-name",
168
+ "description": "the 'component name' or 'component id' of the component whose env you'd like to inspect"
169
+ }
170
+ ]
171
+ },
172
+ {
173
+ "name": "set <component-pattern> <env>",
174
+ "options": [],
175
+ "description": "Assigns one or more components a development environment (env)",
176
+ "group": "component-config",
177
+ "arguments": [
178
+ {
179
+ "name": "component-pattern",
180
+ "description": "component name, component id, or component pattern. use component pattern to select multiple components.\nwrap the pattern with quotes. use comma to separate patterns and \"!\" to exclude. e.g. \"ui/**, !ui/button\".\nuse '$' prefix to filter by states/attributes, e.g. '$deprecated', '$modified' or '$env:teambit.react/react'.\nuse `bit pattern --help` to understand patterns better and `bit pattern <pattern>` to validate the pattern."
181
+ },
182
+ {
183
+ "name": "env",
184
+ "description": "the env's component id (include version if not latest, e.g `teambit.community/envs/community-react@1.95.13`)"
185
+ }
186
+ ],
187
+ "examples": [
188
+ {
189
+ "cmd": "set ui/button teambit.react/react-env",
190
+ "description": "configures 'ui/button' to use the latest version of the 'teambit.react/react-env' env"
191
+ },
192
+ {
193
+ "cmd": "set ui/button teambit.community/envs/community-mdx@1.95.16",
194
+ "description": "configures 'ui/button' to use the 'teambit.community/envs/community-mdx@1.95.16' env"
195
+ },
196
+ {
197
+ "cmd": "set \"*/ui/**\" teambit.react/react-env",
198
+ "description": "configures all components that have the 'ui' namespace to use the latest version of the teambit.react/react-env env"
199
+ }
200
+ ]
201
+ },
202
+ {
203
+ "name": "unset <component-pattern>",
204
+ "options": [],
205
+ "description": "un-sets an env from components that were previously set by \"bit env set\" or by a component template",
206
+ "extendedDescription": "keep in mind that this doesn't remove envs that are set via variants.\nin only removes envs that appear in the .bitmap file, which were previously configured via \"bit env set\".\nthe purpose of this command is to reset previously assigned envs to either allow variants configure the env or use the base node env.\nyou can use a `<pattern>` for multiple component ids, such as `bit env unset \"org.scope/utils/**\"`.\nuse comma to separate patterns and '!' to exclude. e.g. 'ui/**, !ui/button'\nuse '$' prefix to filter by states/attributes, e.g. '$deprecated', '$modified' or '$env:teambit.react/react'.\nalways wrap the pattern with single quotes to avoid collision with shell commands.\nuse `bit pattern --help` to understand patterns better and `bit pattern <pattern>` to validate the pattern.\n",
207
+ "group": "component-config",
208
+ "arguments": [
209
+ {
210
+ "name": "component-pattern",
211
+ "description": "component name, component id, or component pattern. use component pattern to select multiple components.\nwrap the pattern with quotes. use comma to separate patterns and \"!\" to exclude. e.g. \"ui/**, !ui/button\".\nuse '$' prefix to filter by states/attributes, e.g. '$deprecated', '$modified' or '$env:teambit.react/react'.\nuse `bit pattern --help` to understand patterns better and `bit pattern <pattern>` to validate the pattern."
212
+ }
213
+ ]
214
+ },
215
+ {
216
+ "name": "replace <current-env> <new-env>",
217
+ "options": [],
218
+ "description": "replace an existing env with another env for all components using the old env",
219
+ "group": "component-config",
220
+ "arguments": [
221
+ {
222
+ "name": "current-env",
223
+ "description": "the component id of the env to be replaced"
224
+ },
225
+ {
226
+ "name": "new-env",
227
+ "description": "the component id of the new env"
228
+ }
229
+ ],
230
+ "examples": [
231
+ {
232
+ "cmd": "replace teambit.harmony/aspect teambit.harmony/node",
233
+ "description": "components configured to use the 'aspect' env will be configured to use the 'node' env, instead"
234
+ }
235
+ ]
236
+ },
237
+ {
238
+ "name": "update [env-id] [pattern]",
239
+ "options": [],
240
+ "description": "update a version of an env for all components using that env",
241
+ "group": "component-config",
242
+ "arguments": [
243
+ {
244
+ "name": "env-id",
245
+ "description": "the environment id (defaults to all envs). optionally, add a version (id@version), if no version is supplied will use the latest version on the remote."
246
+ },
247
+ {
248
+ "name": "pattern",
249
+ "description": "the components to update (defaults to all components). component name, component id, or component pattern. use component pattern to select multiple components.\nwrap the pattern with quotes. use comma to separate patterns and \"!\" to exclude. e.g. \"ui/**, !ui/button\".\nuse '$' prefix to filter by states/attributes, e.g. '$deprecated', '$modified' or '$env:teambit.react/react'.\nuse `bit pattern --help` to understand patterns better and `bit pattern <pattern>` to validate the pattern."
250
+ }
251
+ ],
252
+ "examples": [
253
+ {
254
+ "cmd": "envs update",
255
+ "description": "update all envs for all components in the workspace, to their latest version"
256
+ },
257
+ {
258
+ "cmd": "envs update scope.org/env '**/ui/**'",
259
+ "description": "update components in the \"ui\" namespace that use scope.org/env to use its latest version"
260
+ },
261
+ {
262
+ "cmd": "envs update scope.org/env@2.0.0",
263
+ "description": "update all components that use scope.org/env to version 2.0.0 (of this env)."
264
+ }
265
+ ]
266
+ }
267
+ ]
268
+ },
77
269
  {
78
270
  "name": "config",
79
271
  "alias": "",
@@ -261,198 +453,6 @@
261
453
  }
262
454
  ]
263
455
  },
264
- {
265
- "name": "component-issues",
266
- "alias": "",
267
- "options": [
268
- [
269
- "j",
270
- "json",
271
- "output issues in json format"
272
- ]
273
- ],
274
- "description": "list available component-issues",
275
- "extendedDescription": "",
276
- "group": "info-analysis",
277
- "private": true
278
- },
279
- {
280
- "name": "show <component-name>",
281
- "alias": "",
282
- "options": [
283
- [
284
- "j",
285
- "json",
286
- "return the component data in json format"
287
- ],
288
- [
289
- "l",
290
- "legacy",
291
- "use the legacy bit show."
292
- ],
293
- [
294
- "r",
295
- "remote",
296
- "show data for a remote component"
297
- ],
298
- [
299
- "b",
300
- "browser",
301
- "open the component page in the browser"
302
- ],
303
- [
304
- "c",
305
- "compare",
306
- "legacy-only. compare current file system component to its latest tagged version [default=latest]"
307
- ]
308
- ],
309
- "description": "display component metadata, dependencies, and configuration",
310
- "extendedDescription": "shows detailed information about a component including its version, dependencies, environment, and other metadata.\nnote: to see file changes made in a specific version, use `bit diff <component> <version> --parent`.",
311
- "group": "info-analysis",
312
- "private": false,
313
- "arguments": [
314
- {
315
- "name": "component-name",
316
- "description": "component name or component id"
317
- }
318
- ]
319
- },
320
- {
321
- "name": "envs",
322
- "alias": "env",
323
- "options": [],
324
- "description": "show components and their assigned environments",
325
- "extendedDescription": "displays a table showing each workspace component and its corresponding environment.\nenvironments control how components are built, tested, linted, and deployed.",
326
- "group": "component-config",
327
- "private": false,
328
- "commands": [
329
- {
330
- "name": "list",
331
- "alias": "",
332
- "options": [],
333
- "description": "list all envs currently used in the workspace",
334
- "extendedDescription": "",
335
- "group": "component-config",
336
- "private": false
337
- },
338
- {
339
- "name": "get <component-name>",
340
- "alias": "",
341
- "options": [
342
- [
343
- "",
344
- "services <string>",
345
- "show information about the specific services only. for multiple services, separate by a comma and wrap with quotes"
346
- ]
347
- ],
348
- "description": "show config information from a component's env",
349
- "extendedDescription": "",
350
- "group": "component-config",
351
- "private": false,
352
- "arguments": [
353
- {
354
- "name": "component-name",
355
- "description": "the 'component name' or 'component id' of the component whose env you'd like to inspect"
356
- }
357
- ]
358
- },
359
- {
360
- "name": "set <component-pattern> <env>",
361
- "options": [],
362
- "description": "Assigns one or more components a development environment (env)",
363
- "group": "component-config",
364
- "arguments": [
365
- {
366
- "name": "component-pattern",
367
- "description": "component name, component id, or component pattern. use component pattern to select multiple components.\nwrap the pattern with quotes. use comma to separate patterns and \"!\" to exclude. e.g. \"ui/**, !ui/button\".\nuse '$' prefix to filter by states/attributes, e.g. '$deprecated', '$modified' or '$env:teambit.react/react'.\nuse `bit pattern --help` to understand patterns better and `bit pattern <pattern>` to validate the pattern."
368
- },
369
- {
370
- "name": "env",
371
- "description": "the env's component id (include version if not latest, e.g `teambit.community/envs/community-react@1.95.13`)"
372
- }
373
- ],
374
- "examples": [
375
- {
376
- "cmd": "set ui/button teambit.react/react-env",
377
- "description": "configures 'ui/button' to use the latest version of the 'teambit.react/react-env' env"
378
- },
379
- {
380
- "cmd": "set ui/button teambit.community/envs/community-mdx@1.95.16",
381
- "description": "configures 'ui/button' to use the 'teambit.community/envs/community-mdx@1.95.16' env"
382
- },
383
- {
384
- "cmd": "set \"*/ui/**\" teambit.react/react-env",
385
- "description": "configures all components that have the 'ui' namespace to use the latest version of the teambit.react/react-env env"
386
- }
387
- ]
388
- },
389
- {
390
- "name": "unset <component-pattern>",
391
- "options": [],
392
- "description": "un-sets an env from components that were previously set by \"bit env set\" or by a component template",
393
- "extendedDescription": "keep in mind that this doesn't remove envs that are set via variants.\nin only removes envs that appear in the .bitmap file, which were previously configured via \"bit env set\".\nthe purpose of this command is to reset previously assigned envs to either allow variants configure the env or use the base node env.\nyou can use a `<pattern>` for multiple component ids, such as `bit env unset \"org.scope/utils/**\"`.\nuse comma to separate patterns and '!' to exclude. e.g. 'ui/**, !ui/button'\nuse '$' prefix to filter by states/attributes, e.g. '$deprecated', '$modified' or '$env:teambit.react/react'.\nalways wrap the pattern with single quotes to avoid collision with shell commands.\nuse `bit pattern --help` to understand patterns better and `bit pattern <pattern>` to validate the pattern.\n",
394
- "group": "component-config",
395
- "arguments": [
396
- {
397
- "name": "component-pattern",
398
- "description": "component name, component id, or component pattern. use component pattern to select multiple components.\nwrap the pattern with quotes. use comma to separate patterns and \"!\" to exclude. e.g. \"ui/**, !ui/button\".\nuse '$' prefix to filter by states/attributes, e.g. '$deprecated', '$modified' or '$env:teambit.react/react'.\nuse `bit pattern --help` to understand patterns better and `bit pattern <pattern>` to validate the pattern."
399
- }
400
- ]
401
- },
402
- {
403
- "name": "replace <current-env> <new-env>",
404
- "options": [],
405
- "description": "replace an existing env with another env for all components using the old env",
406
- "group": "component-config",
407
- "arguments": [
408
- {
409
- "name": "current-env",
410
- "description": "the component id of the env to be replaced"
411
- },
412
- {
413
- "name": "new-env",
414
- "description": "the component id of the new env"
415
- }
416
- ],
417
- "examples": [
418
- {
419
- "cmd": "replace teambit.harmony/aspect teambit.harmony/node",
420
- "description": "components configured to use the 'aspect' env will be configured to use the 'node' env, instead"
421
- }
422
- ]
423
- },
424
- {
425
- "name": "update [env-id] [pattern]",
426
- "options": [],
427
- "description": "update a version of an env for all components using that env",
428
- "group": "component-config",
429
- "arguments": [
430
- {
431
- "name": "env-id",
432
- "description": "the environment id (defaults to all envs). optionally, add a version (id@version), if no version is supplied will use the latest version on the remote."
433
- },
434
- {
435
- "name": "pattern",
436
- "description": "the components to update (defaults to all components). component name, component id, or component pattern. use component pattern to select multiple components.\nwrap the pattern with quotes. use comma to separate patterns and \"!\" to exclude. e.g. \"ui/**, !ui/button\".\nuse '$' prefix to filter by states/attributes, e.g. '$deprecated', '$modified' or '$env:teambit.react/react'.\nuse `bit pattern --help` to understand patterns better and `bit pattern <pattern>` to validate the pattern."
437
- }
438
- ],
439
- "examples": [
440
- {
441
- "cmd": "envs update",
442
- "description": "update all envs for all components in the workspace, to their latest version"
443
- },
444
- {
445
- "cmd": "envs update scope.org/env '**/ui/**'",
446
- "description": "update components in the \"ui\" namespace that use scope.org/env to use its latest version"
447
- },
448
- {
449
- "cmd": "envs update scope.org/env@2.0.0",
450
- "description": "update all components that use scope.org/env to version 2.0.0 (of this env)."
451
- }
452
- ]
453
- }
454
- ]
455
- },
456
456
  {
457
457
  "name": "start [component-pattern]",
458
458
  "alias": "c",
@@ -1018,6 +1018,27 @@
1018
1018
  }
1019
1019
  ]
1020
1020
  },
1021
+ {
1022
+ "name": "script [script-name]",
1023
+ "alias": "",
1024
+ "options": [
1025
+ [
1026
+ "l",
1027
+ "list",
1028
+ "list all available scripts from all environments"
1029
+ ]
1030
+ ],
1031
+ "description": "run a script defined by the environment",
1032
+ "extendedDescription": "executes custom scripts defined by component environments.\nscripts can be shell commands or JavaScript functions defined in env.scripts().\nruns the script for all components grouped by their environment.\nuse --list to see all available scripts.",
1033
+ "group": "development",
1034
+ "private": false,
1035
+ "arguments": [
1036
+ {
1037
+ "name": "script-name",
1038
+ "description": "the name of the script to run (e.g., \"generate-svg\", \"pre-snap\")"
1039
+ }
1040
+ ]
1041
+ },
1021
1042
  {
1022
1043
  "name": "list [remote-scope]",
1023
1044
  "alias": "ls",
package/cli-reference.mdx CHANGED
@@ -2213,6 +2213,26 @@ optionally, provide [pattern] to limit the fork to specific components
2213
2213
 
2214
2214
  ---
2215
2215
 
2216
+ ## script
2217
+
2218
+ **Description**: run a script defined by the environment
2219
+ executes custom scripts defined by component environments.
2220
+ scripts can be shell commands or JavaScript functions defined in env.scripts().
2221
+ runs the script for all components grouped by their environment.
2222
+ use --list to see all available scripts.
2223
+
2224
+ `bit script [script-name]`
2225
+
2226
+ | **Arg** | **Description** |
2227
+ | ------------- | :--------------------------------------------------------------: |
2228
+ | `script-name` | the name of the script to run (e.g., "generate-svg", "pre-snap") |
2229
+
2230
+ | **Option** | **Option alias** | **Description** |
2231
+ | ---------- | :--------------: | ------------------------------------------------ |
2232
+ | `--list` | `-l` | list all available scripts from all environments |
2233
+
2234
+ ---
2235
+
2216
2236
  ## set-peer
2217
2237
 
2218
2238
  **Description**: configure component to always be installed as peer dependency
@@ -1,4 +1,4 @@
1
1
  ---
2
- description: 'Bit command synopses. Bit version: 1.12.154'
2
+ description: 'Bit command synopses. Bit version: 1.12.156'
3
3
  labels: ['cli', 'mdx', 'docs']
4
4
  ---