claudish 7.12.1 → 7.12.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/dist/index.js +23 -34
- package/package.json +5 -5
package/dist/index.js
CHANGED
|
@@ -581,7 +581,7 @@ var init_onepassword_config = __esm(() => {
|
|
|
581
581
|
});
|
|
582
582
|
|
|
583
583
|
// src/version.ts
|
|
584
|
-
var VERSION = "7.12.
|
|
584
|
+
var VERSION = "7.12.2";
|
|
585
585
|
|
|
586
586
|
// src/logger.ts
|
|
587
587
|
var exports_logger = {};
|
|
@@ -3716,7 +3716,8 @@ async function discoverItemFields(vault, item, opts = {}) {
|
|
|
3716
3716
|
reference,
|
|
3717
3717
|
type: typeof field.fieldType === "string" ? field.fieldType : String(field.fieldType ?? ""),
|
|
3718
3718
|
hasValue: !!field.value,
|
|
3719
|
-
valueTail: valueTail(field.value)
|
|
3719
|
+
valueTail: valueTail(field.value),
|
|
3720
|
+
value: opts.captureValues && typeof field.value === "string" ? field.value : undefined
|
|
3720
3721
|
});
|
|
3721
3722
|
}
|
|
3722
3723
|
return out;
|
|
@@ -3786,26 +3787,26 @@ async function resolveGlobImport(opPath, opts = {}) {
|
|
|
3786
3787
|
sdkFactory: opts.sdkFactory,
|
|
3787
3788
|
auth: opts.auth,
|
|
3788
3789
|
env: opts.env,
|
|
3789
|
-
warn
|
|
3790
|
+
warn,
|
|
3791
|
+
captureValues: true
|
|
3790
3792
|
});
|
|
3791
3793
|
const matches = filterGlobFields(fields, glob);
|
|
3792
|
-
const
|
|
3794
|
+
const resolved = {};
|
|
3795
|
+
let importable = 0;
|
|
3793
3796
|
for (const m of matches) {
|
|
3794
3797
|
if (!m.valid) {
|
|
3795
3798
|
warn(`[claudish] skipped 1Password field '${m.field.label}' (not a valid env var name)`);
|
|
3796
3799
|
continue;
|
|
3797
3800
|
}
|
|
3798
|
-
|
|
3801
|
+
importable++;
|
|
3802
|
+
if (typeof m.field.value === "string")
|
|
3803
|
+
resolved[m.envName] = m.field.value;
|
|
3799
3804
|
}
|
|
3800
|
-
if (
|
|
3805
|
+
if (importable === 0) {
|
|
3801
3806
|
const available = fields.map((f) => f.label.trim()).filter((l) => l !== "").slice(0, 8);
|
|
3802
3807
|
throw new Error(`1Password glob '${opPath}' matched no importable fields in '${glob.item}'. ` + `Available field labels include: ${available.join(", ") || "(none)"}.`);
|
|
3803
3808
|
}
|
|
3804
|
-
return
|
|
3805
|
-
sdkFactory: opts.sdkFactory,
|
|
3806
|
-
auth: opts.auth,
|
|
3807
|
-
env: opts.env
|
|
3808
|
-
});
|
|
3809
|
+
return resolved;
|
|
3809
3810
|
}
|
|
3810
3811
|
async function resolveGlobImportAll(opPath, opts = {}) {
|
|
3811
3812
|
const warn = opts.warn ?? ((m) => console.error(m));
|
|
@@ -3814,24 +3815,16 @@ async function resolveGlobImportAll(opPath, opts = {}) {
|
|
|
3814
3815
|
sdkFactory: opts.sdkFactory,
|
|
3815
3816
|
auth: opts.auth,
|
|
3816
3817
|
env: opts.env,
|
|
3817
|
-
warn
|
|
3818
|
+
warn,
|
|
3819
|
+
captureValues: true
|
|
3818
3820
|
});
|
|
3819
3821
|
const matches = filterGlobFields(fields, glob);
|
|
3820
|
-
const
|
|
3822
|
+
const resolved = {};
|
|
3821
3823
|
for (const m of matches) {
|
|
3822
3824
|
if (!m.valid)
|
|
3823
3825
|
continue;
|
|
3824
|
-
|
|
3825
|
-
|
|
3826
|
-
if (Object.keys(refMap).length === 0)
|
|
3827
|
-
return {};
|
|
3828
|
-
const { resolved, failures } = await resolveSecretsPartial(refMap, {
|
|
3829
|
-
sdkFactory: opts.sdkFactory,
|
|
3830
|
-
auth: opts.auth,
|
|
3831
|
-
env: opts.env
|
|
3832
|
-
});
|
|
3833
|
-
for (const f of failures) {
|
|
3834
|
-
warn(`[claudish] 1Password glob field could not be resolved (skipped): ${f}`);
|
|
3826
|
+
if (typeof m.field.value === "string")
|
|
3827
|
+
resolved[m.envName] = m.field.value;
|
|
3835
3828
|
}
|
|
3836
3829
|
return resolved;
|
|
3837
3830
|
}
|
|
@@ -3845,24 +3838,20 @@ async function resolveGlobImportForEnvVars(opPath, envNames, opts = {}) {
|
|
|
3845
3838
|
sdkFactory: opts.sdkFactory,
|
|
3846
3839
|
auth: opts.auth,
|
|
3847
3840
|
env: opts.env,
|
|
3848
|
-
warn
|
|
3841
|
+
warn,
|
|
3842
|
+
captureValues: true
|
|
3849
3843
|
});
|
|
3850
3844
|
const matches = filterGlobFields(fields, glob);
|
|
3851
|
-
const
|
|
3845
|
+
const resolved = {};
|
|
3852
3846
|
for (const m of matches) {
|
|
3853
3847
|
if (!m.valid)
|
|
3854
3848
|
continue;
|
|
3855
3849
|
if (!wanted.has(m.envName))
|
|
3856
3850
|
continue;
|
|
3857
|
-
|
|
3851
|
+
if (typeof m.field.value === "string")
|
|
3852
|
+
resolved[m.envName] = m.field.value;
|
|
3858
3853
|
}
|
|
3859
|
-
|
|
3860
|
-
return {};
|
|
3861
|
-
return resolveSecrets(refMap, {
|
|
3862
|
-
sdkFactory: opts.sdkFactory,
|
|
3863
|
-
auth: opts.auth,
|
|
3864
|
-
env: opts.env
|
|
3865
|
-
});
|
|
3854
|
+
return resolved;
|
|
3866
3855
|
}
|
|
3867
3856
|
function envNameFromOpRef(opRef) {
|
|
3868
3857
|
if (typeof opRef !== "string" || !opRef.startsWith("op://"))
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "claudish",
|
|
3
|
-
"version": "7.12.
|
|
3
|
+
"version": "7.12.2",
|
|
4
4
|
"description": "Run Claude Code with any model - OpenRouter, Ollama, LM Studio & local models",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -60,10 +60,10 @@
|
|
|
60
60
|
"ai"
|
|
61
61
|
],
|
|
62
62
|
"optionalDependencies": {
|
|
63
|
-
"@claudish/magmux-darwin-arm64": "7.12.
|
|
64
|
-
"@claudish/magmux-darwin-x64": "7.12.
|
|
65
|
-
"@claudish/magmux-linux-arm64": "7.12.
|
|
66
|
-
"@claudish/magmux-linux-x64": "7.12.
|
|
63
|
+
"@claudish/magmux-darwin-arm64": "7.12.2",
|
|
64
|
+
"@claudish/magmux-darwin-x64": "7.12.2",
|
|
65
|
+
"@claudish/magmux-linux-arm64": "7.12.2",
|
|
66
|
+
"@claudish/magmux-linux-x64": "7.12.2"
|
|
67
67
|
},
|
|
68
68
|
"author": "Jack Rudenko <i@madappgang.com>",
|
|
69
69
|
"license": "MIT",
|