@tokenade/cli 0.7.4 → 0.7.5
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/install.js +18 -13
- package/package.json +1 -1
package/install.js
CHANGED
|
@@ -171,19 +171,24 @@ function get(targetUrl, redirects = 0) {
|
|
|
171
171
|
err.httpStatus = res.statusCode;
|
|
172
172
|
return reject(err);
|
|
173
173
|
}
|
|
174
|
-
https
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
174
|
+
const tunneled = https.get(
|
|
175
|
+
{
|
|
176
|
+
host: t.hostname,
|
|
177
|
+
port,
|
|
178
|
+
path: `${t.pathname}${t.search}`,
|
|
179
|
+
socket,
|
|
180
|
+
agent: false,
|
|
181
|
+
servername: t.hostname,
|
|
182
|
+
},
|
|
183
|
+
onResponse,
|
|
184
|
+
);
|
|
185
|
+
tunneled.on("error", reject);
|
|
186
|
+
// The outer setTimeout only guards the CONNECT request — a
|
|
187
|
+
// stall AFTER the tunnel is established used to hang the
|
|
188
|
+
// attempt until the OS TCP timeout.
|
|
189
|
+
tunneled.setTimeout(REQUEST_TIMEOUT_MS, () => {
|
|
190
|
+
tunneled.destroy(new Error(`timeout after ${REQUEST_TIMEOUT_MS}ms (tunneled)`));
|
|
191
|
+
});
|
|
187
192
|
});
|
|
188
193
|
req = connectReq;
|
|
189
194
|
} else {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tokenade/cli",
|
|
3
|
-
"version": "0.7.
|
|
3
|
+
"version": "0.7.5",
|
|
4
4
|
"description": "Tokenade — cut your AI coding agent's token bill. Installs the Tokenade CLI (a local, paid token-reduction tool; activate via your browser).",
|
|
5
5
|
"homepage": "https://tokenade.net",
|
|
6
6
|
"license": "UNLICENSED",
|