Skip to content

Commit e116ce4

Browse files
committed
warn if outdated
1 parent fc25436 commit e116ce4

4 files changed

Lines changed: 22 additions & 1 deletion

File tree

.changeset/add-update-warning.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@salesforce/b2c-cli': patch
3+
---
4+
5+
Add update notifications that warn users when a newer version of the CLI is available

docs/cli/index.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,12 @@ These flags are available on all commands that interact with B2C instances:
2727
| `--username`, `-u` | `SFCC_USERNAME` | Username for Basic Auth |
2828
| `--password`, `-p` | `SFCC_PASSWORD` | Password/access key for Basic Auth |
2929

30+
### Other Environment Variables
31+
32+
| Environment Variable | Description |
33+
|---------------------|-------------|
34+
| `B2C_SKIP_NEW_VERSION_CHECK` | Skip the new version availability check |
35+
3036
## Command Topics
3137

3238
### Instance Operations

packages/b2c-cli/package.json

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
"@oclif/plugin-not-found": "^3",
2020
"@oclif/plugin-plugins": "^5",
2121
"@oclif/plugin-version": "^2",
22+
"@oclif/plugin-warn-if-update-available": "^3",
2223
"@salesforce/b2c-tooling-sdk": "workspace:*",
2324
"cliui": "^9.0.1",
2425
"marked": "^15.0.0",
@@ -82,8 +83,14 @@
8283
"@oclif/plugin-plugins",
8384
"@oclif/plugin-not-found",
8485
"@oclif/plugin-version",
85-
"@oclif/plugin-autocomplete"
86+
"@oclif/plugin-autocomplete",
87+
"@oclif/plugin-warn-if-update-available"
8688
],
89+
"warn-if-update-available": {
90+
"timeoutInDays": 1,
91+
"frequency": 1,
92+
"frequencyUnit": "minutes"
93+
},
8794
"topicSeparator": " ",
8895
"topics": {
8996
"auth": {

pnpm-lock.yaml

Lines changed: 3 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)