skillwiki 0.10.42 → 0.10.44
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/{chunk-VBA5TBPS.js → chunk-JHHVTW7E.js} +26 -8
- package/dist/cli.js +2 -2
- package/dist/{managed-write-preflight-DCUMILQT.js → managed-write-preflight-EDEMCLVQ.js} +1 -1
- package/package.json +1 -1
- package/skills/.claude-plugin/plugin.json +1 -1
- package/skills/.codex-plugin/plugin.json +1 -1
- package/skills/package.json +1 -1
|
@@ -434,9 +434,15 @@ var STASH_AUDIT_CLASSIFICATIONS = [
|
|
|
434
434
|
var STASH_AUDIT_FORMATS = ["wiki-sync", "vault-sync", "manual", "unknown"];
|
|
435
435
|
var STASH_RECENT_MINUTES = 120;
|
|
436
436
|
var MANAGED_WRITER_SPECS = [
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
["
|
|
437
|
+
// Real runner only: wiki-push.sh on Unix, wiki-push/wiki-push.exe as a
|
|
438
|
+
// Windows image name. Bare text mentions never match.
|
|
439
|
+
["wiki-push", /(?:^wiki-push(?:\.exe)?$)|(?:wiki-push\.sh(?:\s|$))/i],
|
|
440
|
+
// Write verbs only on Unix; Windows image name only (tasklist exposes
|
|
441
|
+
// no arguments). Read-only verbs and `rclone mount` (FUSE consumer)
|
|
442
|
+
// never match.
|
|
443
|
+
["rclone", /(?:^rclone(?:\.exe)?$)|(?:\brclone(?:\.exe)?\s+(?:copy|sync|move|delete|purge|deletefile|copyto|moveto|dedupe|mkdir|rmdir|rmdirs|touch|settier|bisync|copyurl)(?:\s|$))/i],
|
|
444
|
+
// Writing helper scripts on Unix; Windows image name only.
|
|
445
|
+
["vault-sync", /(?:^vault-sync(?:\.exe)?$)|(?:wiki-(?:snapshot|pull-with-auto-resolve|git-repair-v3)\.sh(?:\s|$))/i]
|
|
440
446
|
];
|
|
441
447
|
var MANAGED_WRITER_KINDS = MANAGED_WRITER_SPECS.map(([kind]) => kind);
|
|
442
448
|
function classifyStash(ageMinutes, sessionId, currentSession) {
|
|
@@ -671,6 +677,7 @@ function isManagedWriteLockOwnerAlive(pid) {
|
|
|
671
677
|
}
|
|
672
678
|
}
|
|
673
679
|
function hasUnsafeGitState(vault) {
|
|
680
|
+
if (!isGitBackedVault(vault)) return false;
|
|
674
681
|
const gitDirRaw = git(vault, ["rev-parse", "--git-dir"]);
|
|
675
682
|
if (!gitDirRaw) return true;
|
|
676
683
|
const gitDir = gitDirRaw.startsWith("/") ? gitDirRaw : join2(vault, gitDirRaw);
|
|
@@ -866,7 +873,7 @@ function peerCheckFailure(reason, detail = {}) {
|
|
|
866
873
|
result: err("PREFLIGHT_FAILED", { reason, ...detail })
|
|
867
874
|
};
|
|
868
875
|
}
|
|
869
|
-
function runManagedWritePeerGate(vault, deps) {
|
|
876
|
+
function runManagedWritePeerGate(vault, mode, deps) {
|
|
870
877
|
try {
|
|
871
878
|
const check = (deps.syncPeers ?? DEFAULT_DEPS.syncPeers)({ vault });
|
|
872
879
|
if (check.exitCode !== ExitCode.OK || !check.result.ok) {
|
|
@@ -877,11 +884,15 @@ function runManagedWritePeerGate(vault, deps) {
|
|
|
877
884
|
return peerCheckFailure("peer-check-failed");
|
|
878
885
|
}
|
|
879
886
|
const { output: peerOutput, foreignLockCount, recentPeerStashCount } = validated;
|
|
880
|
-
const
|
|
887
|
+
const nonWriterBlockingSignal = foreignLockCount > 0 || recentPeerStashCount > 0;
|
|
888
|
+
const writerOnly = peerOutput.managed_writers.blocking && !nonWriterBlockingSignal;
|
|
889
|
+
if (mode !== "git-writer" && writerOnly) return null;
|
|
890
|
+
const managedWriterBlocking = mode === "git-writer" && peerOutput.managed_writers.blocking;
|
|
891
|
+
const hasKnownBlockingSignal = foreignLockCount > 0 || managedWriterBlocking || recentPeerStashCount > 0;
|
|
881
892
|
if (!peerOutput.blocking) {
|
|
882
893
|
return hasKnownBlockingSignal ? peerCheckFailure("peer-check-failed") : null;
|
|
883
894
|
}
|
|
884
|
-
if (
|
|
895
|
+
if (managedWriterBlocking) {
|
|
885
896
|
return peerCheckFailure("live-writer-overlap", {
|
|
886
897
|
managed_writer_count: peerOutput.managed_writers.count,
|
|
887
898
|
managed_writer_kinds: peerOutput.managed_writers.kinds.slice(0, 8),
|
|
@@ -957,6 +968,12 @@ async function runManagedWritePreflight(input, deps = DEFAULT_DEPS) {
|
|
|
957
968
|
user: input.user
|
|
958
969
|
});
|
|
959
970
|
if (!fleet) {
|
|
971
|
+
if (hasFleetManifest(mutationVault)) {
|
|
972
|
+
return {
|
|
973
|
+
exitCode: ExitCode.PREFLIGHT_FAILED,
|
|
974
|
+
result: err("PREFLIGHT_FAILED", { reason: "fleet-unreadable" })
|
|
975
|
+
};
|
|
976
|
+
}
|
|
960
977
|
const gitVault2 = isGitVault(mutationVault) ? mutationVault : null;
|
|
961
978
|
const head = gitVault2 ? git(gitVault2, ["rev-parse", "HEAD"]) || null : null;
|
|
962
979
|
return {
|
|
@@ -967,7 +984,8 @@ async function runManagedWritePreflight(input, deps = DEFAULT_DEPS) {
|
|
|
967
984
|
git_vault: gitVault2,
|
|
968
985
|
base_oid: head,
|
|
969
986
|
converged: false,
|
|
970
|
-
|
|
987
|
+
...convergenceVault ? { convergence_vault: convergenceVault } : {},
|
|
988
|
+
convergence_source: convergenceSource
|
|
971
989
|
})
|
|
972
990
|
};
|
|
973
991
|
}
|
|
@@ -1172,7 +1190,7 @@ async function runManagedWriteTransaction(input, deps = DEFAULT_DEPS) {
|
|
|
1172
1190
|
})
|
|
1173
1191
|
};
|
|
1174
1192
|
}
|
|
1175
|
-
const peerGate = runManagedWritePeerGate(mutationVault, deps);
|
|
1193
|
+
const peerGate = runManagedWritePeerGate(mutationVault, receipt.mode, deps);
|
|
1176
1194
|
if (peerGate) return peerGate;
|
|
1177
1195
|
return await input.mutate(receipt);
|
|
1178
1196
|
} finally {
|
package/dist/cli.js
CHANGED
|
@@ -64,7 +64,7 @@ import {
|
|
|
64
64
|
runSyncStatus,
|
|
65
65
|
runSyncUnlock,
|
|
66
66
|
stageVaultContentChanges
|
|
67
|
-
} from "./chunk-
|
|
67
|
+
} from "./chunk-JHHVTW7E.js";
|
|
68
68
|
import {
|
|
69
69
|
FLEET_REL_PATH,
|
|
70
70
|
acquireOwnedSyncLock,
|
|
@@ -9542,7 +9542,7 @@ async function emitManagedVaultWrite(vault, command, mutate, opts) {
|
|
|
9542
9542
|
if (dirty) {
|
|
9543
9543
|
return emit(dirty, void 0, { postCommit: false });
|
|
9544
9544
|
}
|
|
9545
|
-
const { runManagedWriteTransaction: runManagedWriteTransaction2 } = await import("./managed-write-preflight-
|
|
9545
|
+
const { runManagedWriteTransaction: runManagedWriteTransaction2 } = await import("./managed-write-preflight-EDEMCLVQ.js");
|
|
9546
9546
|
const run = await runManagedWriteTransaction2({
|
|
9547
9547
|
vault,
|
|
9548
9548
|
command,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "skillwiki",
|
|
3
|
-
"version": "0.10.
|
|
3
|
+
"version": "0.10.44",
|
|
4
4
|
"skills": "./",
|
|
5
5
|
"description": "Project-aware Karpathy-style knowledge base for Claude Code: 19 prompt-only skills (wiki-*, proj-*, using-skillwiki) backed by the deterministic `skillwiki` CLI.",
|
|
6
6
|
"author": {
|