@staff0rd/assist 0.453.1 → 0.454.0
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
CHANGED
|
@@ -6,7 +6,7 @@ import { Command } from "commander";
|
|
|
6
6
|
// package.json
|
|
7
7
|
var package_default = {
|
|
8
8
|
name: "@staff0rd/assist",
|
|
9
|
-
version: "0.
|
|
9
|
+
version: "0.454.0",
|
|
10
10
|
type: "module",
|
|
11
11
|
main: "dist/index.js",
|
|
12
12
|
bin: {
|
|
@@ -9145,6 +9145,12 @@ function getNestedValue(obj, path71) {
|
|
|
9145
9145
|
return current;
|
|
9146
9146
|
}
|
|
9147
9147
|
|
|
9148
|
+
// src/commands/config/isGlobalOnlyConfigKey.ts
|
|
9149
|
+
var GLOBAL_ONLY_KEYS = ["sync.autoConfirm"];
|
|
9150
|
+
function isGlobalOnlyConfigKey(key) {
|
|
9151
|
+
return GLOBAL_ONLY_KEYS.some((k) => key.startsWith(k));
|
|
9152
|
+
}
|
|
9153
|
+
|
|
9148
9154
|
// src/commands/config/readRawConfigLayers.ts
|
|
9149
9155
|
function readRawConfigLayers(cwd) {
|
|
9150
9156
|
const global = loadRawYaml(getGlobalConfigPath());
|
|
@@ -9171,7 +9177,8 @@ function readConfigEntries(cwd) {
|
|
|
9171
9177
|
return describeConfigLeaves(assistConfigSchema).filter((leaf) => !KEYS_STRIPPED_FROM_MERGED_CONFIG.has(leaf.key)).map((leaf) => ({
|
|
9172
9178
|
...leaf,
|
|
9173
9179
|
value: getNestedValue(config, leaf.key),
|
|
9174
|
-
source: resolveConfigSource(leaf.key, layers)
|
|
9180
|
+
source: resolveConfigSource(leaf.key, layers),
|
|
9181
|
+
globalOnly: isGlobalOnlyConfigKey(leaf.key)
|
|
9175
9182
|
}));
|
|
9176
9183
|
}
|
|
9177
9184
|
|
|
@@ -10024,9 +10031,8 @@ function formatIssue(issue, key) {
|
|
|
10024
10031
|
}
|
|
10025
10032
|
|
|
10026
10033
|
// src/commands/config/applyConfigSet.ts
|
|
10027
|
-
var GLOBAL_ONLY_KEYS = ["sync.autoConfirm"];
|
|
10028
10034
|
function applyConfigSet(key, coerced, global, cwd = process.cwd()) {
|
|
10029
|
-
if (!global &&
|
|
10035
|
+
if (!global && isGlobalOnlyConfigKey(key)) {
|
|
10030
10036
|
return {
|
|
10031
10037
|
ok: false,
|
|
10032
10038
|
errors: [
|
|
@@ -10045,9 +10051,6 @@ function applyConfigSet(key, coerced, global, cwd = process.cwd()) {
|
|
|
10045
10051
|
saveConfig(updated, cwd);
|
|
10046
10052
|
return { ok: true, target: "project" };
|
|
10047
10053
|
}
|
|
10048
|
-
function isGlobalOnly(key) {
|
|
10049
|
-
return GLOBAL_ONLY_KEYS.some((k) => key.startsWith(k));
|
|
10050
|
-
}
|
|
10051
10054
|
|
|
10052
10055
|
// src/commands/config/coerceConfigValue.ts
|
|
10053
10056
|
var EDITABLE_TYPES = /* @__PURE__ */ new Set(["string", "number", "boolean", "enum"]);
|