@teambit/harmony.content.cli-reference 2.0.1267 → 2.0.1269

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: 2.2.57'
2
+ description: 'Bit command synopses. Bit version: 2.2.59'
3
3
  labels: ['cli', 'mdx', 'docs']
4
4
  ---
@@ -5953,6 +5953,52 @@
5953
5953
  "private": false,
5954
5954
  "skipWorkspace": true
5955
5955
  },
5956
+ {
5957
+ "name": "gc",
5958
+ "alias": "",
5959
+ "options": [
5960
+ [
5961
+ "d",
5962
+ "dry-run",
5963
+ "show what would be removed without removing anything"
5964
+ ],
5965
+ [
5966
+ "",
5967
+ "keep-versions <number>",
5968
+ "keep the last N versions of each workspace component, so their recent history stays available offline"
5969
+ ],
5970
+ [
5971
+ "",
5972
+ "backup",
5973
+ "move the objects into a \"deleted-objects\" directory instead of deleting them. frees no disk space"
5974
+ ],
5975
+ [
5976
+ "",
5977
+ "restore",
5978
+ "bring back everything previous runs moved aside with --backup, and empty that directory"
5979
+ ],
5980
+ [
5981
+ "",
5982
+ "restore-overwrite",
5983
+ "same as --restore, but overwrite objects that already exist"
5984
+ ],
5985
+ [
5986
+ "v",
5987
+ "verbose",
5988
+ "log every object being removed"
5989
+ ],
5990
+ [
5991
+ "j",
5992
+ "json",
5993
+ "return the results in json format"
5994
+ ]
5995
+ ],
5996
+ "description": "remove objects from the local scope that are no longer needed",
5997
+ "extendedDescription": "a workspace keeps every version of every component it has ever imported. each new version brings\nthe source files of that version with it, and nothing removes the ones it superseded, so the local\nscope keeps growing - often to several gigabytes.\n\nthis command removes the versions nothing points at anymore. it keeps the version each component is\nchecked out at, every head (of the workspace, of its lanes and of the remotes it tracks), anything\nsnapped locally and not exported yet, and the dependencies of all of those. everything it removes\ncan be fetched again from the remote on demand, which bit already does whenever a version it needs\nis not in the local scope.\n\nthe trade-off is that history is no longer local: \"bit log\", \"bit blame\" and diffing against an old\nversion will fetch from the remote instead of answering offline. use --keep-versions to keep the\nlast few versions of each workspace component if that matters to you.\n\nrun with --dry-run first to see how much there is to gain.\n\nin a bare scope (a scope that is not backed by a workspace) this instead runs the collector that\nkeeps all history, since there the scope is the source of truth rather than a cache.",
5998
+ "group": "system",
5999
+ "private": false,
6000
+ "skipWorkspace": true
6001
+ },
5956
6002
  {
5957
6003
  "name": "rename <current-name> <new-name>",
5958
6004
  "alias": "",
package/cli-reference.mdx CHANGED
@@ -1132,6 +1132,42 @@ supports check mode to verify formatting without making changes.
1132
1132
 
1133
1133
  ---
1134
1134
 
1135
+ ## gc
1136
+
1137
+ **Description**: remove objects from the local scope that are no longer needed
1138
+ a workspace keeps every version of every component it has ever imported. each new version brings
1139
+ the source files of that version with it, and nothing removes the ones it superseded, so the local
1140
+ scope keeps growing - often to several gigabytes.
1141
+
1142
+ this command removes the versions nothing points at anymore. it keeps the version each component is
1143
+ checked out at, every head (of the workspace, of its lanes and of the remotes it tracks), anything
1144
+ snapped locally and not exported yet, and the dependencies of all of those. everything it removes
1145
+ can be fetched again from the remote on demand, which bit already does whenever a version it needs
1146
+ is not in the local scope.
1147
+
1148
+ the trade-off is that history is no longer local: "bit log", "bit blame" and diffing against an old
1149
+ version will fetch from the remote instead of answering offline. use --keep-versions to keep the
1150
+ last few versions of each workspace component if that matters to you.
1151
+
1152
+ run with --dry-run first to see how much there is to gain.
1153
+
1154
+ in a bare scope (a scope that is not backed by a workspace) this instead runs the collector that
1155
+ keeps all history, since there the scope is the source of truth rather than a cache.
1156
+
1157
+ `bit gc`
1158
+
1159
+ | **Option** | **Option alias** | **Description** |
1160
+ | -------------------------- | :--------------: | ----------------------------------------------------------------------------------------------------- |
1161
+ | `--dry-run` | `-d` | show what would be removed without removing anything |
1162
+ | `--keep-versions <number>` | | keep the last N versions of each workspace component, so their recent history stays available offline |
1163
+ | `--backup` | | move the objects into a "deleted-objects" directory instead of deleting them. frees no disk space |
1164
+ | `--restore` | | bring back everything previous runs moved aside with --backup, and empty that directory |
1165
+ | `--restore-overwrite` | | same as --restore, but overwrite objects that already exist |
1166
+ | `--verbose` | `-v` | log every object being removed |
1167
+ | `--json` | `-j` | return the results in json format |
1168
+
1169
+ ---
1170
+
1135
1171
  ## git
1136
1172
 
1137
1173
  **Description**: Git utilities for Bit repositories
@@ -1,4 +1,4 @@
1
1
  ---
2
- description: 'Bit command synopses. Bit version: 2.2.57'
2
+ description: 'Bit command synopses. Bit version: 2.2.59'
3
3
  labels: ['cli', 'mdx', 'docs']
4
4
  ---
@@ -5953,6 +5953,52 @@
5953
5953
  "private": false,
5954
5954
  "skipWorkspace": true
5955
5955
  },
5956
+ {
5957
+ "name": "gc",
5958
+ "alias": "",
5959
+ "options": [
5960
+ [
5961
+ "d",
5962
+ "dry-run",
5963
+ "show what would be removed without removing anything"
5964
+ ],
5965
+ [
5966
+ "",
5967
+ "keep-versions <number>",
5968
+ "keep the last N versions of each workspace component, so their recent history stays available offline"
5969
+ ],
5970
+ [
5971
+ "",
5972
+ "backup",
5973
+ "move the objects into a \"deleted-objects\" directory instead of deleting them. frees no disk space"
5974
+ ],
5975
+ [
5976
+ "",
5977
+ "restore",
5978
+ "bring back everything previous runs moved aside with --backup, and empty that directory"
5979
+ ],
5980
+ [
5981
+ "",
5982
+ "restore-overwrite",
5983
+ "same as --restore, but overwrite objects that already exist"
5984
+ ],
5985
+ [
5986
+ "v",
5987
+ "verbose",
5988
+ "log every object being removed"
5989
+ ],
5990
+ [
5991
+ "j",
5992
+ "json",
5993
+ "return the results in json format"
5994
+ ]
5995
+ ],
5996
+ "description": "remove objects from the local scope that are no longer needed",
5997
+ "extendedDescription": "a workspace keeps every version of every component it has ever imported. each new version brings\nthe source files of that version with it, and nothing removes the ones it superseded, so the local\nscope keeps growing - often to several gigabytes.\n\nthis command removes the versions nothing points at anymore. it keeps the version each component is\nchecked out at, every head (of the workspace, of its lanes and of the remotes it tracks), anything\nsnapped locally and not exported yet, and the dependencies of all of those. everything it removes\ncan be fetched again from the remote on demand, which bit already does whenever a version it needs\nis not in the local scope.\n\nthe trade-off is that history is no longer local: \"bit log\", \"bit blame\" and diffing against an old\nversion will fetch from the remote instead of answering offline. use --keep-versions to keep the\nlast few versions of each workspace component if that matters to you.\n\nrun with --dry-run first to see how much there is to gain.\n\nin a bare scope (a scope that is not backed by a workspace) this instead runs the collector that\nkeeps all history, since there the scope is the source of truth rather than a cache.",
5998
+ "group": "system",
5999
+ "private": false,
6000
+ "skipWorkspace": true
6001
+ },
5956
6002
  {
5957
6003
  "name": "rename <current-name> <new-name>",
5958
6004
  "alias": "",