@bitcobblers/wod-wiki-engine 0.35.2117 → 0.35.2120

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/bin/wod.mjs CHANGED
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'module';
3
- import { cliMain } from '../chunk-AKNXDA75.mjs';
3
+ import { cliMain } from '../chunk-4HQWTNS5.mjs';
4
4
  import '../chunk-Y6WO6MXS.mjs';
5
5
 
6
6
  if (typeof globalThis.require === 'undefined') {
@@ -1128,7 +1128,7 @@ async function putChanged(store, values, keys) {
1128
1128
  async function applySeedChunk(storage, write) {
1129
1129
  assertSeedManifest(write.manifest);
1130
1130
  assertSeedRows(write.rows);
1131
- const result = { totalNotes: 0, totalEfforts: 0, totalBlocks: 0, skippedUserOwned: 0, deleted: 0 };
1131
+ const result = { totalNotes: 0, totalEfforts: 0, totalBlocks: 0, skippedUserOwned: 0, deleted: 0, addedNotes: 0, updatedNotes: 0 };
1132
1132
  const ids = await Promise.all(write.rows.map((row) => seedNoteId(row.path)));
1133
1133
  const pagesBySlug = /* @__PURE__ */ new Map();
1134
1134
  const linkIds = /* @__PURE__ */ new Map();
@@ -1183,6 +1183,8 @@ async function applySeedChunk(storage, write) {
1183
1183
  result.skippedUserOwned++;
1184
1184
  continue;
1185
1185
  }
1186
+ if (!existing) result.addedNotes++;
1187
+ else if (existing.rawContent !== row.content) result.updatedNotes++;
1186
1188
  validateNoteBlocks(row.content, row.blocks, 1, { registeredWidgets: SEED_REGISTERED_WIDGETS });
1187
1189
  const sourceRevision = existing ? existing.sourceRevision + (existing.rawContent === row.content ? 0 : 1) : 1;
1188
1190
  let ordinal = 0;
@@ -2705,7 +2707,7 @@ async function cliMain(argv = process.argv.slice(2), io = {}) {
2705
2707
  writeErr(`[wod build] No markdown/ corpus under ${root} \u2014 run from the content repo root (or pass its directory).`);
2706
2708
  return 1;
2707
2709
  }
2708
- const { generateSeed } = await import('./compiler-MQRZVZQW.mjs');
2710
+ const { generateSeed } = await import('./compiler-CAOKDLIY.mjs');
2709
2711
  try {
2710
2712
  const result = generateSeed({
2711
2713
  corpusRoot: root,
@@ -2774,5 +2776,5 @@ async function cliMain(argv = process.argv.slice(2), io = {}) {
2774
2776
  }
2775
2777
 
2776
2778
  export { NOTE_ID_FRONTMATTER_KEY, PackLoadError, ParseSyntaxError, SESSION_CSV_HEADER, WqlSyntaxError, applySeedChunk, assertSeedManifest, assertSeedRows, buildStatementTree, buildWorkoutResults, cliMain, composeNoteMarkdown, createIRFile, csvToEquipmentLabels, csvToSessionRows, defineLanguagePack, effortToMarkdown, equipmentToCsv, extractNoteIdentity, extractTypedTags, formatExecutionOutput, formatParseOutput, formatQueryOutput, getRegisteredLanguagePacks, inMemoryEventStore, injectIdentityFrontmatter, isIRFile, listLanguagePacks, loadLanguagePack, loadQueryData, markdownToEffort, parseCliArgs, parseCsvLine, readFrontmatterMeta, readStdin, registerLanguagePack, runExecution, runParse, runQueryCli, seedNoteId, sessionToCsv, splitCsvRecords, statementToNode, unregisterLanguagePack };
2777
- //# sourceMappingURL=chunk-AKNXDA75.mjs.map
2778
- //# sourceMappingURL=chunk-AKNXDA75.mjs.map
2779
+ //# sourceMappingURL=chunk-4HQWTNS5.mjs.map
2780
+ //# sourceMappingURL=chunk-4HQWTNS5.mjs.map