Skip to content

Latest commit

 

History

History
90 lines (69 loc) · 2.98 KB

File metadata and controls

90 lines (69 loc) · 2.98 KB

Contributing to Qoderian

Thank you for helping improve Qoderian.

Before you start

  • Use Obsidian 1.7.2 or later on desktop.
  • Install Node.js 24 and a working qodercli.
  • Search existing issues before opening a new one.
  • Do not include private vault content, credentials, or unredacted logs.

Development setup

npm ci
npm run build

Copy .env.local.example to .env.local and set OBSIDIAN_VAULT only when you want development builds copied into a local vault automatically. Local environment files are ignored by Git.

Quality checks

Run the complete local gate before opening a pull request:

npm run typecheck
npm run lint
npm run test
npm run test:coverage
npm run build
npm run release:check
npm run audit:prod

Tests that mock the SDK do not prove that a qodercli command supports non-interactive SDK execution. Changes to commands, sessions, permissions, or stream events should also be exercised manually against a real qodercli:

npm run smoke:qoder

The initialization-only SDK check follows the official TypeScript model-selection sample and does not send a model turn. Set QODER_CLI_PATH when qodercli is not available on PATH.

Folder-drop changes have a protocol-driven test in a running Obsidian/Electron app. Set OBSIDIAN_VAULT in .env.local, launch Obsidian with remote debugging enabled, open that vault, and run:

/Applications/Obsidian.app/Contents/MacOS/Obsidian --remote-debugging-port=9222
npm run test:e2e:file-drop

The test builds and deploys the plugin into the configured test vault, reloads it, sends a folder drag through Chromium's input protocol, and verifies that the path becomes external context with visible feedback and no composer text change. It also checks dragover acceptance with a simulated host interceptor. This does not automate the Finder/Explorer mouse gesture; verify that separately. Set QODERIAN_E2E_DROP_KIND=file for the file case, or OBSIDIAN_DEBUG_PORT when using a port other than 9222.

Naming conventions

  • TypeScript, TSX, and script file names use kebab-case, including descriptive test suffixes: qoder-chat-runtime.ts and input-toolbar.model-selector.test.ts.
  • Classes, interfaces, types, and enums use PascalCase.
  • Functions and methods use camelCase.
  • Entry points and conventional modules keep their natural lowercase names, such as main.ts, index.ts, and types.ts.

npm run lint enforces these conventions. Names required by Obsidian, the Qoder SDK, or another external interface retain the spelling defined by that interface.

Pull requests

  • Keep each pull request focused on one behavior or refactor.
  • Add or update tests for behavior changes.
  • Explain user-visible changes and migration impact.
  • Preserve the Qoder-only service boundary; do not introduce provider routing without an agreed architecture change.
  • Update CHANGELOG.md for user-visible changes.

By contributing, you agree that your contribution is licensed under this repository's MIT License.