Commit graph

38 commits

Author SHA1 Message Date
blamouche
867f312cc9 Add a non-technical Getting Started section to the README
Leads with a 3-step beginner path: install the plugin from Obsidian's
Community plugins browser, install one AI coding CLI (Claude Code, Codex,
opencode, Ollama) with copy-paste installers and official links, then open
the panel. Reframes "Install in a Vault" so the community browser is the
primary path. Docs only.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-21 17:09:36 +02:00
blamouche
a13b3bdd0a Generate AUTOMATION-DOCS.md alongside the example automation
The "Create example automation" button now writes two files: the
hello-world example and a detailed AUTOMATION-DOCS.md reference covering
every option (purpose, allowed values, defaults, schedule rules, cron
examples, validation). The docs file is overwritten on each press and is
excluded from loadAutomations so it never appears as a parse error.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-21 14:05:26 +02:00
blamouche
4bf305e0b8 Add ~/.lmstudio/bin to PATH discovery so the LM Studio CLI resolves
Fixes "command not found: lms" when launching the LM Studio CLI from the
plugin. The PTY backend uses a -lc (login, non-interactive) shell, which
does not source ~/.zshrc where the lms installer adds ~/.lmstudio/bin to
PATH. getShellEnv() now adds that directory to its automatic PATH discovery.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-20 23:46:03 +02:00
blamouche
32f8adc447 Hide PTY fallback chatter from the terminal by default
The node-pty -> python bridge -> pipe fallback chain is normal operation
when the optional native node-pty module isn't installed, but its
[proxy-warn]/[proxy-info] lines (plus node-pty's multi-line "Require stack")
cluttered the terminal on every launch. Route those diagnostics through a
verbosity-gated logger in pty-proxy.js: info/warn are silent by default,
while error/fatal are always shown so real failures aren't hidden. Add a
"Verbose proxy logs" toggle (Advanced settings, off by default) that passes
a verbose flag through the proxy payload to restore full diagnostics.

Bump to 0.2.15.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-20 18:39:40 +02:00
blamouche
19e782df4d Make the idle timeout configurable (default 10s)
Replace the hard-coded ACTIVITY_IDLE_MS constant with a new "Idle timeout
(seconds)" setting (idleTimeoutSeconds, default 10) in the Automations
section. It controls when a session counts as finished — the gray tab dot
and the idle auto-close. Bump to 0.2.14.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-20 18:01:39 +02:00
blamouche
8125b744fb Raise automation idle threshold from 5s to 10s
The idle auto-close (and gray dot) fired too quickly on automation tabs.
Bump ACTIVITY_IDLE_MS to 10s so a session is only "finished" after the CLI
has been quiet for ~10s, reducing premature closes during task pauses.
Bump to 0.2.13.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-20 17:56:05 +02:00
blamouche
b1d5651713 Move automation auto-close toggles into the Automations settings section
The two "Auto-close automation sessions" toggles (on exit / when idle) now
live in the Automations section next to the folder/reload/example controls,
instead of the general session settings. Bump to 0.2.12.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-20 17:47:19 +02:00
blamouche
560735b898 Activity-aware tab dot + idle auto-close for automation sessions
The session tab status dot now reflects live CLI activity rather than just
whether the process is alive: green = a manual session's AI is working,
purple = an automation session's AI is working, gray = the CLI is idle
(finished its turn) or stopped. CliSession tracks activity continuously —
output flowing = working, quiet for ~5s = idle — and notifies the view via
onActivityChange to repaint the dot.

Add a new opt-in setting "Auto-close automation sessions when idle": closes
an automation tab once its CLI goes quiet after the prompt ran, even if the
process stays interactive (Claude/Codex). It complements the existing
on-exit close (renamed "...on exit"); both are kept. Idle-close is armed only
after the prompt is sent and driven by real CLI output, so boot and slow
first responses don't close the tab early.

Extract the pure tabDotClass helper to session-utils.ts with tests. Update
README. Bump to 0.2.11.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-20 17:40:03 +02:00
blamouche
3b215953cf Fix automation Enter not submitting on freshly spawned sessions
A new session was marked "ready" on its first byte of output, so an
automation's prompt and its delayed Enter (appendNewline: true) were sent
while the CLI was still booting and had not yet drawn its input box — the
Enter was lost. Readiness now waits for the CLI's output to go quiet
(debounced ~800ms, 10s hard cap), matching the idle-at-prompt conditions
under which the split-write Enter reliably submits.

Bump to 0.2.10.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-20 10:19:29 +02:00
blamouche
073efef75c Run multiple runtimes in parallel via session tabs
Refactor the sidebar panel from a single-process view into a tabbed
multi-session view: each tab is an independent CliSession with its own
PTY process and xterm terminal. A New session / + control opens a session
from any configured runtime; multiple sessions of the same runtime are
allowed and labels are disambiguated. Stop/Restart/Clear and the @file/
@folder buttons act on the active tab; a single ResizeObserver refits only
the visible terminal and re-fits on tab activation.

Automations now spawn their own session tab for the declared runtime (or
the default when none is declared), await CLI readiness, then send the
prompt — replacing the old skip-if-not-running/runtime-mismatch logic.
Add settings autoCloseAutomationSessions and maxConcurrentSessions; the
Automations modal "Run now" button is always enabled.

Extract pure helpers to session-utils.ts (resolveRuntimeForAutomation,
runtimeMatches, nextSessionLabel, canOpenSession) with unit tests. Update
README and the generated example automation. Bump to 0.2.9 (manifest,
versions.json, package.json, prompt-hub version).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-20 10:12:26 +02:00
blamouche
55a6b72ad1 Release 0.2.8: align manifest and versions for tag
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-20 00:21:44 +02:00
blamouche
1d11d9ebf9 Export history to a fresh date-stamped file each time
The History export filename now embeds the export date and time
(automations-history-YYYY-MM-DD-HHMMSS.md) with a numeric-suffix guard, so
exporting more than once on the same day creates a new file instead of
failing on an existing-file clash. The export heading shows the readable
export timestamp.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-20 00:09:17 +02:00
blamouche
47cab1bc04 Activate runtime field in generated example automation
The runtime option was commented out; make it a live field (runtime:
Claude) so the example shows every schedulable option active, keeping the
comment that explains removing it to target any running runtime.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-19 23:54:17 +02:00
blamouche
19208af9ea Document every option in the generated example automation
The "Create example" button now writes a hello-world.md that spells out
every available frontmatter field with its type, default, and notes:
interval-vs-cron exclusivity, five worked cron examples, runtime id/name
matching, and appendNewline behaviour. The file stays valid as-is
(interval active, cron/runtime commented) so it runs without edits.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-19 23:52:22 +02:00
blamouche
d2e907cf2d Add "Create example automation" button to settings
Generates a documented hello-world.md (every frontmatter field explained
with inline comments, plus a simple "say hello and tell me the time"
prompt) into the configured automations folder. Creates the folder if it
doesn't exist, avoids clobbering an existing file by suffixing the name,
reloads the automation cache, and opens the new file. Shows a clear notice
when no automations folder is configured.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-19 23:39:14 +02:00
blamouche
9b9a356a31 Fix Codex automation: split body and Enter into two stdin writes
Codex uses bracketed-paste-style heuristics on the input field: when text
and the trailing carriage return arrive in a single stdin write, the \r
is treated as a literal newline inside the prompt instead of the submit
key, so the message is composed but never sent.

Splitting the write — body first, then \r after a ~120 ms delay via
activeWindow.setTimeout — lets the paste-detection window close before
Enter is registered. The \r is then read as a real keystroke and the
prompt is submitted.

Claude tolerates either form; Codex does not. Verified Claude behaviour
unchanged.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-19 23:25:56 +02:00
blamouche
ec2ce25432 Fix automation Enter: send \r (carriage return), not \n
PTY-attached raw-mode TUIs (Claude, Codex, any TUI that reads keypresses
directly) only recognize \r as the Enter key — \n just sits in the input
buffer. Cooked-mode shells also accept \r because the tty line discipline
translates it, so \r is the safe universal Enter for any PTY child.

The prompt body was being typed correctly but the run never fired because
the Enter never registered. Swap the suffix from \n to \r.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-19 23:21:35 +02:00
blamouche
8efbce2156 Strip release zip to the three canonical Obsidian plugin files
Since 0.1.46, main.js embeds pty-proxy.js and pty-bridge.py via esbuild
define and writes them next to the plugin on first Start. That makes
the zip-side copies redundant: the staging step previously bundled 8
files (`manifest.json`, `main.js`, `styles.css`, `versions.json`,
`pty-proxy.js`, `pty-bridge.py`, `package.json`, `package-lock.json`),
but only the three official ones actually need to end up in the plugin
folder for the panel to start.

Trim:

- Zip now contains only `manifest.json`, `main.js`, `styles.css` —
  the canonical Obsidian plugin folder layout.
- Standalone release assets keep the four files Obsidian's plugin
  update protocol and BRAT actually fetch: `manifest.json`, `main.js`,
  `styles.css`, `versions.json`.
- `versions.json` is no longer inside the zip — Obsidian fetches it
  directly from the release URL, not from the plugin folder.
- `package.json` / `package-lock.json` are no longer shipped at all
  (advanced users can download them from the repo for the matching
  tag if they want to opt into the native node-pty backend).

Reworked the release notes body to lead with the community-store
install path and document the embedded-source bootstrap. Aligned the
README `Release` and `Required files` sections with the new layout.

Bumped manifest/version metadata to 0.1.47.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-12 23:13:36 +02:00
blamouche
7aeb9578e6 Self-bootstrap pty-proxy.js and pty-bridge.py from embedded sources
Obsidian's community-store auto-install only downloads main.js,
manifest.json, and styles.css. This plugin also needs pty-proxy.js
(spawned as a child process) and pty-bridge.py (Python PTY fallback)
alongside main.js, so community-store installs broke immediately on
Start with `Missing proxy script: ...`.

Fix:
- esbuild.config.mjs now reads pty-proxy.js and pty-bridge.py at build
  time and injects their full content as build-time JS string constants
  PTY_PROXY_SOURCE / PTY_BRIDGE_SOURCE via the `define` substitution.
- main.ts declares the two constants and adds ensureProxyFiles(dir),
  which writes both files into the plugin folder only when they're
  missing or their content drifted from the embedded copy. The helper
  is called from spawnPtyProxy before the existence check, so the very
  first Start auto-bootstraps the proxy without any zip-side files.
- README `Required files` reworked to reflect that main.js now carries
  the auxiliary sources; pty-proxy.js / pty-bridge.py move to an
  `auto-generated on first run` tier.

Verified the bundled main.js contains the embedded markers from both
files (spawnPythonBridge from proxy, decode_payload / TIOCSWINSZ /
pty.fork from bridge). Build size grows by ~22 KB.

Bumped manifest/version metadata to 0.1.46.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-12 23:09:38 +02:00
blamouche
1fce422a66 Lead manifest description with AI assistant CLI
Per user feedback, the previous "Run AI coding tools like Claude..."
phrasing buried what the plugin actually does. Reworded both
manifest.json and package.json descriptions to put the central
concept up front:

  Run an AI assistant CLI like Claude from a right sidebar terminal
  panel, with a customizable runtime list.

106 characters, validated against the obsidianmd/ui/sentence-case
rule (acronyms AI / CLI recognized, "Claude" recognized as a brand,
all other words sentence-case correct). Tested 6 candidates with
evaluateSentenceCase before picking this one.

Bumped manifest/version metadata to 0.1.45.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-27 09:01:29 +02:00
blamouche
df937afe45 Trim release standalone assets to the 5 files that actually matter
After auditing each file, classified them by whether the plugin can
start without them:

- Required (panel will not start): manifest.json, main.js, pty-proxy.js
- Recommended (panel loads but degraded): styles.css, pty-bridge.py
- Optional (only inside zip): versions.json (backwards-compat install
  matching only, not runtime), package.json + package-lock.json
  (only needed for the optional `npm install --omit=dev` native
  node-pty backend)

The release workflow now attaches only the five Required + Recommended
files as standalone assets next to the zip. The other three remain
bundled in the zip so users opting into native node-pty still get them
in one shot, but they don't clutter the release page as if they were
load-bearing.

Reworked the release notes body and the README `Required files`
section to lead with this Required/Recommended/Optional split instead
of presenting every file as "indispensable".

Bumped manifest/version metadata to 0.1.44.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-27 08:58:13 +02:00
blamouche
7bc1ddac11 Document and ship every runtime-required file in each GitHub release
The plugin's panel spawns a child process and needs more than the
typical Obsidian main.js / manifest.json / styles.css triple — the
Node proxy (pty-proxy.js) and the Python PTY fallback (pty-bridge.py)
must also be present in the plugin folder, plus versions.json (for
backwards-compatible install matching) and package.json /
package-lock.json (for the optional native node-pty backend).

The release workflow already bundled all of these inside the zip but
only attached the standard triple as standalone files. Switch to
uploading every runtime-required file at the release root so users
who fix one corrupt file or pin a specific component (e.g. swapping
in a custom pty-proxy.js for debugging) can grab it directly without
re-downloading the whole zip.

Reworked the release notes body template to spell out what each file
is for and to flag that the three-file triple is NOT sufficient for
this plugin (BRAT / Obsidian auto-update only fetches those three,
which is why the bundled zip stays the recommended install path).
Mirrored the same explanation in the README `Required files` section.

Bumped manifest/version metadata to 0.1.43.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-27 08:51:07 +02:00
blamouche
67da139633 Drop parens around No runtime configured to satisfy bot scanner
The community bot flagged exactly two lines after 0.1.41 was published:

  main.ts:187 createEl("option", { text: "(No runtime configured)" })
  main.ts:592 dropdown.addOption("", "(No runtime configured)")

Both contained the same literal "(No runtime configured)". Verified
locally that obsidianmd/ui/sentence-case@0.2.4 accepts this string in
both loose and strict modes (returned {ok: true}), so the bot must use
a stricter scanner that treats parenthesized phrases as sentence
continuations and rejects the leading capital.

Removed the parens entirely — "No runtime configured" reads as a
standalone sentence and passes both scanners. Other parenthesized
single-word fallbacks ("(Unnamed)", "(Unnamed runtime)", "(No runtime)")
were not flagged so left alone.

Bumped manifest/version metadata to 0.1.42.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-27 08:43:13 +02:00
blamouche
6e1e3ebdba Drop Codex from descriptions: not in linter brands list
Traced the persistent bot complaint to a single root cause: the
sentence-case rule's DEFAULT_BRANDS in eslint-plugin-obsidianmd@0.2.4
includes Claude, Anthropic, OpenAI, GPT, etc. but not Codex.
Verified locally — passing the description to the rule expected
"codex" lowercase. Both manifest.json and package.json descriptions
contained "Codex", hence the bot's two violations.

Reworded both descriptions to drop the unrecognized brand while
preserving the multi-runtime value prop:

  Run AI coding tools like Claude in a right sidebar terminal panel,
  with a customizable runtime list.

Bumped manifest/version metadata to 0.1.41.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-27 07:23:06 +02:00
blamouche
3ac8d12fa7 Capitalize fallback UI labels for the community bot's sentence-case scan
The community-store bot still flagged two sentence-case violations after
0.1.39 even though our local `obsidianmd/ui/sentence-case` lint was
clean. AST tracing confirmed every direct-literal UI string was already
sentence-case correct, so the surviving candidates were the lowercase
fallback labels living inside `runtime.name || "(unnamed)"`-style
expressions. The local rule's `getStringFromNode` only inspects direct
Literals and skips LogicalExpression operands, which is why our lint
silently missed them; the bot apparently walks fallback expressions.

Capitalized every such label so both scanners agree:

- `(unnamed)` → `(Unnamed)` (createEl text + Setting dropdown
  addOption label fallbacks).
- `(unnamed runtime)` → `(Unnamed runtime)` (status / log
  fallbacks for runtimes with empty names).
- `(no runtime)` → `(No runtime)` (status fallback when no
  runtime is selected).

Bumped manifest/version metadata to 0.1.40.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-26 22:25:35 +02:00
blamouche
120c66071d Drop CLIs and Claude Code from descriptions to clear sentence-case flags
The community bot still flagged two sentence-case violations after
0.1.38. Both sit in the manifest.json description: the plural acronym
"CLIs" and the multi-word product name "Claude Code" — neither is in
the linter's known-acronym / proper-noun lists, so they get flagged
mid-sentence.

Reworded the description to "Run AI coding tools like Claude or Codex
from a right sidebar terminal panel." in both manifest.json (the field
the bot actually scans) and package.json (kept in sync for npm
metadata). Also switched the local ESLint config from `recommended` to
`recommendedWithLocalesEn` so future runs match the bot's severity,
and added explicit ignores for non-source JSON / lockfiles.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-26 14:44:58 +02:00
blamouche
89ab3ae679 Add eslint-plugin-obsidianmd and resolve every recommended-rule violation
Install the official Obsidian ESLint plugin (with eslint v9 and
@typescript-eslint/parser) and add an eslint.config.mjs flat config
that wires the recommended ruleset to TS files only, with a small
override turning off hardcoded-config-path for the tests directory
(those literal `.obsidian` strings are unit-test fixtures, not real
Obsidian configuration usage). Add an `npm run lint` script and call
it from the CI workflow before tests so guideline violations surface
on every push and PR.

Resolved every reported violation:

- UI text sentence case: button labels @Active file/@Active folder ->
  @active file/@active folder; "(no runtime configured)" placeholder
  capitalised; ribbon tooltip "Open Any AI CLI" -> "Open AI CLI panel";
  command-list placeholders, descriptions, and the runtimes-section
  empty state reworded to drop ambiguous mid-sentence acronyms (PTY,
  CLIs, Node) and quoted button names.
- commands/no-plugin-name-in-command-name: command palette name
  "Open Any AI CLI" -> "Open panel" (Obsidian shows the plugin name
  next to the command, repeating it is redundant).
- prefer-active-doc on globalThis: replace the inline crypto fallback
  in runtime-utils.ts with `import { randomUUID } from "node:crypto"`.
- no-unsupported-api on Workspace.revealLeaf: bump manifest.json
  minAppVersion to 1.7.2 (the version that introduced revealLeaf) and
  await the call. versions.json maps 0.1.38 -> 1.7.2 while older
  entries stay at 1.5.0 so existing downloads keep resolving.

Lint, build, tsc and the 27 vitest cases are all clean.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-26 14:20:53 +02:00
blamouche
6e2839a92b Resolve Obsidian community-store automated-scan issues
Audit-driven fixes from the bot's automated review:

- Replace every require() in main.ts with top-level ES imports
  (child_process.spawn, fs, os, path) so the
  @typescript-eslint/no-require-imports rule passes.
- Drop unnecessary `async` on onOpen, onClose, onunload, and
  startClaudeProcess: none of them used `await`, and onunload is
  declared `void` on the Plugin base class so a Promise return was
  flagged as a type mismatch. onOpen and onClose now return
  Promise.resolve() to keep matching the ItemView interface.
- Replace the async ribbon-icon and command callbacks with sync
  callbacks that explicitly `void` the activateView promise — fixes
  the "Promise returned in function argument where a void return was
  expected" warning without losing fire-and-forget semantics.
- Rename UI labels to sentence case (the docs guideline only allows
  capitals on the first word and on acronyms / proper nouns):
  - View display text: "CLI AI Assistant" -> "Any AI CLI".
  - Ribbon tooltip and command name: "Open CLI AI Assistant"
    -> "Open Any AI CLI".
  - Auto-start hint message: "Click Start" -> "Click start".
- Drop the redundant plugin prefix on the command id ("open-claude-
  code-panel" -> "open-panel") since Obsidian auto-prefixes command
  ids with the plugin id.
- Tighten activateView to bail out cleanly when getRightLeaf(false)
  returns null, removing the only remaining strict-mode TS error.

Validated with `npm run build`, `npx tsc --noEmit` (clean) and the
27 vitest cases.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-26 14:10:51 +02:00
blamouche
3bc7fb521f Rename plugin id to any-ai-cli for community submission
The Obsidian submission bot rejected obsidian-any-ai-cli because the
guideline asks plugins not to include "obsidian" in their id (the id
becomes the plugin folder name; brevity helps sorting). Verified
any-ai-cli is free in the public community-plugins.json, then renamed
the id everywhere it surfaces:
- manifest.json (id) and bumped to 0.1.36
- versions.json (added 0.1.36 entry)
- package.json (npm name) and package-lock.json (re-synced)
- .github/workflows/release.yml (PLUGIN_ID env var → release zip name)
- README.md install paths and zip filename references

Existing personal installs must rename their plugin folder to
.obsidian/plugins/any-ai-cli before this version.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-26 08:47:09 +02:00
blamouche
1863b3e96b Rename plugin id to obsidian-any-ai-cli and bump to 0.1.35
The plugin was rebranded to "Any AI CLI" earlier in this branch, but
the manifest id remained obsidian-any-ai-code from the original name.
Aligning the id ahead of the community-store submission so the
community-plugins.json entry, the manifest id, the plugin folder name
and the release zip filename all match.

Updated:
- manifest.json id and version
- versions.json (added 0.1.35)
- package.json name and version
- package-lock.json (re-synced)
- .github/workflows/release.yml PLUGIN_ID env var
- README.md install paths and release-zip filename references

GitHub repo URLs (blamouche/obsidian-any-ai-code) are intentionally
unchanged — the repo itself is not being renamed at this time.

Existing local installs must rename their plugin folder from
.obsidian/plugins/obsidian-any-ai-code to .obsidian/plugins/obsidian-any-ai-cli
to keep the plugin discoverable.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-26 08:39:59 +02:00
blamouche
351fb29dae Bump plugin version to 0.1.34
Aligns manifest.json, versions.json, package.json, and package-lock.json
with the Prompt Hub version so the 0.1.34 release tag ships a manifest
matching the tag — covers the Obsidian community-store compliance pass
(LICENSE, settings setHeading, no leaf detach on unload, draft release).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-26 08:26:57 +02:00
blamouche
8100cecd42 Align plugin with Obsidian community submission guidelines
Audit-driven fixes for community-store submission:
- Add a top-level MIT LICENSE so the license is discoverable next to
  the manifest and README.
- Remove leaf.detach() from onunload — the plugin guidelines
  explicitly require not detaching custom-view leaves on unload so
  Obsidian preserves leaf placement across reloads.
- Settings tab UI text guidelines:
  - Drop the top-level plugin-name <h2> heading.
  - Drop the redundant heading on the first general section
    (general settings now sit at the top with no heading, per the
    "Only use headings under settings if you have more than one
    section" rule).
  - Replace remaining <h3> elements with
    new Setting(containerEl).setName(...).setHeading() so headings
    inherit Obsidian's setting-heading styling.
- Release workflow now creates drafts (draft: true), matching the
  official "Release your plugin with GitHub Actions" guide so the
  author reviews release notes before publishing.
- Tighten manifest description to a clearer action statement that
  avoids the "OpenAI" parsing ambiguity.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-26 08:24:41 +02:00
blamouche
d6a3c1c5b9 Bump plugin version to 0.1.33
Aligns manifest.json, versions.json, package.json, and package-lock.json
with the Prompt Hub version so the upcoming 0.1.33 release tag ships a
manifest matching the tag (covers the customizable runtime list, the
two-row sidebar reorg, the polished button styling with green Start /
red Stop / blue file-context highlights, and the new @Active folder
button).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-26 07:56:57 +02:00
blamouche
eb05136a03 Replace fixed Claude/Codex switch with customizable runtime list
Settings now expose a list of CLI runtimes (each with a display name and
launch command) instead of two hardcoded entries. Users can add as many
runtimes as they want from the settings panel, remove unused ones (the
list always keeps at least one entry), and pick the default runtime
through a dropdown listing every configured entry.

The sidebar toolbar replaces the previous Claude/Codex toggle buttons
with a dropdown populated from the same configured list, so switching
runtime is a single action and reflects user-added entries.

A migration helper converts legacy `command`, `codexCommand`, and
`runtime` settings into the new `runtimes` + `selectedRuntimeId` shape
on first load, and the Codex-specific terminal workarounds (no-color
env, terminal reset) are now triggered by `isCodexLikeCommand` so they
keep working regardless of the entry id.

Adds vitest coverage for the migration and codex-like command helpers.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-26 07:27:45 +02:00
blamouche
4e21c4504f Bump plugin version to 0.1.26
Aligns manifest.json, versions.json, package.json, and package-lock.json
with the Prompt Hub version so the 0.1.26 release zip ships a manifest
matching the tag name (and uses the new zero-command install flow in
the release notes template).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-25 09:33:16 +02:00
blamouche
2559a9b45b Fix node-pty crash by making native dep optional in proxy
The plugin advertises a fallback chain (PTY → Python bridge → direct
pipe → script), but a missing node-pty native module killed the proxy
at top-level require before any fallback could run. Wrap require in
try/catch and surface a clear unavailable error from spawnWithFallback,
so users who haven't run npm install --omit=dev (or whose node-pty
build failed) still get a working terminal via the Python bridge.

Bumps plugin manifest + package metadata to 0.1.25.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-25 09:26:52 +02:00
blamouche
9f6f6ecb43 Bump plugin version to 0.1.24
Aligns manifest.json, versions.json, package.json, and package-lock.json
with the Prompt Hub version so the upcoming 0.1.24 release tag matches
the manifest published in the release zip and on Obsidian's update path.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-25 09:22:01 +02:00
blamouche
8f9574e0d0 Translate README to English and finalize plugin runtime/test setup 2026-03-05 09:27:44 +01:00