@capawesome/cli 2.0.0 → 2.0.2
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.
- package/CHANGELOG.md +18 -4
- package/dist/index.js +6 -1
- package/dist/utils/error.js +6 -0
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -2,17 +2,31 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file. See [commit-and-tag-version](https://github.com/absolute-version/commit-and-tag-version) for commit guidelines.
|
|
4
4
|
|
|
5
|
+
## [2.0.2](https://github.com/capawesome-team/cli/compare/v2.0.1...v2.0.2) (2025-08-24)
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
### Bug Fixes
|
|
9
|
+
|
|
10
|
+
* improve error messages for 500 and 503 status codes ([769ee5d](https://github.com/capawesome-team/cli/commit/769ee5dbd6535b7b58f516165bc02dbe9c40c531))
|
|
11
|
+
|
|
12
|
+
## [2.0.1](https://github.com/capawesome-team/cli/compare/v2.0.0...v2.0.1) (2025-08-24)
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
### Bug Fixes
|
|
16
|
+
|
|
17
|
+
* do not capture CLI errors ([0eacbab](https://github.com/capawesome-team/cli/commit/0eacbab054b314ce953493e9fe71a17e872d1066))
|
|
18
|
+
|
|
5
19
|
## [2.0.0](https://github.com/capawesome-team/cli/compare/v1.14.0...v2.0.0) (2025-08-23)
|
|
6
20
|
|
|
7
21
|
|
|
8
22
|
### ⚠ BREAKING CHANGES
|
|
9
23
|
|
|
10
|
-
* You should now call the CLI using `@capawesome/cli` instead of just `capawesome
|
|
11
|
-
* set npm minimum version to `8.0.0`
|
|
12
|
-
* set Node.js minimum version to `
|
|
24
|
+
* You should now call the CLI using `@capawesome/cli` instead of just `capawesome` (see `BREAKING.md`).
|
|
25
|
+
* set npm minimum version to `8.0.0` (see `BREAKING.md`)
|
|
26
|
+
* set Node.js minimum version to `18.0.0` (see `BREAKING.md`)
|
|
13
27
|
|
|
14
28
|
* deprecate `capawesome` command ([d59ea30](https://github.com/capawesome-team/cli/commit/d59ea305b7bb873071162b2ef896fc2f87b7ea21))
|
|
15
|
-
* set Node.js minimum version to `
|
|
29
|
+
* set Node.js minimum version to `18.0.0` ([396688c](https://github.com/capawesome-team/cli/commit/396688c96b69131dc0433e79af2d79eca19ee7fe))
|
|
16
30
|
* set npm minimum version to `8.0.0` ([8c382fa](https://github.com/capawesome-team/cli/commit/8c382fab37c53b0df8d7efc18e6a0efbb45e1c39))
|
|
17
31
|
|
|
18
32
|
|
package/dist/index.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import configService from './services/config.js';
|
|
3
3
|
import updateService from './services/update.js';
|
|
4
4
|
import { getMessageFromUnknownError } from './utils/error.js';
|
|
5
|
-
import { defineConfig, processConfig } from '@robingenz/zli';
|
|
5
|
+
import { defineConfig, processConfig, ZliError } from '@robingenz/zli';
|
|
6
6
|
import * as Sentry from '@sentry/node';
|
|
7
7
|
import consola from 'consola';
|
|
8
8
|
import pkg from '../package.json' with { type: 'json' };
|
|
@@ -33,6 +33,11 @@ const config = defineConfig({
|
|
|
33
33
|
},
|
|
34
34
|
});
|
|
35
35
|
const captureException = async (error) => {
|
|
36
|
+
// Check if the error is from the CLI itself
|
|
37
|
+
if (error instanceof ZliError) {
|
|
38
|
+
// Ignore CLI errors like "No command found."
|
|
39
|
+
return;
|
|
40
|
+
}
|
|
36
41
|
const environment = await configService.getValueForKey('ENVIRONMENT');
|
|
37
42
|
if (environment !== 'production') {
|
|
38
43
|
return;
|
package/dist/utils/error.js
CHANGED
|
@@ -21,6 +21,12 @@ const getErrorMessageFromAxiosError = (error) => {
|
|
|
21
21
|
else if (error.response?.status === 403) {
|
|
22
22
|
message = 'You do not have permission to access this resource.';
|
|
23
23
|
}
|
|
24
|
+
else if (error.response?.status === 500) {
|
|
25
|
+
message = 'An internal server error has occurred. Please try again later.';
|
|
26
|
+
}
|
|
27
|
+
else if (error.response?.status === 503) {
|
|
28
|
+
message = 'The service is currently unavailable. Please try again later.';
|
|
29
|
+
}
|
|
24
30
|
else if (error.response?.data?.message) {
|
|
25
31
|
message = error.response?.data?.message;
|
|
26
32
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@capawesome/cli",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.2",
|
|
4
4
|
"description": "The Capawesome Cloud Command Line Interface (CLI) to manage Live Updates and more.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"scripts": {
|
|
@@ -49,7 +49,7 @@
|
|
|
49
49
|
],
|
|
50
50
|
"dependencies": {
|
|
51
51
|
"@clack/prompts": "0.7.0",
|
|
52
|
-
"@robingenz/zli": "0.1.
|
|
52
|
+
"@robingenz/zli": "0.1.4",
|
|
53
53
|
"@sentry/node": "8.55.0",
|
|
54
54
|
"archiver": "7.0.1",
|
|
55
55
|
"axios": "1.8.4",
|