@lobehub/cli 0.0.214 → 0.0.216
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/dist/acceptance-report.html +2 -2
- package/dist/index.js +11 -1
- package/man/man1/lh.1 +1 -1
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -56710,7 +56710,7 @@ const createAdapter = (agentType) => {
|
|
|
56710
56710
|
};
|
|
56711
56711
|
|
|
56712
56712
|
//#endregion
|
|
56713
|
-
//#region node_modules/.pnpm/@lobehub+icons@6.
|
|
56713
|
+
//#region node_modules/.pnpm/@lobehub+icons@6.20.0_@lobehub+ui@6.19.1_lucide-react@1.77.0_@types+react@19.2.13_react_712a9c1aa2e96b0b3f2c3e4bcad70c75/node_modules/@lobehub/icons/es/features/getLobeIconCDN/index.mjs
|
|
56714
56714
|
const GITHUB_ICON_CDN = (type) => `https://raw.githubusercontent.com/lobehub/lobe-icons/refs/heads/master/packages/static-${type}`;
|
|
56715
56715
|
const ALIYUN_ICON_CDN = (type) => `https://registry.npmmirror.com/@lobehub/icons-static-${type}/latest/files`;
|
|
56716
56716
|
const UNPKG_ICON_CDN = (type) => `https://unpkg.com/@lobehub/icons-static-${type}@latest`;
|
|
@@ -80854,6 +80854,14 @@ const normalizeCreditText = (value) => {
|
|
|
80854
80854
|
if (typeof value !== "string") return null;
|
|
80855
80855
|
return value.trim() || null;
|
|
80856
80856
|
};
|
|
80857
|
+
const mapRpcCredits = (raw) => {
|
|
80858
|
+
const balance = normalizeCreditText(raw?.balance);
|
|
80859
|
+
const unlimited = raw?.unlimited === true;
|
|
80860
|
+
return balance === null && !unlimited ? void 0 : {
|
|
80861
|
+
balance,
|
|
80862
|
+
unlimited
|
|
80863
|
+
};
|
|
80864
|
+
};
|
|
80857
80865
|
const mapRpcResetCredit = (credit) => ({
|
|
80858
80866
|
expiresAt: parseCreditTimestamp(credit.expiresAt),
|
|
80859
80867
|
grantedAt: parseCreditTimestamp(credit.grantedAt),
|
|
@@ -81102,6 +81110,7 @@ const fetchViaRpc = async (options, auth) => {
|
|
|
81102
81110
|
});
|
|
81103
81111
|
const rateLimits = mapRpcRateLimits(wrapper);
|
|
81104
81112
|
const defaultRateLimit = rateLimits.find(({ limitId }) => limitId.toLowerCase() === "codex") ?? rateLimits[0];
|
|
81113
|
+
const credits = mapRpcCredits(wrapper.rateLimitsByLimitId?.codex?.credits) ?? mapRpcCredits(wrapper.rateLimits?.credits);
|
|
81105
81114
|
const rateLimitResetCredits = mapRpcResetCredits(wrapper?.rateLimitResetCredits);
|
|
81106
81115
|
let backendCredits = null;
|
|
81107
81116
|
if (options.includeResetCredits !== false && auth && rateLimitResetCredits?.credits === void 0) try {
|
|
@@ -81111,6 +81120,7 @@ const fetchViaRpc = async (options, auth) => {
|
|
|
81111
81120
|
}
|
|
81112
81121
|
const updatedAt = Date.now();
|
|
81113
81122
|
return {
|
|
81123
|
+
credits,
|
|
81114
81124
|
error: null,
|
|
81115
81125
|
readings: codexQuotaReadings(rateLimits, updatedAt),
|
|
81116
81126
|
provider: "codex",
|
package/man/man1/lh.1
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
.\" Code generated by `npm run man:generate`; DO NOT EDIT.
|
|
2
2
|
.\" Manual command details come from the Commander command tree.
|
|
3
|
-
.TH LH 1 "" "@lobehub/cli 0.0.
|
|
3
|
+
.TH LH 1 "" "@lobehub/cli 0.0.216" "User Commands"
|
|
4
4
|
.SH NAME
|
|
5
5
|
lh \- LobeHub CLI \- manage and connect to LobeHub services
|
|
6
6
|
.SH SYNOPSIS
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lobehub/cli",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.216",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
6
6
|
"url": "https://github.com/lobehub/lobehub",
|
|
@@ -83,5 +83,5 @@
|
|
|
83
83
|
"access": "public",
|
|
84
84
|
"registry": "https://registry.npmjs.org"
|
|
85
85
|
},
|
|
86
|
-
"gitHead": "
|
|
86
|
+
"gitHead": "a52ae3ab50eb723da2eabdb2ae25fce4a382f870"
|
|
87
87
|
}
|