Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -118,3 +118,7 @@ Linux CI installs only the required Xvfb/Openbox dependencies, with bounded netw
Editor archive actions share one pending promise through final modal cleanup. Other modal transitions wait for it; archive cleanup bypasses its own wait. Preserve failure cleanup, duplicate-request handling, and the delayed-archive Electron regression.

App settings save responses reconcile against the submitted snapshot: preserve newer renderer edits while accepting server-generated values for unchanged fields. Keep the deferred-save regression in `test:app-settings` and Smart Actions Electron coverage aligned.

## Card move metadata — 1.7.8

`lib/archive.js` records cross-list move activity and normalizes destination Signboard properties in one atomic card write. Desktop drag/drop and move-to-top must not follow it with a second metadata write. Same-list drag reorders leave card contents unchanged. Preserve body/custom fields and the atomic-failure regression in `test:archive`; filtered-drag Electron tests assert both `status` and `signboard_list` before opening the editor.
4 changes: 4 additions & 0 deletions CODEX.md
Original file line number Diff line number Diff line change
Expand Up @@ -157,3 +157,7 @@ Linux CI installs only the required Xvfb/Openbox dependencies, with bounded netw
Editor archive actions share one pending promise through final modal cleanup. Other modal transitions wait for it; archive cleanup bypasses its own wait. Preserve failure cleanup, duplicate-request handling, and the delayed-archive Electron regression.

App settings save responses reconcile against the submitted snapshot: preserve newer renderer edits while accepting server-generated values for unchanged fields. Keep the deferred-save regression in `test:app-settings` and Smart Actions Electron coverage aligned.

## Card move metadata — 1.7.8

`lib/archive.js` records cross-list move activity and normalizes destination Signboard properties in one atomic card write. Desktop drag/drop and move-to-top must not follow it with a second metadata write. Same-list drag reorders leave card contents unchanged. Preserve body/custom fields and the atomic-failure regression in `test:archive`; filtered-drag Electron tests assert both `status` and `signboard_list` before opening the editor.
10 changes: 5 additions & 5 deletions config/build-info.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
{
"schemaVersion": 1,
"version": "1.7.7",
"buildId": "20261111.4",
"version": "1.7.8",
"buildId": "20261120.1",
"channel": "release",
"builtAt": "2026-11-11T15:09:58.648Z",
"sourceFingerprint": "b36621c24a6fb0f9bc164088203fd26e85788b45b56635f99c8d75588cf6f5b9",
"builtAt": "2026-11-20T09:20:39.136Z",
"sourceFingerprint": "3de83b023a4a0a600a5fb60bac620a8c6461c49006225ddcfc47ba8cf5dac30b",
"sourceFileCount": 177,
"commit": "b971c0a6c2d2876e739d1438815cea929bb8dc8d",
"commit": "b70b112c850688ebef15a9e2865032818b324cf6",
"dirty": true
}
2 changes: 2 additions & 0 deletions docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,3 +32,5 @@ Public contributor docs describe reusable development practices. Machine access
The CLI and MCP support archiving/restoration, filtered card queries, list renaming, board settings updates, board rename/move/duplication, and persisted card/list ordering. See the [operation matrix and examples](./automation.md).

List insertion and left/right moves preserve existing names when a rename fails, with bounded retries and rollback. See [list recovery](./using-signboard.md#move-lists) for recovery messages and retained new lists.

Card moves between lists save the move activity and destination `status` / `signboard_list` properties together, including drag-and-drop. Notes, labels, dates, and custom properties are preserved.
4 changes: 2 additions & 2 deletions docs/codex/FILE_STRUCTURE.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ This map focuses on source and operational files. Large generated/vendor folders
- `lib/omarchyTheme.js` - Canonical Omarchy active-theme path resolution, restricted TOML palette parsing, contrast-safe token derivation, and read status.
- `lib/releaseArtifactValidation.js` - Debian/ar and Pacman archive recognition, minimum release-artifact sizing, and SHA-512 helpers shared by runtime download checks and release validation.
- `lib/cardOrdering.js` - Shared transactional ordering helpers used by main-process/MCP restore and move flows to insert a card at the top, reorder cards in a list, perform stable due-date ordering, and reorder list directories while staging only changed entries and rolling back on failures.
- `lib/archive.js` - Archive/archive-list filesystem operations plus archive listing/detail/restore helpers and legacy archive fallback handling.
- `lib/archive.js` - Atomic cross-list move activity plus destination metadata, archive/archive-list filesystem operations plus archive listing/detail/restore helpers and legacy archive fallback handling.
- `lib/boardLabels.js` - Board-level label/theme/workflow/External Published Calendar inclusion settings read/write/defaults/filter helpers (`board-settings.md`) plus legacy app-setting extraction for migration.
- `lib/boardDuplication.js` - Board folder duplication helper used by desktop Settings; copies board contents, assigns fresh copied-card IDs, refreshes copied Signboard metadata, rewrites internal `signboard://open-card` references, rewrites copied local linked-object paths, and resets copied managed Base state.
- `lib/appSettings.js` - App-wide tooltip/notification/appearance-source/Quick Add global shortcut/AI assistance and External Published Calendar JSON persistence under Electron `userData`, delegating defaults and normalization to `shared/appSettingsSchema.js`.
Expand Down Expand Up @@ -120,7 +120,7 @@ This map focuses on source and operational files. Large generated/vendor folders
- `scripts/test-release-artifact-validation.js` - Valid, malformed, incomplete, and file-backed Debian/Pacman archive inspection assertions.
- `scripts/test-packaging-config.js` - Required electron-builder runtime-source glob validation, including `bin/**` and `shared/**`.
- `scripts/test-packaged-app-launch.js` - Isolated packaged-app smoke test that requires the packaged main process and renderer bridge to load before macOS distribution builds succeed.
- `scripts/test-archive.js` - Archive metadata, archive-browser data, restore flow, empty archived-list cleanup, and legacy archive fallback assertions.
- `scripts/test-archive.js` - Single-write move metadata, failed-write preservation, archive metadata, archive-browser data, restore flow, empty archived-list cleanup, and legacy archive fallback assertions.
- `scripts/test-due-notifications.js` - Due-notification assertions for task due item collection and notification body formatting.
- `scripts/test-external-published-calendar.js` - External Published Calendar assertions for ICS generation, completed-list skipping, checked-task skipping, and board opt-out.
- `scripts/test-import-trello.js` - Trello importer assertions for order, label reuse, archive routing, and metadata preservation.
Expand Down
4 changes: 4 additions & 0 deletions docs/codex/PROJECT_CONTEXT.md
Original file line number Diff line number Diff line change
Expand Up @@ -666,3 +666,7 @@ Linux CI installs only the required Xvfb/Openbox dependencies, with bounded netw
Editor archive actions share one pending promise through final modal cleanup. Other modal transitions wait for it; archive cleanup bypasses its own wait. Preserve failure cleanup, duplicate-request handling, and the delayed-archive Electron regression.

App settings save responses reconcile against the submitted snapshot: preserve newer renderer edits while accepting server-generated values for unchanged fields. Keep the deferred-save regression in `test:app-settings` and Smart Actions Electron coverage aligned.

## Card move metadata — 1.7.8

`lib/archive.js` records cross-list move activity and normalizes destination Signboard properties in one atomic card write. Desktop drag/drop and move-to-top must not follow it with a second metadata write. Same-list drag reorders leave card contents unchanged. Preserve body/custom fields and the atomic-failure regression in `test:archive`; filtered-drag Electron tests assert both `status` and `signboard_list` before opening the editor.
2 changes: 2 additions & 0 deletions docs/using-signboard.md
Original file line number Diff line number Diff line change
Expand Up @@ -534,3 +534,5 @@ The CLI and MCP support archiving/restoration, filtered card queries, list renam
List folder names remove Windows-invalid punctuation throughout the name, including after periods; for example, `Release 1.7: QA` becomes `Release 1.7 QA`.

Board and list names can be renamed by changing only their capitalization. Planner filter menus scroll when needed so every label and Clear filters remain reachable in smaller windows.

Card moves between lists save the move activity and destination `status` / `signboard_list` properties together, including drag-and-drop. Notes, labels, dates, and custom properties are preserved.
20 changes: 14 additions & 6 deletions lib/archive.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ const boardLabels = require('./boardLabels');
const cardFrontmatter = require('./cardFrontmatter');
const { insertCardFileAtTop } = require('./cardOrdering');
const { atomicWriteFile } = require('./atomicFile');
const { normalizeSignboardCardFrontmatter } = require('./obsidianIntegration');
const {
clearCardArchiveState,
formatActivityTimestamp,
Expand Down Expand Up @@ -955,12 +956,19 @@ async function recordCardListMove(boardRoot, cardPath, fromListPath, toListPath)
const toList = getListContextFromPath(normalizedToListPath);
const movedAt = formatActivityTimestamp();

await mutateCard(normalizedCardPath, (frontmatter) => applyCardListMove(frontmatter, {
movedAt,
fromListDirectoryName: fromList.directoryName,
fromListDisplayName: fromList.displayName,
toListDirectoryName: toList.directoryName,
toListDisplayName: toList.displayName,
// Commit the destination properties with the move event. A separate metadata
// write leaves a stale intermediate version visible to sync clients and can
// fail after the move event has already been persisted.
await mutateCard(normalizedCardPath, (frontmatter) => normalizeSignboardCardFrontmatter({
boardRoot: normalizedBoardRoot,
cardPath: normalizedCardPath,
frontmatter: applyCardListMove(frontmatter, {
movedAt,
fromListDirectoryName: fromList.directoryName,
fromListDisplayName: fromList.displayName,
toListDirectoryName: toList.directoryName,
toListDisplayName: toList.displayName,
}),
}));

return {
Expand Down
4 changes: 2 additions & 2 deletions main.js
Original file line number Diff line number Diff line change
Expand Up @@ -4601,7 +4601,6 @@ ipcMain.handle('board-call', async (event, payload = {}) => {
if (sourceListPath !== targetListPath) {
movedAcrossLists = true;
await recordCardListMove(boardRoot, cardEntry.cardPath, sourceListPath, targetListPath);
await refreshCardSignboardMetadata(boardRoot, cardEntry.cardPath);
}
}

Expand Down Expand Up @@ -4688,9 +4687,10 @@ ipcMain.handle('board-call', async (event, payload = {}) => {

if (sourceListPath !== targetListPath) {
await recordCardListMove(boardRoot, movedCardPath, sourceListPath, targetListPath);
} else {
await refreshCardSignboardMetadata(boardRoot, movedCardPath);
}

await refreshCardSignboardMetadata(boardRoot, movedCardPath);
await autoSyncManagedObsidianBaseForBoard(boardRoot);

return {
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "signboard",
"productName": "Signboard",
"version": "1.7.7",
"version": "1.7.8",
"description": "A fast, local-first Kanban board for Markdown files.",
"homepage": "https://github.com/cdevroe/signboard",
"repository": {
Expand Down
2 changes: 2 additions & 0 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -412,3 +412,5 @@ Signboard includes the following open source libraries:
The CLI and MCP support archiving/restoration, filtered card queries, list renaming, board settings updates, board rename/move/duplication, and persisted card/list ordering. See the [operation matrix and examples](./docs/automation.md).

List insertion and left/right moves preserve existing names when a rename fails, with bounded retries and rollback. See [list recovery](docs/using-signboard.md#move-lists) for recovery messages and retained new lists.

Card moves between lists save the move activity and destination `status` / `signboard_list` properties together, including drag-and-drop. Notes, labels, dates, and custom properties are preserved.
51 changes: 48 additions & 3 deletions scripts/test-archive.js
Original file line number Diff line number Diff line change
Expand Up @@ -219,15 +219,60 @@ async function testRecordCardListMoveAppendsLifecycleEvent(root) {
await fs.mkdir(doingList, { recursive: true });

const cardPath = path.join(doingList, '000-track-progress-stock.md');
await writeCard(cardPath, { title: 'Track progress' }, 'Update the thread');

const moved = await recordCardListMove(boardRoot, cardPath, todoList, doingList);
await writeCard(cardPath, {
title: 'Track progress', status: 'To-do', signboard_list: 'To-do',
due: '2026-12-01', labels: ['work'], custom: 'Keep me',
}, 'Update the thread');

// A sync client can observe every atomic replacement. No committed move
// event may still describe the source list, even before a later refresh.
const originalWrite = cardFrontmatter.writeCard;
let writes = 0;
let moved;
cardFrontmatter.writeCard = async (file, card) => {
await originalWrite(file, card);
writes += 1;
const saved = await cardFrontmatter.readCard(file);
assert.strictEqual(saved.frontmatter.status, 'Doing');
assert.strictEqual(saved.frontmatter.signboard_list, 'Doing');
};
try {
moved = await recordCardListMove(boardRoot, cardPath, todoList, doingList);
} finally {
cardFrontmatter.writeCard = originalWrite;
}
assert.strictEqual(writes, 1, 'Save lifecycle and destination metadata together');
assert.strictEqual(moved.moved, true);

const movedCard = await cardFrontmatter.readCard(cardPath);
assert.deepStrictEqual(getActivityTypes(movedCard.frontmatter), ['moved-list']);
assert.strictEqual(movedCard.frontmatter.activity[0].fromListDisplayName, 'To-do');
assert.strictEqual(movedCard.frontmatter.activity[0].toListDisplayName, 'Doing');
assert.strictEqual(movedCard.frontmatter.status, 'Doing');
assert.strictEqual(movedCard.frontmatter.signboard_list, 'Doing');
assert.strictEqual(movedCard.frontmatter.signboard_board, 'Archive Move Metadata Board');
assert.strictEqual(movedCard.frontmatter.custom, 'Keep me');
assert.strictEqual(movedCard.frontmatter.due, '2026-12-01');
assert.deepStrictEqual(movedCard.frontmatter.labels, ['work']);
assert.strictEqual(movedCard.body, 'Update the thread');

const before = await fs.readFile(cardPath, 'utf8');
assert.strictEqual((await recordCardListMove(boardRoot, cardPath, doingList, doingList)).moved, false);
assert.strictEqual(await fs.readFile(cardPath, 'utf8'), before, 'Same-list reorders do not rewrite metadata');

// A failed atomic replacement must not commit just the lifecycle event.
const originalRename = fs.rename;
fs.rename = async (from, to) => {
if (to === cardPath && from.endsWith('.tmp')) throw new Error('Simulated sync-client file lock');
return originalRename(from, to);
};
try {
await assert.rejects(recordCardListMove(boardRoot, cardPath, todoList, doingList), /Simulated sync-client file lock/);
} finally {
fs.rename = originalRename;
}
assert.strictEqual(await fs.readFile(cardPath, 'utf8'), before);
assert.deepStrictEqual(await fs.readdir(doingList), [path.basename(cardPath)], 'Failed writes clean up temporary files');
}

async function main() {
Expand Down
20 changes: 16 additions & 4 deletions tests/playwright/signboard-smoke.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -1551,7 +1551,10 @@ for (const filterMode of ['label', 'date', 'search']) {
['003-hidden-last-Hd002.md', 'Hidden last', false],
]) {
await cardFrontmatter.writeCard(path.join(todo, file), {
frontmatter: { title, ...(visible ? { labels: ['launch'], due: today } : {}) },
frontmatter: {
title, status: 'To-do', signboard_list: 'To-do', custom: 'Preserve on move',
...(visible ? { labels: ['launch'], due: today } : {}),
},
body: `Original body for ${title}.`,
});
}
Expand Down Expand Up @@ -1603,9 +1606,18 @@ for (const filterMode of ['label', 'date', 'search']) {
await expect.poll(async () => (await fs.readdir(doing)).filter((name) => name.endsWith('.md')).length).toBe(2);
await expect.poll(async () => {
const cardPath = await moved.getAttribute('data-path');
try { return (await cardFrontmatter.readCard(cardPath)).frontmatter.signboard_list; }
catch { return ''; }
}).toBe('Doing');
try {
const { frontmatter, body } = await cardFrontmatter.readCard(cardPath);
return {
status: frontmatter.status, list: frontmatter.signboard_list,
moves: (frontmatter.activity || []).filter((event) => event.type === 'moved-list').length,
custom: frontmatter.custom, body: body.trim(),
};
} catch { return null; }
}).toEqual({
status: 'Doing', list: 'Doing', moves: 1,
custom: 'Preserve on move', body: 'Original body for Release followup.',
});
expect(await source.evaluate((element) => element === window.filteredDragSource)).toBe(true);
expect(await page.locator('.list').evaluateAll((lists) => lists.map((list) => list.dataset.path))).toEqual(listPaths);
expect((await fs.readdir(boardRoot)).filter((name) => /^\d+-/.test(name)).sort())
Expand Down