Conversation
There was a problem hiding this comment.
Pull request overview
Adds first-class static site publishing to AS Notes by bundling a new publish CLI and exposing VS Code commands/slash-commands to manage front matter and run HTML builds.
Changes:
- Introduces
publish/package (CLI + config support) and wires it into CI for docs generation. - Adds VS Code publish commands (toggle front matter fields, publish wizard, run publish) and builds
convert.jsinto the extension dist. - Moves
FrontMatterServiceintoas-notes-commonand updates consumers to import from the shared package.
Reviewed changes
Copilot reviewed 50 out of 69 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| vs-code-extension/src/extension.ts | Registers new publish-related commands in full mode. |
| vs-code-extension/src/WikilinkRenameTracker.ts | Switches FrontMatterService import to as-notes-common. |
| vs-code-extension/src/SlashCommandProvider.ts | Adds publishing slash commands that invoke the new VS Code commands. |
| vs-code-extension/src/PublishService.ts | New publish wizard/config discovery + command handlers to run bundled convert.js. |
| vs-code-extension/src/IndexService.ts | Switches FrontMatterService import to as-notes-common. |
| vs-code-extension/src/FrontMatterService.ts | Re-exports FrontMatterService from as-notes-common. |
| vs-code-extension/package.json | Bumps extension version, broadens activation, and contributes new publish commands. |
| vs-code-extension/build.mjs | Builds/bundles publish/src/convert.ts into vs-code-extension/dist/convert.js. |
| skills/as-notes-agent-use/SKILL.md | Updates docs references from html-conversion to publish. |
| publish/test/config.test.ts | Adds vitest coverage for CLI config, layouts/themes/includes, assets, base-url, etc. |
| publish/package.json | Introduces npm package metadata and scripts for the new publisher CLI. |
| publish/README.md | Adds minimal readme for the publish package. |
| html-conversion/test/FileResolver.test.ts | Updates resolver tests for slugified hrefs and adds slugify tests. |
| html-conversion/src/convert.ts | Removes the old html-conversion CLI entry point. |
| html-conversion/src/FileResolver.ts | Adds slugify() and switches href generation to slugified names. |
| html-conversion/package.json | Removes the old html-conversion package manifest. |
| html-conversion/README.md | Removes outdated html-conversion readme. |
| docs-src/templates/Journal.md | Adds a journal template placeholder header. |
| docs-src/pages/index.md | Adds a screenshot and fixes formatting. |
| docs-src/pages/Publishing a Static Site.md | Removes old publishing documentation page (moved). |
| docs-src/notes/Publishing a Static Site.md | Adds comprehensive new publishing documentation (notes workspace). |
| docs-src/blog/welcome-to-as-notes-blog.md | Adds a sample blog page for publishing. |
| docs-src/asnotes-publish.themes.notes/default.css | Adds generated/default theme CSS for notes site config. |
| docs-src/asnotes-publish.themes.notes/dark.css | Adds generated/dark theme CSS for notes site config. |
| docs-src/asnotes-publish.themes.blog/default.css | Adds generated/default theme CSS for blog site config. |
| docs-src/asnotes-publish.themes.blog/dark.css | Adds generated/dark theme CSS for blog site config. |
| docs-src/asnotes-publish.notes.json | Adds publish config for docs “notes” site. |
| docs-src/asnotes-publish.layouts.notes/minimal.html | Adds generated minimal layout template for notes config. |
| docs-src/asnotes-publish.layouts.notes/docs.html | Adds generated docs layout template for notes config. |
| docs-src/asnotes-publish.layouts.notes/blog.html | Adds generated blog layout template for notes config. |
| docs-src/asnotes-publish.layouts.blog/minimal.html | Adds generated minimal layout template for blog config. |
| docs-src/asnotes-publish.layouts.blog/docs.html | Adds generated docs layout template for blog config. |
| docs-src/asnotes-publish.layouts.blog/blog.html | Adds generated blog layout template for blog config. |
| docs-src/asnotes-publish.includes.notes/header.html | Adds generated header partial for notes config. |
| docs-src/asnotes-publish.includes.notes/footer.html | Adds generated footer partial for notes config. |
| docs-src/asnotes-publish.includes.blog/header.html | Adds generated header partial for blog config. |
| docs-src/asnotes-publish.includes.blog/footer.html | Adds generated footer partial for blog config. |
| docs-src/asnotes-publish.blog.json | Adds publish config for docs “blog” site. |
| docs-src/.vscode/settings.json | Adds markdown copy destination settings for docs workspace. |
| docs-src/.gitignore | Ignores .asnotes/ + .asnotesignore within docs-src. |
| common/test/FrontMatterService.test.ts | Adds full test suite for front matter parsing/strip/update behavior. |
| common/src/index.ts | Exports FrontMatterService from the common package entrypoint. |
| common/src/FrontMatterService.ts | Adds shared front matter parsing implementation (publishing + aliases). |
| TECHNICAL.md | Updates architecture docs to reflect publish/ + publish wizard/service. |
| README.md | Updates repository/package docs and adds publish CLI usage details. |
| CHANGELOG.md | Adds release notes entry for v2.2.8 publishing feature. |
| .vscode/settings.json | Sets workspace rootDirectory to docs-src and markdown copy destination. |
| .github/workflows/ci.yml | Renames html-conversion job to publish and switches docs build to use the npm CLI. |
Comments suppressed due to low confidence (4)
vs-code-extension/src/PublishService.ts:1
pickOutputDirectory()is being called withconfig.outputDirpassed as theinputDirparameter (2nd arg), not as the saved output directory (3rd arg). This produces incorrect default folder suggestions (derived from the output path) and skips the "reuse saved output directory" flow. Call it aspickOutputDirectory(notesRoot, config.inputDir, config.outputDir)(or at minimum passundefinedforinputDirandconfig.outputDirforsavedDir).
vs-code-extension/src/PublishService.ts:1- Same argument ordering issue as the
__all__path:selected.config.outputDiris being passed asinputDirrather thansavedDir. This will lead to wrong defaults and not offering reuse of the previously saved folder. UsepickOutputDirectory(notesRoot, selected.config.inputDir, selected.config.outputDir).
vs-code-extension/src/PublishService.ts:1 - Boolean toggling only detects
trueand treats everything else asfalse. This meanspublic: yes(or other YAML-boolean-like variants) will incorrectly toggle totrueinstead offalse. Since the repo already centralizes boolean parsing inFrontMatterService(supportstrue/false/yes/no), re-use that parsing here (or expand the regex) so toggling inverts the actual boolean value rather than only matching/true/.
vs-code-extension/package.json:1 - Activating the extension on
*will load it for every VS Code session (all languages/workspaces), which can increase startup/idle overhead and impact users who don't use AS Notes in that workspace. Prefer narrowing activation to explicit events (e.g.,onLanguage:markdown,workspaceContains:.asnotes, and/oronCommand:...for the publish commands) so the extension only activates when needed.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| --stylesheet docs.css | ||
| --asset ../docs-src/docs.css | ||
| working-directory: html-conversion | ||
| - run: npx @appsoftwareltd/asnotes-publish --config docs-src/asnotes-publish.notes.json |
There was a problem hiding this comment.
This makes CI depend on downloading the published npm package (registry availability + version alignment) rather than validating the publish/ code in the same commit. If the goal is to test the repo’s current publish implementation, build/run from publish/ in-workspace (similar to the test job) or use npx with a local path/tarball to ensure CI exercises the code being changed.
| - run: npx @appsoftwareltd/asnotes-publish --config docs-src/asnotes-publish.notes.json | |
| - run: npm ci | |
| working-directory: publish | |
| - run: npx --no-install asnotes-publish --config ../docs-src/asnotes-publish.notes.json | |
| working-directory: publish |
No description provided.