@shopware-ag/shopware-cli 0.6.31 → 0.6.33
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/lib.js +12 -0
- package/package.json +10 -9
package/lib.js
CHANGED
|
@@ -6,8 +6,18 @@ const path = require("path");
|
|
|
6
6
|
const JSZip = require("jszip");
|
|
7
7
|
const tar = require("tar");
|
|
8
8
|
const axios = require("axios");
|
|
9
|
+
const ProxyAgent = require("proxy-agent");
|
|
9
10
|
const { spawnSync } = require("child_process");
|
|
10
11
|
|
|
12
|
+
const proxyUrl =
|
|
13
|
+
process.env.HTTPS_PROXY ||
|
|
14
|
+
process.env.https_proxy ||
|
|
15
|
+
process.env.HTTP_PROXY ||
|
|
16
|
+
process.env.http_proxy ||
|
|
17
|
+
null;
|
|
18
|
+
|
|
19
|
+
const agent = proxyUrl ? new ProxyAgent(proxyUrl) : undefined;
|
|
20
|
+
|
|
11
21
|
const getArchive = () => {
|
|
12
22
|
let target = `${process.platform}-${process.arch}`;
|
|
13
23
|
const archive = archives[target];
|
|
@@ -180,6 +190,8 @@ const download = async (url, filename) => {
|
|
|
180
190
|
url: url,
|
|
181
191
|
responseType: "stream",
|
|
182
192
|
timeout: 300000, // 5min
|
|
193
|
+
httpAgent: agent,
|
|
194
|
+
httpsAgent: agent,
|
|
183
195
|
});
|
|
184
196
|
|
|
185
197
|
const writer = fs.createWriteStream(filename);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@shopware-ag/shopware-cli",
|
|
3
|
-
"version": "0.6.
|
|
3
|
+
"version": "0.6.33",
|
|
4
4
|
"description": "Shopware CLI helps Shopware developers manage extensions",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"postinstall": "node install.js",
|
|
@@ -26,55 +26,56 @@
|
|
|
26
26
|
"dependencies": {
|
|
27
27
|
"axios": "^1.8.2",
|
|
28
28
|
"jszip": "^3.10.1",
|
|
29
|
+
"proxy-agent": "^6.5.0",
|
|
29
30
|
"tar": "^7.4.3"
|
|
30
31
|
},
|
|
31
32
|
"archives": {
|
|
32
33
|
"darwin-arm64": {
|
|
33
34
|
"name": "shopware-cli_Darwin_arm64.tar.gz",
|
|
34
|
-
"url": "https://github.com/shopware/shopware-cli/releases/download/0.6.
|
|
35
|
+
"url": "https://github.com/shopware/shopware-cli/releases/download/0.6.33/shopware-cli_Darwin_arm64.tar.gz",
|
|
35
36
|
"bins": [
|
|
36
37
|
"shopware-cli"
|
|
37
38
|
],
|
|
38
39
|
"format": "tar.gz",
|
|
39
40
|
"checksum": {
|
|
40
41
|
"algorithm": "sha256",
|
|
41
|
-
"digest": "
|
|
42
|
+
"digest": "a1f846422c349aad2c4251c9fc5d1276fd7a46098a12eec9eb95d818e6644d3f"
|
|
42
43
|
}
|
|
43
44
|
},
|
|
44
45
|
"darwin-x64": {
|
|
45
46
|
"name": "shopware-cli_Darwin_x86_64.tar.gz",
|
|
46
|
-
"url": "https://github.com/shopware/shopware-cli/releases/download/0.6.
|
|
47
|
+
"url": "https://github.com/shopware/shopware-cli/releases/download/0.6.33/shopware-cli_Darwin_x86_64.tar.gz",
|
|
47
48
|
"bins": [
|
|
48
49
|
"shopware-cli"
|
|
49
50
|
],
|
|
50
51
|
"format": "tar.gz",
|
|
51
52
|
"checksum": {
|
|
52
53
|
"algorithm": "sha256",
|
|
53
|
-
"digest": "
|
|
54
|
+
"digest": "b382825a8dbe0b9093b5e50243c7c8979abb4b97e8d4abf061ed9039d6480628"
|
|
54
55
|
}
|
|
55
56
|
},
|
|
56
57
|
"linux-arm64": {
|
|
57
58
|
"name": "shopware-cli_Linux_arm64.tar.gz",
|
|
58
|
-
"url": "https://github.com/shopware/shopware-cli/releases/download/0.6.
|
|
59
|
+
"url": "https://github.com/shopware/shopware-cli/releases/download/0.6.33/shopware-cli_Linux_arm64.tar.gz",
|
|
59
60
|
"bins": [
|
|
60
61
|
"shopware-cli"
|
|
61
62
|
],
|
|
62
63
|
"format": "tar.gz",
|
|
63
64
|
"checksum": {
|
|
64
65
|
"algorithm": "sha256",
|
|
65
|
-
"digest": "
|
|
66
|
+
"digest": "bf7d700acb83f5a5ef2f63b73fc7f2e033d384602a241797707144b6ed722c82"
|
|
66
67
|
}
|
|
67
68
|
},
|
|
68
69
|
"linux-x64": {
|
|
69
70
|
"name": "shopware-cli_Linux_x86_64.tar.gz",
|
|
70
|
-
"url": "https://github.com/shopware/shopware-cli/releases/download/0.6.
|
|
71
|
+
"url": "https://github.com/shopware/shopware-cli/releases/download/0.6.33/shopware-cli_Linux_x86_64.tar.gz",
|
|
71
72
|
"bins": [
|
|
72
73
|
"shopware-cli"
|
|
73
74
|
],
|
|
74
75
|
"format": "tar.gz",
|
|
75
76
|
"checksum": {
|
|
76
77
|
"algorithm": "sha256",
|
|
77
|
-
"digest": "
|
|
78
|
+
"digest": "c68aee7722b8aa83c91843635b512cdfec9c94d536ecbc69a66345a34be4a0eb"
|
|
78
79
|
}
|
|
79
80
|
}
|
|
80
81
|
}
|