@feigi/fleet-ctl 3.127.8 → 3.127.9
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/package.json +1 -1
- package/scripts/label-map.mjs +12 -6
package/package.json
CHANGED
package/scripts/label-map.mjs
CHANGED
|
@@ -45,9 +45,12 @@
|
|
|
45
45
|
// the string rules, the message naming each
|
|
46
46
|
// role, the rule and the fix. Exit 2: no
|
|
47
47
|
// repository, the table not readable, the
|
|
48
|
-
// cache present but not readable
|
|
49
|
-
//
|
|
50
|
-
//
|
|
48
|
+
// cache present but not readable (the
|
|
49
|
+
// message naming the errno as a filesystem
|
|
50
|
+
// fault and its repair, nothing written) or
|
|
51
|
+
// not writable, `gh` could not answer, the
|
|
52
|
+
// label list filled its limit, or a usage
|
|
53
|
+
// refusal.
|
|
51
54
|
// label-map.mjs set [--accept-suggestions] [--create] [<role>=<label> …]
|
|
52
55
|
// writes the map from a fresh derivation (as
|
|
53
56
|
// `ensure` runs it) plus the answer: each
|
|
@@ -73,7 +76,9 @@
|
|
|
73
76
|
// unknown role, a malformed pair, a role
|
|
74
77
|
// answered twice or an unknown flag; no
|
|
75
78
|
// repository, `gh` could not answer, or the
|
|
76
|
-
// cache not readable
|
|
79
|
+
// cache not readable (the message naming the
|
|
80
|
+
// errno as a filesystem fault and its
|
|
81
|
+
// repair, nothing written) or not writable.
|
|
77
82
|
// label-map.mjs show [<role>] the mapped string for <role>, or the whole
|
|
78
83
|
// `roles` object as JSON with no role.
|
|
79
84
|
// `show` exits 0 printed; 1 no cache or an
|
|
@@ -587,8 +592,9 @@ function readDerivationInputs(cwd) {
|
|
|
587
592
|
} catch (e) {
|
|
588
593
|
if (!(e instanceof LabelMapUnreadable)) throw e;
|
|
589
594
|
// Absent or not parsing is derived again; a cache that exists and cannot
|
|
590
|
-
// be read may hold maintainer answers, so it is never written over
|
|
591
|
-
|
|
595
|
+
// be read may hold maintainer answers, so it is never written over: the
|
|
596
|
+
// refusal is the reader's own, naming the errno and the repair.
|
|
597
|
+
if (e.cause) throw new LabelMapUnavailable(`${e.message}; nothing written`);
|
|
592
598
|
}
|
|
593
599
|
return { top, table, live, cache };
|
|
594
600
|
}
|