Embedded Terminal

unlisted

by enixcode

Embed a full interactive terminal. Run shell commands, AI coding agents, vim, python REPL and more.

Updated 22d agoMIT
View on GitHub

Obsidian CLI

Embed a full interactive terminal inside Obsidian. Run shell commands, REPLs (Node, Python), and CLI tools without leaving your vault.

Desktop-only. Uses node-pty + xterm.js.

Features

  • Full PTY terminal (not just piped output) — interactive programs work
  • Opens at the bottom of the editor, like VS Code
  • Toggle with a customizable hotkey or the ribbon icon
  • Follows your Obsidian theme automatically (light/dark)
  • Configurable shell path, working directory, and font size

Installation

From Community Plugins (recommended)

  1. Open Settings > Community plugins
  2. Search for Obsidian CLI
  3. Install and enable

Manual

  1. Download main.js, manifest.json, styles.css, pty-host.js from the latest release
  2. Create folder: <vault>/.obsidian/plugins/obsidian-cli/
  3. Copy the downloaded files into that folder
  4. Also copy the node_modules/node-pty/ directory from the release
  5. Reload Obsidian and enable the plugin

Usage

  • Click the terminal icon in the left ribbon, or
  • Open command palette and run Toggle terminal
  • Assign a hotkey in Settings > Hotkeys (search "Toggle terminal")

Settings

SettingDescriptionDefault
Shell pathShell executable to usecmd.exe (Win) / /bin/bash (Mac/Linux)
Working directoryStarting directoryVault root
Font sizeTerminal font size in px14

Architecture

The plugin runs node-pty in a separate Node.js process (pty-host.js) because Obsidian's Electron renderer doesn't support Worker threads. Communication happens via JSON over stdin/stdout.

Development

npm install
npm run dev    # watch mode
npm run build  # production build
npm run lint   # eslint

License

0-BSD

For plugin developers

Search results and similarity scores are powered by semantic analysis of your plugin's README. If your plugin isn't appearing for searches you'd expect, try updating your README to clearly describe your plugin's purpose, features, and use cases.